[Voyage-linux] service startup in voyage linux 3.6.9
sarto76
(spam-protected)
Sat Aug 31 04:26:50 HKT 2013
Hallo, I created this service in /etc/init.d/linknx
#!/bin/sh
### BEGIN INIT INFO
# Provides: linknx
# Required-Start: $local_fs $remote_fs $network $syslog $nocatsplash
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# X-Interactive: false
# Short-Description: Start/stop linknx daemon
# Description: Simnet linknx daemond starter.
### END INIT INFO
now=$(date +"%F %k:%M:%S")
port=3671
ip=192.168.2.41
LD_LIBRARY_PATH=/usr/local/lib
knx_config_file=/var/www/knxweb/linknx.xml
knx_write_file=/var/www/knxweb/linknx.xml
log_tag="[LINKNX]"
log_level="-p local0.notice"
case "$1" in
start)
logger $log_level -t $log_tag -s "Starting linknx and eibd ..."
eibd -d -D -S -T -i ipt:$ip:$port
linknx -d --config=$knx_config_file
logger $log_level -t $log_tag -s "Done\n"
;;
stop)
killall -9 eibd
killall -9 linknx
;;
reload|restart|force-reload)
;;
test)
logger $log_level -t $log_tag -s "[$now] - [TEST] - This is a simple
test to check behavior of the program ..."
;;
*)
logger $log_level -t $log_tag -s "[$now] - [FATAL] - Unknow command, only
available are start|stop|restart|reload|force-reload"
;;
esac
exit 0
----------------------------
chmod 755
if I start manually the 2 programs it starts, I have only a warning:
W00000001: EIBD should not run as root
I tryied tho start it at startup with
insserv linknx
and I have this:
ls -l /etc/rc?.d/*linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc0.d/K02linknx ->
../init.d/linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc1.d/K02linknx ->
../init.d/linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc2.d/S02linknx ->
../init.d/linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc3.d/S02linknx ->
../init.d/linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc4.d/S02linknx ->
../init.d/linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc5.d/S02linknx ->
../init.d/linknx
lrwxrwxrwx 1 root root 16 Aug 30 19:42 /etc/rc6.d/K02linknx ->
../init.d/linknx
I tryied also with
update-rc.d linknx defaults (before I do insserv -r linknx)
I have the same links but when I boot the 2 processes won't start
So I tryied to add a cronjob at boot time , I created a shell script that
simply make this:
/etc/init.d/linknx start
the script work, but when I restart the processes won't start.
I have finished my ideas...someone can help me please??
Thank you very much
--
View this message in context: http://voyage-linux.34677.n3.nabble.com/service-startup-in-voyage-linux-3-6-9-tp4025715.html
Sent from the Voyage Linux mailing list archive at Nabble.com.
More information about the Voyage-linux
mailing list