Question: Restart Server
gravatar for very
10.1 years ago by
very70 wrote:
Do you provide any program to restart the galaxy server? Currently, I just Ctrl+z to exit the, but some time it kept the port binding, so I have to restart the computer to release the port to start the server. If I work remotely, this put me into trouble.
galaxy • 2.7k views
ADD COMMENTlink modified 10.1 years ago by Sean Davis220 • written 10.1 years ago by very70
gravatar for Greg Von Kuster
10.1 years ago by
Greg Von Kuster840 wrote:
Hello, Start up your server as a daemon ( depending on your platform ). Perhaps something like: to start server: sh --daemon to stop server: sh --stop-daemon Greg Von Kuster Galaxy Development Team
ADD COMMENTlink written 10.1 years ago by Greg Von Kuster840
gravatar for Sean Davis
10.1 years ago by
Sean Davis220
Sean Davis220 wrote:
Ctrl+z will place the server into the background and not stop it. Therefore, it will keep the port bound. You will need to use Ctrl+c, I think. Sean
ADD COMMENTlink written 10.1 years ago by Sean Davis220
If this is helpful, I'll throw this out there, too. We're using suse linux (I think these things are dependent on your flavor of linux, but maybe not?), and typically there are scripts to start and stop services in /etc/rc.d. So, I wrote one up. Before I include it, the caveats: 1. There are various checks and such that could be done, but are not. This is kind of quick-and-dirty. 2. Might be linux flavor-dependent 3. You have to set GALAXY_RUN and GALAXY_USER appropriately #!/bin/sh # # Galaxy init script written by Michael Rusch # ### BEGIN INIT INFO # Provides: galaxy # Required-Start: $local_fs $remote_fs $network # X-UnitedLinux-Should-Start: postgresql # Required-Stop: $local_fs $remote_fs $network # X-UnitedLinux-Should-Stop: # Default-Start: 3 5 # Default-Stop: 0 1 2 6 # Short-Description: Galaxy daemon # Description: Start the Galaxy daemon ### END INIT INFO . /etc/rc.status rc_reset GALAXY_RUN="/srv/galaxy/" GALAXY_USER="galaxy" case "$1" in start) echo -n "Starting galaxy..." sudo -u $GALAXY_USER $GALAXY_RUN --daemon rc_done=$rc_done_up rc_status -v ;; stop) echo -n "Stopping galaxy..." sudo -u $GALAXY_USER $GALAXY_RUN --stop-daemon rc_status -v ;; restart) $0 stop $0 start rc_status ;; *) echo "Usage: $0 start|stop|restart" exit 1 esac rc_exit Then you can just do cd /etc/rc.d ./galaxy start or ./galaxy stop or ./galaxy restart Michael
ADD REPLYlink written 10.1 years ago by Michael Rusch80
gravatar for James Taylor
10.1 years ago by
James Taylor320
United States
James Taylor320 wrote:
ctrl-z does not terminate a process, it just suspends it. You should use ctrl-c to send an interrupt, which will cause Galaxy to shutdown cleanly. Or you can run as a daemon using the method Greg suggested. -- jt
ADD COMMENTlink written 10.1 years ago by James Taylor320
Please log in to add an answer.


Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 146 users visited in the last hour