LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE
User Name
Password
SUSE / openSUSE This Forum is for the discussion of Suse Linux.

Notices


Reply
  Search this Thread
Old 11-07-2006, 04:48 PM   #1
drokmed
Member
 
Registered: Dec 2005
Location: St Petersburg, FL, USA
Posts: 220

Rep: Reputation: 31
VNC works, but doesn't ask for password


Hi all,

I need the vncserver to ask me for a password!

I'm running SUSE 10.1, and the vncserver is configured and up and running. Works fine.

The first time I started the vncserver (yast2->remote administration) I didn't put a password in when it prompted me (kickin myself!). Now, it NEVER asks for a password. It will let anybody connect to it, and give them a login prompt!

I've tried everything I can think of. Used vncpasswd as root and my normal login. I've edited xinetd startup for the vnc1 session. I've even un/reinstalled tightvnc and the xorg*vnc. No luck.

This is driving me nuts!

If I connect using the java interface (browser pointed to port 5801) it DOES ask for a vnc password, before connecting to a login session.

If I connect to 5901, it refuses.

If I connect to port 1, it connects! and doesn't ask for a password.

The docs say the password is stored in $HOME/.vnc/passwd. The service runs as nobody, however there is NO /home/nobody directory. I tried making a /home/nobody/.vnc/passwd file but no luck DOH!

I've seen other people post this very same question, but I haven't found any of them answered.

Please help me Obiwan... you are my only hope!
 
Old 11-08-2006, 11:51 AM   #2
kotnik
Member
 
Registered: Nov 2004
Location: Novi Sad, Serbia
Distribution: Debian, Slackware, Gentoo, openSuSE
Posts: 254

Rep: Reputation: 31
I don't know about Yast thing, but you can start vncserver as a regular user. First set up a password:

vncpasswd

Copy xinit script of your favourite Window Manager into ~/.vnc/xstartup. I use fluxbox, so my xstartup looks like this:

Code:
#!/bin/sh
# $XConsortium: xinitrc.cpp,v 1.4 91/08/22 11:41:34 rws Exp $

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/usr/X11R6/lib/X11/xinit/.Xresources
sysmodmap=/usr/X11R6/lib/X11/xinit/.Xmodmap

# merge in defaults and keymaps

if [ -f $sysresources ]; then
    xrdb -merge $sysresources
fi

if [ -f $sysmodmap ]; then
    xmodmap $sysmodmap
fi

if [ -f $userresources ]; then
    xrdb -merge $userresources
fi

if [ -f $usermodmap ]; then
    xmodmap $usermodmap
fi

# Start the window manager:
eval `ssh-agent`
exec /usr/X11R6/bin/startfluxbox
Then, start a server:

vncserver

Nobody will be able to connect without a password.
 
Old 11-09-2006, 03:38 PM   #3
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Rep: Reputation: 31
There's 2 ways to enable VNC via GUI (KDE or GNOME).

Yast > Remote Administration (which starts a separate session for each remote login) and yes you have to manually setup a password using steps below.

second way:

Yast > Display and Monitor (X monitor setup) and just enable VNC (which lets you log into the existing session visible on X). That will also give you a password option right there and not have to go through the troubles above.

FYI - make sure you open the firewall port for the one you want (5900 or 5800 - java). Or be smart and do VNC through SSH tunnel (no firewall port opening required, except for SSH).

Hope this helps
 
Old 11-10-2006, 10:57 AM   #4
drokmed
Member
 
Registered: Dec 2005
Location: St Petersburg, FL, USA
Posts: 220

Original Poster
Rep: Reputation: 31
Thank you for both of those responses.

The "second way" is what I was actually looking to do, which is to remote control the current X session, just like I do on my windows servers.

However, when I enabled that option, it does wierd things. It works, I can connect to it from a remote vnc client, but the video is scrambled (interlaced) and the keyboard on the server becomes disabled. DOH! I have to view from the server, and key from the remote client heh. Oh well, disabled that for now.

I sure wish suse/Novell had some documentation on this stuff. The various online help resources dont even mention the display->vnc option. When enabled, its deactivating the local keyboard... dont see any options to configure that.
 
Old 11-10-2006, 12:49 PM   #5
crazibri
Member
 
Registered: Mar 2004
Location: Orange County, CA
Distribution: OS X, SuSE, RH, Debian, XP
Posts: 377

Rep: Reputation: 31
Hmm, I had a similar problem like that with a previous machine. I remember that you have to go into your X11 config file to change it. There will be an entry for your existing keyboard and mouse but there will be another entry for your VNC keyboard and VNC mouse. Check it out and see if you see anything wrong. It should be in /etc/X11/xorg.conf if I remember correctly. You should enable that VNC option using the GUI config before looking at the xorg.conf file, otherwise you wont see the VNC entries.

If you display your conf file, I might be able to help.
 
Old 11-10-2006, 06:42 PM   #6
kotnik
Member
 
Registered: Nov 2004
Location: Novi Sad, Serbia
Distribution: Debian, Slackware, Gentoo, openSuSE
Posts: 254

Rep: Reputation: 31
If you want to access to already running X desktop, then use x11vnc package. It's easy to setup and use.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
VNC password natm Linux - Software 3 07-19-2005 11:04 AM
Tight VNC password? Maver Linux - Software 2 08-29-2004 05:11 PM
vnc..telnet..rlogin..nothing works 4 me funkymunky Linux - Networking 25 08-20-2004 08:08 AM
vnc over ssh works fine but then i have X problem... suhis Linux - General 1 08-17-2004 04:33 PM
vnc works on root but greyscreen for user Johnlester199 Linux - General 6 10-15-2002 06:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > SUSE / openSUSE

All times are GMT -5. The time now is 11:28 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration