Question: Setting Environment For Sge Scripts
0
gravatar for Andreas Kuntzagk
9.1 years ago by
Andreas Kuntzagk130 wrote:
Hi, I followed the advice for multiple installed python versions to set ~galaxy/galaxy-python/python and set the environment for the galaxy user to have that in the PATH Problem is, when a job is started on GridEngine, it does not use the "-V" flag to inherit the environment. So it runs with a different python version and more important it does not set LD_LIBRARY_PATH and fails for some tools which need some special lib. (libRblas in this case) Where can I fix that? regards, Andreas
galaxy • 2.0k views
ADD COMMENTlink modified 8.6 years ago by Pieter Neerincx360 • written 9.1 years ago by Andreas Kuntzagk130
0
gravatar for Nate Coraor
9.1 years ago by
Nate Coraor3.2k
United States
Nate Coraor3.2k wrote:
Andreas, You should be able to set it in your shell's startup files (like ~/.bash_profile). --nate
ADD COMMENTlink written 9.1 years ago by Nate Coraor3.2k
Hi, It is set in ~/.bashrc, which is source by ~/.bash_profile. If I normally login to a cluster node via ssh it is set correctly. But if I qsub a job, it is not read. Except when I set the "-V" switch. So I either need to change gridengines behaviour or make galaxy use that switch. Is there a easy way to config how to submit cluster jobs? Regards, Andreas
ADD REPLYlink written 9.1 years ago by Andreas Kuntzagk130
Andreas, SGE must not be running the shell as a login or interactive shell, which PBS does. You may want to check the 'INVOCATION' section of the bash(1) man page to see how you can force this. If you can't change how your shell is run by SGE, you could add what you need to the SGE job template in: galaxy_dist/lib/galaxy/jobs/runners/sge.py but this would be an ugly hack. --nate
ADD REPLYlink written 9.1 years ago by Nate Coraor3.2k
SGE supports per-user defaults file called "~/.sge_request" , which can be used to set job's environment variables (and other qsub parameters). I think it was mentioned in the galaxy-dev list (I don't remember by whom). Example: ============ $ cat ~/.sge_request -v PERL5LIB=/data/hannon/gordon/perl_modules/lib64/perl5 -v DUMMY=HELLO ============ Will add two environment variables (PERL5LIB and DUMMY) to each qsub job. I guess this way you can also change the PATH. see "man sge_request" or "man ge_request" (in some places it is mentioned as "ge_request" instead of "sge_request"). "man qsub" tells which options take precedence ( command-line VS script VS user-sge_request VS gloval-sge_request ). Tested with SGE 6.1 and 6.2u3. -gordon Nate Coraor wrote, On 10/20/2009 11:51 AM:
ADD REPLYlink written 9.1 years ago by Assaf Gordon320
0
gravatar for Pieter Neerincx
8.6 years ago by
Pieter Neerincx360 wrote:
Hi, I have some tools that produce SVG images. These load just fine in a browser when they are in the middle part of a galaxy browser window as tool output. But now I've added some example images as documentation in the help section of the *.xml tool config files using the reStructuredText syntax like this: .. image:: /images/custom_galaxy_tools/ExtractModificationSiteSequenceContext.svg The problem is that these images don't load. Instead the text above is displayed. The strange thing is that you cannot select the text, but if I right-click on it, I get a contextual menu with the options "View Image", "Copy Image", etc. So it seems the files are recognized as images. Bitmap images in file formats like PNG do load directly. Does anyone on the list know what I need to do to make SVGs load directly too? Cheers, Pi Biomolecular Mass Spectrometry & Proteomics group Utrecht University Visiting address: H.R. Kruyt building room O607 Padualaan 8 3584 CH Utrecht The Netherlands Mail address: P.O. box 80.082 3508 TB Utrecht The Netherlands phone: +31 6 143 66 783 email: pieter.neerincx@gmail.com skype: pieter.online
ADD COMMENTlink written 8.6 years ago by Pieter Neerincx360
Hi, This drove me nuts for a while, but I found a solution. In case anyone else wants to add SVG images the help section here is a workaround: Apparently reStructuredText is part of a package called Docutils. The current "stable" version of Docutils does not support SVG images. SVGs need to be placed in an <object> tag, but Docutils generates HTML with the svg in an <image> tag. This is fixed in the development version. If you don't want the unstable version, you can use something like the code below to insert raw html code into the help section. Note that the examples for inserting raw html in the Docutils documentation are not correct: you'll need to encode the < and > characters. .. role:: raw-html(raw) :format: html .. class:: infomark **What it does** Some help on how to use this great tool. :raw-html:`<object data="/images/custom_galaxy_tools/myTool.svg" type="image/svg+xml" width="100%"/>` Some more help on how to use his tool Also note that the raw-html role must be at the beginning of the reStructuredText preceding any other directives. Cheers, Pi mobile: +31 6 143 66 783 e-mail: pieter.neerincx@gmail.com skype: pieter.online
ADD REPLYlink written 8.6 years ago by Pieter Neerincx360
Please log in to add an answer.

Help
Access

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