Problem with crontab/init.d

Sergio Fernández sergio.fernandez at
Fri Mar 25 17:58:30 EDT 2016

Hello again!

I have a problem while trying to start GenieACS at bootup, using crontab 
or init.d

Normally, what it works is to cd to root directory /// and perform an 

The bash script / contains the following:

//if tmux has-session -t 'genieacs'; then//
//  echo "GenieACS is already running."//
//  echo "To stop it use: ./"//
//  echo "To attach to it use: tmux attach -t genieacs"//
//  tmux new-session -s 'genieacs' -d//
//  tmux send-keys './genieacs/bin/genieacs-cwmp 2>&1 | tee 
genieacs-cwmp.log' 'C-m'//
//  tmux split-window//
//  tmux send-keys './genieacs/bin/genieacs-nbi 2>&1 | tee 
genieacs-nbi.log' 'C-m'//
//  tmux split-window//
//  tmux send-keys './genieacs/bin/genieacs-fs 2>&1 | tee 
genieacs-fs.log' 'C-m'//
//  tmux split-window//
//  tmux send-keys 'cd genieacs-gui' 'C-m'//
//  tmux send-keys 'rails server' 'C-m'//
//  tmux select-layout tiled 2>/dev/null//
//  tmux rename-window 'GenieACS'//
//  echo "GenieACS has been started in tmux session 'genieacs'"//
//  echo "To attach to session, use: tmux attach -t genieacs"//
//  echo "To switch between panes use Ctrl+B-ArrowKey"//
//  echo "To deattach, press Ctrl+B-D"//
//  echo "To stop GenieACS, use: ./"

/If from*crontab* I perform any of these possibilities, it doesn't work:

@reboot sh /

@reboot cd / && sh 2>&1 /var/log/genieacs-start.log

@reboot /genieacs/bin/genieacs-cwmp 2>&1 /var/log/genieacs-cwmp.log
@reboot /genieacs/bin/genieacs-nbi 2>&1 /var/log/genieacs-nbi.log
@reboot /genieacs/bin/genieacs-fs 2>&1 /var/log/genieacs-fs.log

where file // /contains the following:

/cd / && sh 2>&1 /var/log/genieacs-start0.log/

On the other hand, if I incorporate an init script on*init.d *of the modifying the directories, it also doesn't work.

The thing is that even now I'm trying to reproduce the exact problem as 
I am telling, I can't get the output log work. I know that is failing 
because the genieacs-cwmp script is failing and I don't get response 
from the devices.

The other times I had an error like "|js-bson: Failed to load c++ bson 
extension, using pure JS version"||
Or like "Redis connection to failed - connect ECONNREFUSED
     at RedisClient.on_error 
(/genieacs/node_modules/redis/index.js:196:24)"  (but the gui was working).

Thank you in advance for your help!

Sergio Fernández.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Users mailing list