LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 04-01-2006, 02:48 PM   #1
richb01
LQ Newbie
 
Registered: Mar 2006
Posts: 7

Rep: Reputation: 0
Newbie Question - VNC


Hi,

I an running Ubuntu. I DL'ed tight vnc.

I set up a password and can see the file. I sudo to root and type:
#./vncserver

I get New 'desktop:1 (root)' desktop is desktop:1
(etc)

So it all looks good.

But - when I enter ps ax | grep vnc

I get nothing except the grep process! It's like their is no vnc process running.

If I type ./vncserver -kill :1 the reply looks like it's killing a process.

Of course, during all this fun, I cannot connect from my WinXP machine.

Any ideas?

TIA!
Rich
 
Old 04-01-2006, 03:06 PM   #2
nilleso
Member
 
Registered: Nov 2004
Location: ON, CANADA
Distribution: ubuntu, RHAS, and other unmentionables
Posts: 372

Rep: Reputation: 31
that is wierd.. there should be a vnc log file that may have your answer

like everyone else I'm sure you may be quite happy with VNC. I recently came across a much superior tool with better security, features etc that you should check out. I have been a vnc user for many years, but I am VERY impressed with FREENX!!

cheers
 
Old 04-01-2006, 03:07 PM   #3
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
i would think that the server is failing for some reason, normally vncserver will create a log in ~/.vnc/ somewhere.
 
Old 04-01-2006, 03:07 PM   #4
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
I'd recommend you don't use root for VNC. On my box there are 3 users who can VNC in so I got them to run vncpasswd and I use the following startup script:
Code:
#!/bin/bash
#
# description: Starts and stops vncserver. \
#	       used to provide remote X administration services.

unset VNCSERVERARGS
VNCSERVERS="1:pkitest 2:steve 3:oracle"
VNCSERVERARGS[1]="-geometry 1152x864"
VNCSERVERARGS[2]="-geometry 1152x864"
VNCSERVERARGS[3]="-geometry 1152x864"

start() {
    echo -n $"Starting VNC server: "
    ulimit -S -c 0 >/dev/null 2>&1

    if [ ! -d /tmp/.X11-unix ]
    then
        mkdir -m 1777 /tmp/.X11-unix || :
    fi
    for display in ${VNCSERVERS}
    do
        echo -n "${display} "
	unset BASH_ENV ENV
	DISP="${display%%:*}"
	export USER="${display##*:}"
	export VNCUSERARGS="${VNCSERVERARGS[${DISP}]}"
        su - ${USER} -c "cd ~${USER} && [ -f .vnc/passwd ] && vncserver :${DISP} ${VNCUSERARGS}"
    done
}

stop() {
    echo -n $"Shutting down VNC server: "
    for display in ${VNCSERVERS}
    do
        echo -n "${display} "
	unset BASH_ENV ENV
	export USER="${display##*:}"
	su ${USER} -c "vncserver -kill :${display%%:*}" >/dev/null 2>&1
    done
}

# See how we were called.
case "$1" in
  start)
	start
	;;
  stop)
	stop
	;;
  restart|reload)
	stop
	sleep 3
	start
	;;
  condrestart)
	if [ -f /var/lock/subsys/vncserver ]; then
	    stop
	    sleep 3
	    start
	fi
	;;
  status)
	status Xvnc
	;;
  *)
	echo $"Usage: $0 {start|stop|restart|condrestart|status}"
	exit 1
esac
User 1 connects with vncviewer hostname:1
User 2 connects with vncviewer hostname:2
User 3 connects with vncviewer hostname:3

Hope that helps

Last edited by gilead; 04-01-2006 at 03:09 PM.
 
Old 04-01-2006, 04:14 PM   #5
richb01
LQ Newbie
 
Registered: Mar 2006
Posts: 7

Original Poster
Rep: Reputation: 0
Thanks for all the help!

Ok, I looked in my log and here is what I see:

Quote:
Xvnc version 4.0 - built Apr 19 2005 04:26:49
Underlying X server release 40200000, The XFree86 Project, Inc


Sat Apr 1 17:10:51 2006
vncext: VNC extension running!
vncext: Listening for VNC connections on port 5901
vncext: created VNC server for screen 0
Could not init font path element /usr/X11R6/lib/X11/fonts/misc/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/Speedo/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/Type1/, removing from
list!
Could not init font path element /usr/X11R6/lib/X11/fonts/CID/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/75dpi/, removing from
list!
Could not init font path element /usr/X11R6/lib/X11/fonts/100dpi/, removing from list!

Fatal server error:
could not open default font 'fixed'
xsetroot: unable to open display 'desktop:1'
/home/rich/.vnc/xstartup: line 7: twm: command not found
vncconfig: unable to open display "desktop:1"
xterm Xt error: Can't open display: desktop:1
My guess is that not finding twm is the culpret. (now to figure out what twm is! lol)

Thanks again!
 
Old 04-01-2006, 04:17 PM   #6
richb01
LQ Newbie
 
Registered: Mar 2006
Posts: 7

Original Poster
Rep: Reputation: 0
Oh, and, Gilead - yes, great advice. I guess I can really screw my system as root, huh. I'm now running as my "normal" user. Thanks
 
Old 04-01-2006, 04:42 PM   #7
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
twm is a window manager (GUI) - there's some info at http://xwinman.org/vtwm.php describing it. You could try a different window manager if you don't want to install it. To see most of the window managers you have installed try running ls -l /usr/X11R6/bin/*wm or /usr/X11R6/bin/xwmconfig - I say most because there are also things like fluxbox, windowmaker, etc. and a bunch of others (http://xwinman.org/)
 
Old 04-01-2006, 04:43 PM   #8
richb01
LQ Newbie
 
Registered: Mar 2006
Posts: 7

Original Poster
Rep: Reputation: 0
Update - I installed xorg-x11-twm, and no luck.

Any ideas are very welcome.

Thanks!
 
Old 04-01-2006, 04:49 PM   #9
richb01
LQ Newbie
 
Registered: Mar 2006
Posts: 7

Original Poster
Rep: Reputation: 0
gilead - here is my /usr/X11R6/bin/ directory:

Quote:
rich@desktop:~$ ls -al /usr/X11R6/bin/
total 1808
drwxr-xr-x 2 root root 4096 2006-03-26 21:23 .
drwxr-xr-x 5 root root 4096 2006-03-26 21:23 ..
-rwxr-xr-x 1 root root 7952 2005-10-10 14:10 gtf
-rwxr-xr-x 1 root root 9184 2005-10-10 14:10 ioport
-rwxr-xr-x 1 root root 5100 2005-10-10 14:10 mmapr
-rwxr-xr-x 1 root root 4648 2005-10-10 14:10 mmapw
-rwsr-sr-x 1 root root 7508 2005-10-10 14:10 X
-rwxr-xr-x 1 root root 1790168 2005-10-10 14:10 Xorg
rich@desktop:~$
I don't have a preference one way or another about twm. Is there a way for me to set one of my existining win mgrs? Thanks!
 
Old 04-01-2006, 05:24 PM   #10
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141

Rep: Reputation: 168Reputation: 168
Now that's strange - in my /usr/X11R6/bin I have 225 files. I was going to suggest that your ~/.vnc/xstartup file might have a syntax error (I'll post mine anyway, in case it helps later), but that looks like there are a lot of X packages not installed.
Code:
#!/bin/sh

xrdb $HOME/.Xresources
xsetroot -solid grey
xterm -geometry 110x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
wmaker &
Can you check with the Ubuntu package manager which X packages are installed?
 
Old 04-02-2006, 12:42 PM   #11
richb01
LQ Newbie
 
Registered: Mar 2006
Posts: 7

Original Poster
Rep: Reputation: 0
Hi, Steve,

Well, I got it working - thanks for all your help. I did learn alot from you.

The way I fixed it was I installed Mandrake. I was pretty disappointed with Ubuntu in that I was seeing (as you did) that I was missing alot of basic stuff.

If any Ubuntu contributors are reading this, 1 suggestion I can make is that after a simple install, use the package manager to install everything that would be considered basic, but missing.

Thanks, again, for all your help! :-)

Rich
 
  


Reply



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 newbie help stork Mandriva 6 11-05-2005 08:55 PM
VNC Question iz3r Linux - Software 11 02-04-2005 09:08 AM
Newbie help RE VNC viewer/server indespair Linux - Networking 3 08-25-2004 06:27 PM
newbie linux question - VNC laclac01 Linux - Networking 3 08-09-2004 03:01 PM
Newbie - VNC failing pm02368 Linux - Networking 3 03-25-2004 04:31 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 07:15 PM.

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