Win2003 login remotely to FC4 via VNC

Associate
Joined
5 Dec 2005
Posts
142
I know that there are heaps threads about this topics , but this what I did without any success

This is what I did on FC4 I am logging as root (I know the security implication)
First:
[root@localhost ~]# rpm -q --info vnc-server
Code:
Name		: vnc-server				 Relocations: (not relocatable)
Version	 : 4.1.1							 Vendor: Red Hat, Inc.
Release	 : 10							Build Date: Wed 27 Apr 2005 10:44:11 AM GST
Install Date: Wed 15 Feb 2006 11:53:50 PM GST	 Build Host: decompose.build.redhat.com
Group	 : User Interface/X			 Source RPM: vnc-4.1.1-10.src.rpm
Size		: 3054396						 License: GPL
Signature : DSA/SHA1, Fri 20 May 2005 10:28:29 PM GST, Key ID b44269d04f2a6fd2Packager	: Red Hat, Inc. <[url="http://bugzilla.redhat.com/bugzilla"]http://bugzilla.redhat.com/bugzilla[/url]>
URL		 : [url="http://www.realvnc.com/"]http://www.realvnc.com[/url]
Summary	 : A VNC server.
Description :
The VNC system allows you to access the same desktop from a wide
variety of platforms. This package is a VNC server, allowing others to
access the desktop on your machine.

Second:
The gedit /etc/sysconfig/vncserver
Code:
# The VNCSERVERS variable is a list of display:user pairs.
# Uncomment the lines below to start a VNC server on display :2
# as my 'myusername' (adjust this to your own). You will also
# need to set a VNC password; run 'man vncpasswd' to see how
# to do that.
# DO NOT RUN THIS SERVICE if your local area network is
# untrusted! For a secure way of using VNC, see
# <[url="http://www.uk.research.att.com/vnc/sshvnc.html"]URL:http://www.uk.research.att.com/vnc/sshvnc.html[/url]>.
#zillah uncomment VNCSERVERS="2:myusername"
 
[b]VNCSERVERS="2:root"[/b]
#zillah uncomment VNCSERVERARGS[2]="-geometry 800x600"
[b]VNCSERVERARGS[2]="-geometry 800x600"[/b]


Third:
[root@localhost ~]# vncpasswd root
Password:
Verify:

Fourth:
[root@localhost ~]# vncserver
New 'localhost.localdomain:2 (root)' desktop is localhost.localdomain:2
Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/localhost.localdomain:2.log

Is the command "vncserver" same as "service vncserver start" ?

[root@localhost ~]# service vncserver start
Starting VNC server: 2:root A VNC server is already running as :2



http://www.linuxforums.org/forum/linux-networking/56400-windows-fc4-vnc.html
Then from windows, you just need to connect using the viewer, and type
[hostname]:[screennum] in the connect box, and type in the correct
I could not find the option that he(in the quote above) was pointing , could you please look at this and let me what I missed?
Code:
http://img273.imageshack.us/img273/8994/vncviewer5vn.jpg

The error message that I received when I typed in the ip address for the address is below:
Code:
[b]VNC Viewer: 198.222.168.189:Error[/b]
unable to connect to host: The requested address is not valid in its context.(10049)


http://www.redhat.com/archives/rhl-list/2005-July/msg05595.html
I am using FC4. The fix for me was that the default iptables (i think
thats the firewall settings) were preventing incoming VNC connections.
To overcome this in gnome i went to Desktop>System Settings>Server Settings>Services There I stopped iptables - and immediately I was able to connect!
I did stop iptables as qoute above suggested.


From within FC4 I tried : vncviewer 127.0.0.1:2 (same as vncviewer :2 ),,,,,,it worked.


I tried to configure from GUI method

Desktop - Preferences - Remote Desktop , check the users view and use boxes , uncheck the 'ask you for confirmation' box , set password ,

then - Desktop - Server Settings - Services , tick vncserver box - start - save , (starts at boot up)


Any suggestion ?
 
Thanks riddlermarc
To connect from your Windows box, use the server name 198.222.168.189:5902, the 5902 bit specifies the screen number
Why do I need to use this number 5902 ? The screen number that I have configured on FC4 was 2.

Is there any criteria to choose the port number which corrospondes to a screen number ?

What if I configured the screen number 3 instead of 2 what will the port number be ?
 
zillah said:
Thanks riddlermarc

Why do I need to use this number 5902 ? The screen number that I have configured on FC4 was 2.

Is there any criteria to choose the port number which corrospondes to a screen number ?

What if I configured the screen number 3 instead of 2 what will the port number be ?
Just change the last digit of the :590x suffix to match the screen number and you are sorted :)
 
zillah said:
Any other idea ?
You are definitely trying to connect to this from another box, not from the same one? Can you SSH onto the FC4 box from another box? Can you ping the FC4 box from another box?
 
Can you SSH onto the FC4 box from another box?
I have not tried this, could you please explain the steps to do that.
1- I have got putty client on windows box.
2- What should I enable on FC4 to accept the SSH conversation from putty client on winodws ?

Can you ping the FC4 box from another box?
Yes I can
 
Putty is good, just enter the ip address of the FC4 box and hit the "Open" button.. SSH should be enabled on your FC4 box already :)

As/when you do that, let us know what the resulting output is from the command "vncserver :2" (minus the quotes) in your putty window..
 
As/when you do that, let us know what the resulting output is from the command "vncserver :2" (minus the quotes) in your putty window..

Do yo mean I have to issue this command (vncserver :2) on the linux box or the windows box ? I know we can do it on linux box , but on windows, I do not know
 
zillah said:
Do yo mean I have to issue this command (vncserver :2) on the linux box or the windows box ? I know we can do it on linux box , but on windows, I do not know
Connect to your linux box from your winbox using putty, then issue the command in the putty window :)
 
zillah said:
Output is:

Code:
A VNC server is already running as :2
.. in which case you should be able to connect to the linux box from your windows box using the server name 198.222.168.189:5902. If not, there maybe something stopping the connection going through - have a look at your Security settings and see if the Firewall and/or SELinux settings are enabled in any way (System>Administration on FC5, not sure the exact location on FC4).. let us know so we can at least rule that one out too :)
 
.. in which case you should be able to connect to the linux box

i feel there is typo here (correct me if I am wrong)

Did you mean to say :
"...in both cases you should be able,,,,,,,,,"

or you meant to say :

",,,,,in what case you should be able ,,,,,,"





If you you meant to say :

",,,,,in what case you should be able ,,,,,,"
My answer will be ssh case.
 
Back
Top Bottom