Posiadam Debiana Lenny 5.1, mam następujący problem, nie odtwarza mi skryptu.
Co robię nie tak: w root/
hlds_start (bez rozszerzenia) a w nim:
Kod: Zaznacz cały
#!/bin/bash
# Serwer s1
cd /home/serwery/ffa
screen -dmS FFA ./hlds_run -game cstrike +port 27016 +maxplayers 11 +exec server.cfg +map de_dust2
Kod: Zaznacz cały
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
sh /root/hlds_start
exit 0
home/serwery/ffa.
Próbowałem użyć update-rc.d. ale są kolejne błędy. Otóż wrzuciłem skrypt do /etc/init.d o nazwie hlds nadałem prawa dostępu 755,
Kod: Zaznacz cały
vz2959:~# update-rc.d hlds1 defaults
update-rc.d: warning: /etc/init.d/hlds1 missing LSB information
update-rc.d: see <http://wiki.debian.org/LSBInitScripts>
Adding system startup for /etc/init.d/hlds1 ...
/etc/rc0.d/K20hlds1 -> ../init.d/hlds1
/etc/rc1.d/K20hlds1 -> ../init.d/hlds1
/etc/rc6.d/K20hlds1 -> ../init.d/hlds1
/etc/rc2.d/S20hlds1 -> ../init.d/hlds1
/etc/rc3.d/S20hlds1 -> ../init.d/hlds1
/etc/rc4.d/S20hlds1 -> ../init.d/hlds1
/etc/rc5.d/S20hlds1 -> ../init.d/hlds1
vz2959:~# update-rc.d hlds1 start 20 2 3 4 5 .
update-rc.d: warning: /etc/init.d/hlds1 missing LSB information
update-rc.d: see <http://wiki.debian.org/LSBInitScripts>
System startup links for /etc/init.d/hlds1 already exist.
Kod: Zaznacz cały
#!/bin/bash
# Serwer s1
cd /home/serwery/ffa
screen -dmS FFA ./hlds_run -game cstrike +port 27016 +maxplayers 11 +exec server.cfg +map de_dust2
Co zrobić by uruchamiane były procesy przez rc.local lub jak skonfigurować update-rc.d?