Sunday, December 9, 2012

Black Screen when reconnecting back to old VNC Server when hostname was changed

When I was reconnecting to an old VNC session, I got a black screen and the screen was unresponsive. There was no way to get back to the contents in the screen. Prior to the reconnecting, the hostname on the VNC Server was changed.

VNC uses hostname and the session id for the identification of the session. You can take a look at the contents at ~/.vnc/

$ ls ~/.vnc/

headnode-h00.mycluster.sg:33.pid
headnode-h00.mycluster.sg:33.log
headnode-h00.mycluster.sg:40.pid
headnode-h00.mycluster.sg:40.log
headnode-h00.mycluster.sg:42.log

To get back to any session, and assuming your VNC Server and network are accounted for and has connection, then you have to check the hostname of the server has not been accidentally changed.

$ hostname

headnode-h00.mycluster.sg
If hostname is changed,do read the blog entries 
  1. Changing the hostname on CentOS 
  2. Another look at Changing hostname for CentOS 

No comments: