Take the 2-minute tour ×

I'm using cygwin, xming and molden on my laptop running Windows 7. When I'm on my lab computer running Linux (I think it's the Mandriva one) I'm able to call Molden via the terminal just by stating 'molden "nameofthefile"', but on my laptop I have this message instead : "Molden: cannot connect to X server"

I think I missed something after installing molden, but I don't know what.

share|improve this question
Have you started the X server? –  Nifle Apr 10 '12 at 13:21
add comment

1 Answer

You probably need to tell Molden where to find the X server, by setting the DISPLAY variable, for example:

DISPLAY=:0 molden "nameofthefile"

(You don't usually need to do that on Linux, because Linux terminals are themselves X clients, so the DISPLAY variable is already set. That isn't the case with the Cygwin terminal.)

share|improve this answer
I tried that: DISPLAY=:0 molden geo.xyz Xlib: connection to ":0.0" refused by server Xlib: No protocol specified Molden: cannot connect to X server :0 Any new advice ? (or what have I done wrong ? :p ) –  Damien Apr 10 '12 at 21:53
Nifle's question seems pertinent then: have you started the X server, i.e. Xming? –  ak2 Apr 11 '12 at 7:40
Yes I have. There is not more to do than just executing it ? –  Damien Apr 11 '12 at 9:06
No, that should do it. Do you see Xming's icon in the tray? It works for me, at least with standard X clients such as xterm. You might want to try that in case it's an issue specific to molden (which I know nothing about). A firewall blocking the connection is the only other possibility I can think of. –  ak2 Apr 13 '12 at 8:39
Yes, I have Xming's miniature icon. I tried authorizing Xming and Cygwin in the firewall options, even tried with firewall down, still "Molden: cannot connect to X server". Maybe I'll try Xterm, and I'm thinking about installing a Linux OS ^^ –  Damien Apr 16 '12 at 1:58
add comment

Your Answer


