need to help for seahub.sh auto start at reboot (raspberry Pi)

911 views
Skip to first unread message

Romain Cahu

unread,
Jul 19, 2014, 12:04:57 PM7/19/14
to sea...@googlegroups.com
Hi everybody

today i run an upgrade server from 2.0.2 to 3.0.4 on my raspberry Pi, all is ok, when I start seafile and seahub manually on terminal, all services work.

I modify my crontab from :

@reboot sudo /home/pi/cloud/seafile-server-2.0.2/seafile.sh start
@reboot sudo /home/pi/cloud/seafile-server-2.0.2/seahub.sh start
@reboot sudo vncserver :xxxx -geometry 800x600 -depth 16


to

@reboot sudo /home/pi/cloud/seafile-server-3.0.4/seafile.sh start
@reboot sudo /home/pi/cloud/seafile-server-3.0.4/seahub.sh start
@reboot sudo vncserver :xxxx -geometry 800x600 -depth 16

overwrite, exit and reboot.

When done, seafile start automatically but not seahub...
When a do on terminal :

sudo /home/pi/cloud/seafile-server-3.0.4/seahub.sh start

seahub start correctly...

do you have an idea?

great thanks

Shuai Lin

unread,
Jul 19, 2014, 8:59:23 PM7/19/14
to sea...@googlegroups.com
Like the example in the official document
http://manual.seafile.com/deploy/start_Seafile_at_system_bootup.html,
you can redirect the output of the "seahub.sh start" command to some
file to debug the reason.

For exapmple:

@reboot sudo /home/pi/cloud/seafile-server-3.0.4/seafile.sh start >>
/home/pi/cloud/logs/seafile.init.log
@reboot sudo /home/pi/cloud/seafile-server-3.0.4/seahub.sh start >>
/home/pi/cloud/logs/seahub.init.log
@reboot sudo vncserver :xxxx -geometry 800x600 -depth 16



> --
> You received this message because you are subscribed to the Google Groups
> "seafile" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to seafile+u...@googlegroups.com.
> To post to this group, send email to sea...@googlegroups.com.
> Visit this group at http://groups.google.com/group/seafile.
> For more options, visit https://groups.google.com/d/optout.

Romain Cahu

unread,
Jul 20, 2014, 7:50:00 AM7/20/14
to sea...@googlegroups.com
Thanks,

The result : 

Warning : seafile-controller not running. Have you run "./seafile.sh start" ?

but seafile is running, confirmed by log file and a "warning seafile controller is already running ... " with manual command on the terminal.

Maybe the execution of seahub.sh start is to fast and before the seafile.sh is loaded... 

Shuai Lin

unread,
Jul 20, 2014, 11:14:40 AM7/20/14
to sea...@googlegroups.com
yes. You can try to modify your scripts so that it waits ten seconds
before starting seahub.

Romain Cahu

unread,
Jul 21, 2014, 5:49:52 AM7/21/14
to sea...@googlegroups.com
thanks for your response.

I tried many configurations of crontab and after some researches, it would seems that crontab doesn't execute lines in write order. So my seahub start line is executed before seafile start line even if she is placed before.

it would seems that the good solution is to create a script, like your link.

Great thanks 

Shuai Lin

unread,
Jul 21, 2014, 9:27:44 AM7/21/14
to sea...@googlegroups.com
Yes, that's the recommended way

Glenn Perdicaro

unread,
May 29, 2016, 1:48:03 PM5/29/16
to seafile
Hello! Thnx for your forum i resolve the problem like this in crontab:

@reboot sleep 20 && sudo /home/pi/sea/seafile-server-5.1.2/seafile.sh start >> /home/pi/sea/logs/seafile.init.log

@reboot sleep 30 && sudo /home/pi/sea/seafile-server-5.1.2/seahub.sh start >> /home/pi/sea/logs/seahub.init.log



Now work perfect! :)

Reply all
Reply to author
Forward
0 new messages