View previous topic :: View next topic |
Author |
Message |
Busta -{ D.O.N.A.T.O.R. }-
Joined: 13 Aug 2007 Posts: 81
|
Posted: Mon Mar 16, 2009 6:51 pm Post subject: Disable / Enable server services at boot time |
|
|
Can you disable/enable services ie: hylafax, samba, etc. I am sure you can, and I guess it is within the rc.M file. Can this be done through the webmin interface?
My goal is to disable fax server at boot and these messages;
FaxGetty[5062]: OPEN /dev/ttyS0 HylaFAX (tm) Version 5.2.8
FaxGetty[5062]: /dev/ttyS0: Can not initialize modem.
I have disabled fax in Webmin, but continue to get the above.
Also would like squid to start automatically at boot. Don't see rc.squid in /etc/rc.d but I am able to start in Webmin.
thanks for your help |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Mon Mar 16, 2009 7:39 pm Post subject: |
|
|
chmod -x /etc/rc.d/rc.hylafax
remove or comment faxgetty dialup line in /etc/inittab
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
Busta -{ D.O.N.A.T.O.R. }-
Joined: 13 Aug 2007 Posts: 81
|
Posted: Mon Mar 16, 2009 8:33 pm Post subject: |
|
|
thanks-
I don't see a rc.squid entry to chmod +x. Can the proxy be started automatically at boot?
Sorry - I am used to RedHat , with the chkconfig --level command to enable/disable service. |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Mon Mar 16, 2009 8:44 pm Post subject: |
|
|
My bad, I understand that you will use webmin to start squid.
You can use the script below
Code: | #!/bin/sh
# Start/stop/restart the squid daemon.
#
squid_start() {
if [ -x /usr/sbin/squid ]; then
echo "Starting squid daemon: "
echo " /usr/sbin/squid -f /etc/squid/squid.conf"
/usr/sbin/squid -f /etc/squid/squid.conf
fi
}
squid_stop() {
echo "Stopping squid daemon: "
killall squid 2> /dev/null
}
squid_restart() {
squid_stop
sleep 1
squid_start
}
case "$1" in
'start')
squid_start
;;
'stop')
squid_stop
;;
'restart')
squid_restart
;;
*)
echo "usage $0 start|stop|restart"
esac |
or you can add the entry in rc.local
'/usr/sbin/squid -f /etc/squid/squid.conf'
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
|