Skip to Main Content

Infrastructure Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

VNC failed to connect Connections refused (10061) Oracle Enterprise Linux

4joey1Aug 14 2010 — edited Aug 22 2010
Hallo!I am a newbie in Oracle 10g having installed Oracle 10g in Oracle Enterprise Linux version 4 update 7.

I am trying to connect to the OEL server using a Windows XP client via VNC.In the Windows XP client,I have installed VNC Viewer Enterprise Edition 4.1.9.On the OEL,I have installed vnc-4.0-12.el4 and vnc-server-4.0-12.el4.

The vncsever is running as shown below
[root@joey-oel ~]# service vncserver status
Xvnc (pid 772) is running...
[root@joey-oel ~]#

But when I try to connect to the server via the VNC Viewer in XP, get the error below

failed to connect: Connections refused (10061)

My server’s IP address is 10.0.0.1 and in the VNC Viewer Dialog box,in the server textbox,I entered the 10.0.0.1 server’s IP address and in the encryption textbox,I selected the Let Server Choose (Default) option.I even tried using the port 5900 option using 10.0.0.1:5900 but the same error appears.

How can I resolve this?

Thanks.

Comments

Dude!
vncserver ports are opened from 5900 upwards. 10061 means that the server computer was reachable, but not accepting connections on the port you were trying to connect to.

Do you have anything in "tail /var/log/messages" on the server?
Did you run "system-config-securitylevel-tui"? Select “Customize” and add 5900 to the other ports list
To troubleshoot if it is a firewall problem you can temporarily disable it until the next server restart by typing "service iptables stop"

You may want to check that port 5900 is available by typing "telnet 10.0.0.1 5900" at the command prompt from Windows "run:cmd", or better isntall Nmap from http://nmap.org/dist/nmap-5.21-win32.zip to scan for open ports on your Linux server.

Edited by: Markus Waldorf on Aug 14, 2010 11:24 AM
Hi,

besides the points Markus mentioned, normally if you start VNCServer in linux, the first port used is 5901 and not 5900.

Maybe you just checked the wrong port.
Try looking with netstat -na |grep 5900
if really the server is listening to 5900.

Sebastian
Dude!
I don't have RHEL 4.7 around to play with, but the first VNC user port depends on whether or not you have GNOME remote desktop or remote administration installed that uses Display 0, which is default in some Linux distributions, like Fedora. The first VNC client normally uses TCP port 5900 - Display 0, the 2nd 5901 - Display 1, and so on.

The port can be configured in:
/etc/sysconfig/vncservers

Also, in order to to connect, a password needs to be set, e.g. for user XYZ:
su XYZ
vncpasswd
exit

Btw, Java VNC, to connect from within a browser uses TCP port 5800
650737
did you execute command like this? vncserver :1 (port number from 1~9), then input password or not.
at the windows client side, running the vncview to connect the ip address of server with port#, like 10.10.10.10:1 then input password as same as at server side
4joey1
Thanks all of you (especially ssolbach)for informing me to use port 5901 instead of 5900.

When I connect to the server,the image is a dull grey screen showing an equally dull terminal.

I had expected the image to have all the colours of the Linux X Window e.g. on my Linux desktop,the desktop image is of my dog.I cannot see this from my Windows client side vnc connection.

How do I resolve this?

Thanks.
Dude!
If you connect to vncserver and get a blank grey screen with a consol window then this means that the ~/.vnc/xstartup script is not initializing the windows manager correctly.

http://codeghar.wordpress.com/2007/11/28/centos-5-post-install-customization/

vim /home/testuser/.vnc/xstartup

And make sure it looks like this:
#!/bin/sh
# Uncomment the following two lines for normal desktop:
unset SESSION_MANAGER
exec /etc/X11/xinit/xinitrc
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
startx &
exec gnome-session &
Also, you have to make this file executable, using the following
chmod u+x /home/testuser/.vnc/xstartup

Then, run ‘vncserver’ to create a new session based on the above script!

Another link:
http://www.realvnc.com/support/faq.html#grey

Edited by: Markus Waldorf on Aug 22, 2010 10:23 AM
1 - 6
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Sep 19 2010
Added on Aug 14 2010
6 comments
10,038 views