Problem of global env $PATH when using galaxy in daemon mode in ubuntu
Hi everybody, I am getting troubles when I try running our galaxy instance as a daemon service in ubuntu, using the procedure provided by James Casbon and available in the /contrib galaxy directory (briefly, installing the galaxy.debian-init in the /etc/init.d directory) Everything is OK, *except* that third party softwares that are installed in /bin of the galaxy home directory fail. I suspect a problem of $PATH when the service is launched with the command : start-stop-daemon --chuid $USER --group $GROUP --start --make-pidfile \ --pidfile $PIDFILE --background --chdir $DIR --exec $PYTHON -- $OPTS; in the James bash script. However, R scripts for instance are run correctly. Taking this observation into account, we added /home/galaxy/bin in the /etc/environment unfortunately without success. Any advices for fixing this irritating bug is welcome ! Chris
I have added information to the galaxy user's .profile export TEMP=/mnt/ngswork/galaxy/tmp export PATH="/mnt/ngswork/galaxy/sw/bin:$PATH" export PYTHONPATH="/mnt/ngswork/galaxy/sw/lib/python2.6/site-packages" and added a .sgerequest # set up temp and path environment variables for jobs -v TEMP=/mnt/ngswork/galaxy/tmp -v PATH=/mnt/ngswork/galaxy/sw/bin:/usr/bin:/bin/:/usr/local/bin #-V On Aug 25, 2012, at 7:41 AM, Christophe Antoniewski <drosofff@gmail.com<mailto:drosofff@gmail.com>> wrote: Hi everybody, I am getting troubles when I try running our galaxy instance as a daemon service in ubuntu, using the procedure provided by James Casbon and available in the /contrib galaxy directory (briefly, installing the galaxy.debian-init in the /etc/init.d directory) Everything is OK, *except* that third party softwares that are installed in /bin of the galaxy home directory fail. I suspect a problem of $PATH when the service is launched with the command : start-stop-daemon --chuid $USER --group $GROUP --start --make-pidfile \ --pidfile $PIDFILE --background --chdir $DIR --exec $PYTHON -- $OPTS; in the James bash script. However, R scripts for instance are run correctly. Taking this observation into account, we added /home/galaxy/bin in the /etc/environment unfortunately without success. Any advices for fixing this irritating bug is welcome ! Chris ___________________________________________________________ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at: http://lists.bx.psu.edu/ -- Brad Langhorst langhorst@neb.com<mailto:langhorst@neb.com> 978-380-7564
I have added information to the galaxy user's .profile export TEMP=/mnt/ngswork/galaxy/tmp export PATH="/mnt/ngswork/galaxy/sw/bin:$PATH" export PYTHONPATH="/mnt/ngswork/galaxy/sw/lib/python2.6/site-packages" and added a .sgerequest # set up temp and path environment variables for jobs -v TEMP=/mnt/ngswork/galaxy/tmp -v PATH=/mnt/ngswork/galaxy/sw/bin:/usr/bin:/bin/:/usr/local/bin #-V On Aug 25, 2012, at 7:41 AM, Christophe Antoniewski <drosofff@gmail.com<mailto:drosofff@gmail.com>> wrote: Hi everybody, I am getting troubles when I try running our galaxy instance as a daemon service in ubuntu, using the procedure provided by James Casbon and available in the /contrib galaxy directory (briefly, installing the galaxy.debian-init in the /etc/init.d directory) Everything is OK, *except* that third party softwares that are installed in /bin of the galaxy home directory fail. I suspect a problem of $PATH when the service is launched with the command : start-stop-daemon --chuid $USER --group $GROUP --start --make-pidfile \ --pidfile $PIDFILE --background --chdir $DIR --exec $PYTHON -- $OPTS; in the James bash script. However, R scripts for instance are run correctly. Taking this observation into account, we added /home/galaxy/bin in the /etc/environment unfortunately without success. Any advices for fixing this irritating bug is welcome ! Chris ___________________________________________________________ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at: http://lists.bx.psu.edu/ -- Brad Langhorst langhorst@neb.com<mailto:langhorst@neb.com> 978-380-7564
Hi everybody, I figured out the problem. Here is our solution, inspired from http://serverfault.com/questions/139970/how-to-tell-start-stop-daemon-to-upd..., which may help others: In the galaxy.debian-init script provided by James Casbon, a line may be added after the variable assignments and before invoking the start-stop-daemon command: export PATH="${PATH:+$PATH:}/home/galaxy/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin" whose purpose is to populate the galaxy $PATH environmental variable, as it turns out that the start-stop-daemon, even as galaxy user, does not pass through the galaxy shell, the .profile conf file, etc... Everything seems to works fine now and we have Galaxy running as a service. Chris 2012/8/25 Christophe Antoniewski <drosofff@gmail.com>
Hi everybody,
I am getting troubles when I try running our galaxy instance as a daemon service in ubuntu, using the procedure provided by James Casbon and available in the /contrib galaxy directory (briefly, installing the galaxy.debian-init in the /etc/init.d directory) Everything is OK, *except* that third party softwares that are installed in /bin of the galaxy home directory fail. I suspect a problem of $PATH when the service is launched with the command : start-stop-daemon --chuid $USER --group $GROUP --start --make-pidfile \ --pidfile $PIDFILE --background --chdir $DIR --exec $PYTHON -- $OPTS; in the James bash script. However, R scripts for instance are run correctly. Taking this observation into account, we added /home/galaxy/bin in the /etc/environment unfortunately without success.
Any advices for fixing this irritating bug is welcome !
Chris
participants (2)
-
Christophe Antoniewski
-
Langhorst, Brad