Friday, January 12, 2007

gtk-warning **: cannot open display:

For this error, the most common cause is that you are not running the X server.
So you have to type "startx" first then retry with your application.
It also happened to me when I did a "su - anotheruser" and tried to run from anotheruser without having proper access to my $DISPLAY. I quickly solved this by copying .Xauthority from the user running the X server to the users who su to, then did a export DISPLAY=:0
However I am not sure if this is the most secure and apropriate way to do it, but it worked and no longer gtk-warning **: cannot open display:

7 comments:

Chris said...

Thank you. Saved me some time.

Anonymous said...

Thanks, I've thinkered that one quite a time.

Christian said...

Thank you! It works!

Christian said...

Thank you! It worked again!!

Antony said...

Thank you, It works.....

phunehehe said...

many people thanked already
me to, that was it!

AAA said...

Thanks!