I am trying to log into a desktop that is running CentOS 4.2 by tennelling VNC through SSH..
The desktop auto-logins a user, then sits there waiting for me to login.
On the client side, I fire up SSH tunneling ssh -L 8000:127.0.0.1:5900
The client spits back the error vncviewer: ConnectToTcpAddr: connect: Connection refused Unable to connect to VNC server
The server says channel 5: open failed: connect failed: Connection refused channel 5: open failed: connect failed: Connection refused
I've tried ssh -L 5900:127.0.0.1:5900 ssh -L 8000:localhost:5900
and neither work.
I've also tried using the command vino-preferences on the remote desktop. It tells me to connect to vnc:/IP-address:0
Whats interesting is that if I issue the command vncserver on the remote desktop, it starts up a new server on display :1. I can connect to this display with no issues via the SSH tunnel.
Does anyone know how I can fix this problem? I use SSH tunneling and VNC with display :0 on SUSE 10.0 machines all the time without issues.
thanks
On 4/1/06, Ryan ryanag@zoominternet.net wrote:
I've also tried using the command vino-preferences on the remote desktop. It tells me to connect to vnc:/IP-address:0
Whats interesting is that if I issue the command vncserver on the remote desktop, it starts up a new server on display :1. I can connect to this display with no issues via the SSH tunnel.
Does anyone know how I can fix this problem? I use SSH tunneling and VNC with display :0 on SUSE 10.0 machines all the time without issues.
thanks
Hi Ryan,
I usually just use the vncserver approach, which starts the :1 on port 5901, so I may not be the best person to advise you. However, I'm wondering if you go to the device running the "VNC server" and do a command like "netstat -tupan" (run as root to get the PIDs) to see what port the VNC process is using. Maybe it's not on 5900 for some reason.
Kennedy
Thank you, I think you put on the right path...
netstat shows no port for vnc at all, unless I execute vncserver
as root, I issue the command
service vncserver restart Shutting down VNC server: [ OK ] Starting VNC server: [ OK ]
then service vncserver status Xvnc is stopped
D'OH!!!!
Does anyone have any ideas why vncserver won't start?
No errors in syslog.
hkclark@gmail.com wrote
Hi Ryan,
I usually just use the vncserver approach, which starts the :1 on port 5901, so I may not be the best person to advise you. However, I'm wondering if you go to the device running the "VNC server" and do a command like "netstat -tupan" (run as root to get the PIDs) to see what port the VNC process is using. Maybe it's not on 5900 for some reason.
Kennedy
Ryan wrote:
Does anyone have any ideas why vncserver won't start?
It sounds like you misunderstand what the vncserver service does. It just starts vncservers for you (check the config in /etc/sysconfig/vncserver IIRC). It does not share the console. For that you need to configure something like the vnc loadable module ( http://www.realvnc.com/products/free/4.1/x0.html ).
William Hooper wrote:
Ryan wrote:
Does anyone have any ideas why vncserver won't start?
It sounds like you misunderstand what the vncserver service does. It just starts vncservers for you (check the config in /etc/sysconfig/vncserver IIRC). It does not share the console. For that you need to configure something like the vnc loadable module ( http://www.realvnc.com/products/free/4.1/x0.html ).
Shouldn't vino do that for me?
I must be confused on the proper way to do this in CentOS.
Under SUSE 10.0, fire up krdb and you're set. Remote VNC users can tunnel in. Does anyone know how, or have any links on how-tos, for the CentOS way of doing this?
On 4/1/06, Ryan ryanag@zoominternet.net wrote:
William Hooper wrote:
something like the vnc loadable module ( http://www.realvnc.com/products/free/4.1/x0.html ).
Shouldn't vino do that for me?
There have been a few threads about vino on this list, starting about a year ago. They all resolved with vino being abandoned in favor of using the loadable vnc module in the X server.
I can't believe vino is that difficult to get working, since RH includes it as a distributed package, but the documentation is close to non-existent. In any case it's apparent that it doesn't run automatically -- the local desktop user has to enable it before remote users can connect. It's also not obvious on which port it will listen for connections, making it difficult to preconfigure an SSH tunnel.
Does anyone know how, or have any links on how-tos, for the CentOS way of doing this?
The link that William posted (above) has fairly complete instructions. The vnc loadable module is included with the Xorg server on CentOS 4, so you just have to enable it in the xorg.conf file as decribed on that web page, and set a password.
I then use (on the remote machine)
ssh -N -f -L 5901:${vncserverhost}:5900 ${vncserverhost} vncviewer :1
It may also work to use 5901:localhost:5900 but I haven't tried that recently.
On Sat, 2006-04-01 at 11:29, Ryan wrote:
Does anyone have any ideas why vncserver won't start?
It sounds like you misunderstand what the vncserver service does. It just starts vncservers for you (check the config in /etc/sysconfig/vncserver IIRC). It does not share the console. For that you need to configure something like the vnc loadable module ( http://www.realvnc.com/products/free/4.1/x0.html ).
Shouldn't vino do that for me?
I must be confused on the proper way to do this in CentOS.
Under SUSE 10.0, fire up krdb and you're set. Remote VNC users can tunnel in. Does anyone know how, or have any links on how-tos, for the CentOS way of doing this?
I'm not really sure about this, but I thought vino was gnome-specific and krdb was kde-specific, where adding the 'Load "vnc" to the Modules section of your /etc/X11/xorg.conf file works with any window manager as long as X is running. If you want sessions other than the console, you can use vncserver for long-running sessions that allow you to disconnect and reconnect or you can configure xinetd to start new sessions on demand.