PDA

View Full Version : VNC problem



NER-Green
28th March 2006, 08:41 PM
I installed/run VNC server on succseed,in first reboot something went wrong and the VNC server didnt worked anymore.how can i get it up again by using Putty?

pparks1
28th March 2006, 09:38 PM
putty into the server

service vncserver start

If that fails, check the config in /etc/sysconfig/vncserver.

asif2k
28th March 2006, 10:56 PM
try this command ---

#vncserver :1

NER-Green
29th March 2006, 11:19 AM
#vncserver :1

It says: You will require a password to access your desktops.

vncpasswd: error while loading shared libraries: libstdc++-libc6.2-2.so.3: cannot open shared object file: No such file or directory

so i need to install libstdc++-libc6.2-2.so.3 again,how do i do that in Putty.

ummmm,im lost....

wdgiles
29th March 2006, 12:28 PM
maybe this will work:
#su root
#[enter root password]
#yum install libstdc*
#exit

NER-Green
29th March 2006, 03:35 PM
Little progress:#vncserver :1
A VNC server is already running as :1

but still: unable to connect to host: Connection refused(10061)
Grrrrr...

asif2k
30th March 2006, 06:54 AM
ok, I think maybe your firewall is blocking it. In your iptables, maybe you need to allow port 5901. If you are using windows to connect to the server. In the VNC viewer, you need to type. ( hostname:1 ) where hostname is your server for example, www.yahoo.com:1

1 is the session number. Also, make sure you have a password set up for VNC.


vncserver passwd

hth

NER-Green
31st March 2006, 01:39 PM
Ok,now i can get remote control to fedora, but when i start program running throught putty/vnc and close remote control, suprise there is no program running.it closes when i log out of putty/vnc.....
how do i get program running on services?

i envy u Linux gurus......

kai4785
31st March 2006, 05:10 PM
There's about 200 ways to get what you want done. My suggestion is to get VNC to run on the :0 display. This allows you to control the Desktop as if you're sitting at the computer. Infact, it's really fun for me to VNC home from work to find my Wife surfing the Internet, hehe.
You basically need to have X load the VNC module when it starts up, and give it security settings. Here's the FAQ pages from realvnc.com

http://www.realvnc.com/faq.html#x0
http://www.realvnc.com/products/free/4.1/

Enjoy!

tebbens
9th April 2006, 09:27 PM
Kai4785,

Do you have vnc on :0 running on FC5 ?
What steps did you take to make is work ?

Thanks !

kai4785
10th April 2006, 03:07 PM
Here's the tutorial I followed on realvnc's website.

http://www.realvnc.com/products/free/4.1/x0.html

It's one of the links on the pages I posted before.

This is assuming you've run:

$yum install vnc
and if you need
$yum install vnc-server

And you have both of these packages installed:

vnc-4.1.1-36.i386.rpm <----viewer
vnc-server-4.1.1-36.i386.rpm <----server

Here's the relevant portions of my xorg.conf file:


Section "Module"
Load "dbe"
Load "extmod"
Load "fbdevhw"
Load "record"
Load "freetype"
Load "type1"
Load "vnc"
Load "glx"
EndSection

....


Section "Screen"
Identifier "Screen0"
Device "Videocard0"
Monitor "Monitor0"
DefaultDepth 24
#Choose which user's VNC password file to use for Authentication.
#Set this password by logging in with that user and typing $vncpasswd
Option "SecurityTypes" "VncAuth"
Option "UserPasswdVerifier" "VncAuth"
Option "PasswordFile" "/home/kai/.vnc/passwd"
#Turn on the Http listening server defaulted to port 5800.
#Second Option will change the default port.
Option "httpd" "/usr/share/vnc/classes"
Option "httpport" "80"
SubSection "Display"
Viewport 0 0
Depth 16
Modes "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 24
Modes "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
EndSection

Note:
Make sure that there is a vnc module loaded when X starts.
The line:
Option "PasswordFile" "/root/.vnc/passwd"
on the site is different than mine. You can use the password for any user who has run the vncpassword command. I use the vnc password I assigned to my user, just because :)
Also, I found the part about the java viewer on a different site. The java viewer is not enabled by default on your :0 display unless you tell X where to find the java portion of vnc. Mine is in:
/usr/share/vnc/classes
called
vncviewer.jar
If it's not there on your system, check the equivalent command with your distro:


[kai@gamer ~]$ rpm -ql vnc-server
/etc/rc.d/init.d/vncserver
/etc/sysconfig/vncservers
/usr/bin/Xvnc
/usr/bin/vncconfig
/usr/bin/vncpasswd
/usr/bin/vncserver
/usr/bin/x0vncserver
/usr/lib/xorg/modules/extensions/libvnc.so
/usr/share/man/man1/Xvnc.1.gz
/usr/share/man/man1/vncconfig.1.gz
/usr/share/man/man1/vncpasswd.1.gz
/usr/share/man/man1/vncserver.1.gz
/usr/share/man/man1/x0vncserver.1.gz
/usr/share/vnc
/usr/share/vnc/classes
/usr/share/vnc/classes/index.vnc
/usr/share/vnc/classes/logo150x150.gif
/usr/share/vnc/classes/vncviewer.jar
The very last line.

I also have the Java listening on port 80. You can't run both a webserver and java vnc on port 80 at the same time. httpd will take presidence. I do this so I don't have to worry about people's firewalls if I ever need to work on my machine at home. (and I'm also behind a firewall at work. This way I can either VNC home through port 80, or SSH tunnel home through port 22. Both ways work)

Enjoy!

Check out My in-the-works site (http://gnukai.com) if you're intersted in a few other projects on FC5 I'm working on.

bert
19th May 2006, 12:36 PM
Here's the tutorial I followed on realvnc's website.

http://www.realvnc.com/products/free/4.1/x0.html

It's one of the links on the pages I posted before.

This is assuming you've run:

$yum install vnc
and if you need
$yum install vnc-server

And you have both of these packages installed:

vnc-4.1.1-36.i386.rpm <----viewer
vnc-server-4.1.1-36.i386.rpm <----server

Here's the relevant portions of my xorg.conf file:


Section "Module"
Load "dbe"
Load "extmod"
Load "fbdevhw"
Load "record"
Load "freetype"
Load "type1"
Load "vnc"
Load "glx"
EndSection

....


Section "Screen"
Identifier "Screen0"
Device "Videocard0"
Monitor "Monitor0"
DefaultDepth 24
#Choose which user's VNC password file to use for Authentication.
#Set this password by logging in with that user and typing $vncpasswd
Option "SecurityTypes" "VncAuth"
Option "UserPasswdVerifier" "VncAuth"
Option "PasswordFile" "/home/kai/.vnc/passwd"
#Turn on the Http listening server defaulted to port 5800.
#Second Option will change the default port.
Option "httpd" "/usr/share/vnc/classes"
Option "httpport" "80"
SubSection "Display"
Viewport 0 0
Depth 16
Modes "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Viewport 0 0
Depth 24
Modes "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
EndSection

Note:
Make sure that there is a vnc module loaded when X starts.
The line:
Option "PasswordFile" "/root/.vnc/passwd"
on the site is different than mine. You can use the password for any user who has run the vncpassword command. I use the vnc password I assigned to my user, just because :)
Also, I found the part about the java viewer on a different site. The java viewer is not enabled by default on your :0 display unless you tell X where to find the java portion of vnc. Mine is in:
/usr/share/vnc/classes
called
vncviewer.jar
If it's not there on your system, check the equivalent command with your distro:


[kai@gamer ~]$ rpm -ql vnc-server
/etc/rc.d/init.d/vncserver
/etc/sysconfig/vncservers
/usr/bin/Xvnc
/usr/bin/vncconfig
/usr/bin/vncpasswd
/usr/bin/vncserver
/usr/bin/x0vncserver
/usr/lib/xorg/modules/extensions/libvnc.so
/usr/share/man/man1/Xvnc.1.gz
/usr/share/man/man1/vncconfig.1.gz
/usr/share/man/man1/vncpasswd.1.gz
/usr/share/man/man1/vncserver.1.gz
/usr/share/man/man1/x0vncserver.1.gz
/usr/share/vnc
/usr/share/vnc/classes
/usr/share/vnc/classes/index.vnc
/usr/share/vnc/classes/logo150x150.gif
/usr/share/vnc/classes/vncviewer.jar
The very last line.

I also have the Java listening on port 80. You can't run both a webserver and java vnc on port 80 at the same time. httpd will take presidence. I do this so I don't have to worry about people's firewalls if I ever need to work on my machine at home. (and I'm also behind a firewall at work. This way I can either VNC home through port 80, or SSH tunnel home through port 22. Both ways work)

Enjoy!

Check out My in-the-works site (http://gnukai.com) if you're intersted in a few other projects on FC5 I'm working on.
very usefull. thank you to Kai4785

bouchecl
19th May 2006, 07:35 PM
Be careful about updating vnc and vnc-server. It seems there is a bug with regards to authentication after upgrading to the latest rpms for FC4 (4.1.1-10.1.fc4) and FC5 (4.1.1-37.fc5). There is a discussion about it here:

http://forums.fedoraforum.org/showthread.php?t=109753