[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Condor-users] condor_submit problems: _gtk.init_check(), RuntimeError: could not open display
- Date: Wed, 16 Nov 2011 12:54:02 -0600
- From: Christopher Prokop <cprokop@xxxxxxxx>
- Subject: Re: [Condor-users] condor_submit problems: _gtk.init_check(), RuntimeError: could not open display
What exactly is the proper syntax for including an environment in the .cmd file? echo $DISPLAY returns ...
... where X is different depending on what node I am logged in to on our cluster, i.e. localhost:21.0, localhost:10.0
When I add a line to the .cmd file as suggested...
environment = "DISPLAY = localhost:21.0"
... I get a message
ERROR: Missing '=' after environment variable 'DISPLAY'
The environment you specified was: '"DISPLAY = localhost:10.0"'
Removing the quotes, or adding single-quotes around it, results in me getting the same "RuntimeError: could not open display" message as originally. I also attempted to use my actual IP address instead of localhost, to no improvement. After looking around some more, I also tried adding a line...
getenv = True
Which, as far as I can tell, should and export my DISPLAY settings automatically, but this failed to fix the error, as well.
From: condor-users-bounces@xxxxxxxxxxx [condor-users-bounces@xxxxxxxxxxx] On Behalf Of Ian Chesal [ichesal@xxxxxxxxxxxxxxxxxx]
Sent: Wednesday, November 16, 2011 10:51 AM
To: Condor-Users Mail List
Subject: Re: [Condor-users] condor_submit problems: _gtk.init_check(), RuntimeError: could not open display
On Wednesday, 16 November, 2011 at 11:40 AM, Christopher Prokop wrote:
I am encountering a strange error when using condor_submit. Executing a script on my own works fine without errors, but when I try to run it using condor_submit, I get the following errors when trying to import from pylab or pylot from matplotlib:
line 95, in ?
line 25, in pylab_setup
line 10, in ?
line 8, in ?
File "/usr/lib/python2.4/site-packages/gtk-2.0/gtk/__init__.py", line 76, in ?
line 64, in _init
RuntimeError: could not open display
Your script is expecting to be able to connect to an active display. In this case it looks like it's looking for an X display session. Some tools require this even if you're not running anything graphical. Apparently matplotlib is one of those libraries.
You'll either need to figure out how to stop matplotlib from looking for an active display. Preventing it from loading the GTK library is probably your best way to solve this.
Or you'll need to push an DISPLAY environment variable in to the environment of the job on the remote machine. It'll need to point to a valid (and open, permission-wise) X display session. Consider using the display on your submitting desktop machine if it's running list. You can open permissions on your current display with:
And then get the DISPLAY settings with:
Copy that string in to your submission file as an env setting:
environment = "DISPLAY = <stuff you got from that echo command>"
Cycle Computing, LLC
Leader in Open Compute Solutions for Clouds, Servers, and Desktops
Enterprise Condor Support and Management Tools
This makes me think that there I am missing something in passing a permission to condor, but I have been unable to figure out what it is. I'm not even plotting or displaying any images. Are there any lines I need to add to my .cmd file?
Condor-users mailing list
To unsubscribe, send a message to condor-users-request@xxxxxxxxxxx<mailto:condor-users-request@xxxxxxxxxxx> with a
You can also unsubscribe by visiting
The archives can be found at: