Page 1 of 2
Xstartup file is empty
Posted: February 13th, 2012, 8:03 pm
by mpompey
I'm following the instructions on installing VNC on my ubuntu linux server. I've been able to install vnc4server and create a desktop session. I'm at the part of the instructions where I need to edit (vim .vnc/xstartup). However, when vim opens the file the file appears empty. I see a bunch of blue tildes and at the bottom of the screen I see ".vnc/xstartup" 0L, 0C {Zero lines, Zero Columns I guess)
I'm not sure how to regenerate the correct startup file.
--Complete linux noob, spoiled by Windows
Re: Xstartup file is empty
Posted: February 13th, 2012, 9:29 pm
by Ian
Hi there and welcome to the forums.
Make sure you're in your home folder when you issue the
vim .vnc/xstartup command. You will be in it by default when you first launch a Putty session. However, it's possible you've moved elsewhere since then. To get back to your home folder issue the following command:
Obviously substitute your own username with
YourNameGoesHere above. THEN issue the
vim .vnc/xstartup command.
Any better?
Ian.
Re: Xstartup file is empty
Posted: February 13th, 2012, 9:56 pm
by mpompey
I'll try it now. Thanks for the reply.
Re: Xstartup file is empty
Posted: February 13th, 2012, 10:00 pm
by mpompey
I confirmed that I was in the home folder. I used the terminal commands you provided and got the same result.
Re: Xstartup file is empty
Posted: February 13th, 2012, 10:16 pm
by Ian
If you issue the following command when in your home folder do you see the .vnc folder?
If so, please cd into it:
and then issue another ls -al and send me the output.
Thanks.
Ian.
Re: Xstartup file is empty
Posted: February 14th, 2012, 3:38 pm
by mpompey
Yes, I did see the .vnc folder.
I'm not sure how to copy the text from the command line output of my vm of my ubuntu server install into Windows where I'm responding so I'll type the output:
drwxr-xr-x 2 mpompey mpompey 4096 2012-02-13 14:00 .
drwxr-sr-s 8 mpompey mpompey 4096 2012-02-13 14:00 ..
-rw--------- 1 mpompey mpompey 0 2012-02-13 11:41 passwd
-rw-r--r-- 1 mpompey mpompey 1117 2012-02-13 11:51 ubuntu:1.log
-rwxr-xr-x 1 mpompey mpompey 0 2012-02-13 14:00 xstartup (xstartup is displayed in green font)
Re: Xstartup file is empty
Posted: February 14th, 2012, 7:07 pm
by Ian
Hi there,
To take a screen dump of a window, make sure the window is active and hold down the Alt key and hit the PrintScreen [PrtScn] button. This copies the window into your clipboard. Then paste it into something like Paint using Ctrl-V.
Back to your issue. When you've issued the
vncserver -geometry 1280x1024 -depth 24 command what comes back? Do you see output similar to the screenshot in my guide?
If so, issue the following command and send me the output:
Hopefully you see something along the following lines?:
Xvnc4 :1 -desktop MediaServer:1 (htkh) -auth /home/htkh/.Xauthority -geometry 1280x1024 -depth 24 -rfbwait 30000 -rfbauth /home/htkh/.vnc/passwd -rfbport 5901 -pn -fp /usr/X11R6/lib/X11/fonts/Type1/,/usr/X11R6/lib/X11/fonts/Speedo/,/usr/X11R6/lib/X11/fonts/misc/,/usr/X11R6/lib/X11/fonts/75dpi/,/usr/X11R6/lib/X11/fonts/100dpi/,/usr/share/fonts/X11/misc/,/usr/share/fonts/X11/Type1/,/usr/share/fonts/X11/75dpi/,/usr/share/fonts/X11/100dpi/ -co /etc/X11/rgb
htkh 16492 16102 0 19:04 pts/0 00:00:00 grep --color=auto vnc
Thanks.
Re: Xstartup file is empty
Posted: February 14th, 2012, 7:28 pm
by mpompey
When I issue the -geometry command I get the following back:
- geometry screenshot.jpg (57.1 KiB) Viewed 2751 times
When I run the grep command I get the following:
- geometry screenshot.jpg (57.1 KiB) Viewed 2751 times
Re: Xstartup file is empty
Posted: February 14th, 2012, 8:42 pm
by Ian
Hi,
Thanks for that. It all looks fine
Perhaps try deleting the xstartup file and issuing the
vncserver -geometry 1280x1024 -depth 24 command again? So:
Ian.
Re: Xstartup file is empty
Posted: February 14th, 2012, 9:59 pm
by mpompey
That did it! I did that and got the following: