WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: How to utilize the Control Panel  (Read 7187 times)

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14819
Re: How to utilize the Control Panel
« Reply #15 on: November 13, 2012, 03:11:15 AM »
Did you check if sshd init.d has the couple of lines of code mentioned above?

Offline rms46

  • Jr. Member
  • **
  • Posts: 60
    • Rahmat M. Samik-Ibrahim
Re: How to utilize the Control Panel
« Reply #16 on: November 13, 2012, 05:12:48 AM »
Did you check if sshd init.d has the couple of lines of code mentioned above?

No. I have no idea how to implement:
Quote
The init.d script has to be written to interact with the services applet - see other extensions (for example bluez, dbus) for how this is done.
This following is ROT13 -- Guvf sbyybjvat vf EBG13

Offline Lee

  • Hero Member
  • *****
  • Posts: 645
    • My Core wiki user page
Re: How to utilize the Control Panel
« Reply #17 on: November 13, 2012, 06:13:58 PM »
As an example, try this.

As root, do the following

* Make a copy of /usr/local/etc/init.d/openssh as /usr/local/etc/init.d/openssh2 and make it executable with chmod
* Edit the copy to add the line
Code: [Select]
   status) pidof sshd;;right before the line that says
Code: [Select]
   start) start;;and save it.
* Kill off the sshd process, if it is running
* Start the services applet.  Use the new openssh2 button instead of the original openssh button


Don't forget to add the new script to your backup.

32 bit core4.7.7, Xprogs, Xorg-7.6, wbar, jwm  |  - Testing -
PPR, data persistence through filetool.sh          |  32 bit core 8.0 alpha 1
USB Flash drive, one partition, ext2, grub4dos  | Otherwise similar

Offline rms46

  • Jr. Member
  • **
  • Posts: 60
    • Rahmat M. Samik-Ibrahim
Re: How to utilize the Control Panel
« Reply #18 on: November 14, 2012, 03:45:07 AM »
As an example, try this.[...]

Thank you very much.
I have got an idea on how the service applet works.
I run a simple script in bootlocal.sh:
Code: [Select]
#! /bin/sh
# $Id: setopenssh 477 2012-11-14 08:28:20Z rmssvn $

[ -f /usr/local/etc/init.d/openssh ] && {
   sed '/case $1 in/ a\
   status)  pidof sshd;;' /usr/local/etc/init.d/openssh > /tmp/tmpopenssh
   chmod 755 /tmp/tmpopenssh
   mv -f /tmp/tmpopenssh /usr/local/etc/init.d/openssh
   /usr/local/etc/init.d/openssh start
}
exit
This following is ROT13 -- Guvf sbyybjvat vf EBG13