Export DISPLAY on CentOS

Writing by on Wednesday, 29 of September , 2010 at 4:41 pm

One of the pain points with UNIX is that there are several flavors of Linux and several flavors of Shells. Things that work one way on Solaris (CSH) may not work with CentOS (BASH) or Ubuntu (tcsh).  After major struggle and after several trials-and-errors, I figured how a simple thing like exporting display can be so painful if you don’t know how it works.

On the CentOS box where you want to see the DISPLAY (pretty standard)

xhost +

Then simply ssh -X to the remote host and you should be all set: (This is the trick)

ssh -X user@remotehost
xclock &

That’s it folks! Remember to use the -X option with SSH.

Don’t mess with export DISPLAY=SOURCEIP:0.0. This will cause you MAJOR GRIEF.

Comments (1)

Category: Linux

1 Comment

Comment by fenderbirds

Made Monday, 18 of October , 2010 at 10:41 am

nice article, keep the posts coming

Leave a comment

You must be logged in to post a comment.

Shivdev Kalambi's Blog

Shivdev Kalambi is a Software Development Manager, previously a Principal Software Engineer at ArcSight/HP. With over 16 years' experience in software development, he's worked on several technologies and played different roles and contributed to all phases of projects. Non-tech activies include Ping-pong, Rock Climbing and Yoga at PG, Golf, Skiing, Swimming & a beer enthusiast.