Question

Can you please help me identify the problem here:

I am running Redhat 64bit 6.4 version with the following config. Firewall is disabled, vncserver started successfully, but i still cannot vnc (from a windows VNCviewer client) into the server (redhat). I keep seeing this in the $HOME/.vnc/*.log file

(gnome-volume-control-applet:13945): WARNING **: Connection failed, reconnecting...

Here is my setup:

[root@ip-172-31-47-86 ~]# cat /home/dev/.vnc/xstartup
#!/bin/sh

[ -r /etc/sysconfig/i18n ] && . /etc/sysconfig/i18n
export LANG
export SYSFONT
vncconfig -iconic &
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
OS=`uname -s`
if [ $OS = 'Linux' ]; then
  case "$WINDOWMANAGER" in
    *gnome*)
      if [ -e /etc/SuSE-release ]; then
        PATH=$PATH:/opt/gnome/bin
        export PATH
      fi
      ;;
  esac
fi
if [ -x /etc/X11/xinit/xinitrc ]; then
  exec /etc/X11/xinit/xinitrc
fi
if [ -f /etc/X11/xinit/xinitrc ]; then
  exec sh /etc/X11/xinit/xinitrc
fi
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
twm &
exec gnome-session
[root@ip-172-31-47-86 ~]#

[root@ip-172-31-47-86 ~]# cat /etc/sysconfig/vncservers
VNCSERVERS="1:dev"
VNCSERVERARGS[1]="-geometry 1024x768 -depth 16"
[root@ip-172-31-47-86 ~]#
Was it helpful?

Solution

Solved it. I believe, this was happening particularly in Amazon (AWS) EC2 because of AWS's firewall outside the instance. I had to add rule to the instance to allow the VNC traffic. the process is documented here: GUI in Amazon EC2 Linux instance

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top