HOW TO USE VNCSERVER


	VIEWING LINUX DESKTOP FROM A WINDOWS SYSTEM

---------------------------------------------------------------------
   FIRST TIME SET UP OF VNCSERVER (system you want to connect to)
---------------------------------------------------------------------

1. Open a terminal and run command:	  vncserver
 
---------------------------------------------------------------------

2. First time you will be prompted to set up a password

         1. this should not be the same as your normal login password

         2. You should then get a message:

		New 'hostname:1 (username)' Desktop is hostname:1.

	Starting applications specified in /home/username/.vnc/xstartup
	Log file is /home/username/.vnc/hostname:1.log

(when you look in log you will see that VNC connections are on port 5901
	and HTTP connections are on port 5801  (numbers vary by system)

---------------------------------------------------------------------

3. Note the session (display) number that vncserver is running.  
	There may be multiple sessions.
       
---------------------------------------------------------------------

4. vncserver will not work if a firewall is running, OPTIONS:

         1. Disable your firewall (not always recommended)
	   	[SuSe]              SuSEfirewall2 stop

         2.  [SuSe]       use YAST and xinet services to open port
 
---------------------------------------------------------------------

5.  SuSe:     In order to get full graphic desktop, you need to 
		add the following two lines to the beginning of the

		vi $HOME/.vnc/xstartup :

	#!/bin/sh

	unset SESSION_MANAGER
	exec /etc/X11/xinit/xinitrc

	xrdb $HOME/.Xresources
	xsetroot -solid grey
	xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
	# twm &


---------------------------------------------------------------------

6. Stop and Restart vncserver
         vncserver -kill :1
         vncserver

---------------------------------------------------------------------

7. Resetting vncpasswd.  You can reset the vncpasswd by running the
command

         vncpasswd

---------------------------------------------------------------------

NOTE:  enabling the scroll lock will pass keystrokes such as 
	Ctrl-Tab and Alt-Tab to the viewer. 

FIRST TIME SETUP OF WINDOWS LAPTOP (client):
   1. Install vncviewer on laptop.  
   2. Click on vnc and then you should see:
    * http://www.tightvnc.com/ -- view X apps remotely
    * tightvnc-1.2.9-setup.exe
      from: http://www.tightvnc.com/download.html
    * In the installation process select vncviewer.exe and vncviewer.exe
	should install.  Make a shortcut to your desktop.

---------------------------------------------------------------------
USING VNC:
1.       On the server, start the vncserver by running
		 vncserver
	Make note of the display number (:1). (see log file)

2.       On the Client (laptop).  Click on the vncviewer icon, or open firefox.

3.       Put in the name of server and display number: ie.  server.some-company.com:2

4.       Enter the password.
5.       Your desktop should appear

---------------------------------------------------------------------

IMPORTANT:  AFTER YOU HAVE FINISHED USING YOUR SESSION, YOU SHOULD STOP
THE VNC ON THE SERVER 
	(ESPECIALLY IF YOU ARE RUNNING AS ROOT) BY RUNNING THIS COMMAND
ON THE CLIENT

  Bring up a terminal and run:
	     vncserver -kill :display number  
		example: 	vncserver -kill :1

---------------------------------------------------------------------
	Fri May  4 12:11:40 2007 - updated for SuSE only 3 July 2008
---------------------------------------------------------------------

update 31 Mar 2015 - using VNC got "RFB 003.008"

	a SuSE forum suggested using lsof -i to see if the port was open.  (it apparently is, see below)
------------------------------------------------
--> lsof -i
COMMAND     PID USER   FD   TYPE   DEVICE SIZE/OFF NODE NAME
firefox    1796 john   62u  IPv4 14616454      0t0  UDP *:ssdp 
nxnode.bi 25180 john    7u  IPv4 14583621      0t0  TCP localhost:35607->localhost:22919 (ESTABLISHED)
nxnode.bi 25180 john   15u  IPv4 14585886      0t0  TCP localhost:afs3-callback (LISTEN)
nxnode.bi 25180 john   16u  IPv4 14584371      0t0  TCP localhost:entextnetwk (LISTEN)
nxnode.bi 25180 john   17u  IPv4 14584916      0t0  TCP localhost:35870->localhost:icl-twobase2 (ESTABLISHED)
nxnode.bi 25180 john   30u  IPv4 14612319      0t0  UDP *:43890 
nxclient. 25365 john   10u  IPv4 14584543      0t0  TCP localhost:icl-twobase2 (LISTEN)
nxclient. 25365 john   13u  IPv4 14584544      0t0  TCP localhost:icl-twobase2->localhost:35870 (ESTABLISHED)
nxnode.bi 27762 john    4u  IPv4 14612176      0t0  TCP Wagoneers.com:terabase->10.1.10.10:65060 (ESTABLISHED)
nxnode.bi 27762 john   19u  IPv4 14612253      0t0  TCP localhost:26002 (LISTEN)
nxnode.bi 27762 john   20u  IPv4 14612254      0t0  TCP localhost:entexthigh (LISTEN)
nxnode.bi 27762 john   26u  IPv4 14612319      0t0  UDP *:43890 
Xvnc      28204 john    0u  IPv6 14616036      0t0  TCP *:x11 (LISTEN)
Xvnc      28204 john    1u  IPv4 14616037      0t0  TCP *:x11 (LISTEN)
Xvnc      28204 john    6u  IPv4 14616042      0t0  TCP *:5901 (LISTEN)
Xvnc      28204 john    7u  IPv4 14616043      0t0  TCP *:5801 (LISTEN)
nxnode.bi 28286 john    7u  IPv4 14615120      0t0  TCP localhost:35788->localhost:22919 (ESTABLISHED)
nxnode.bi 28286 john   15u  IPv4 14615148      0t0  TCP localhost:afs3-vlserver (LISTEN)
nxnode.bi 28286 john   16u  IPv4 14616199      0t0  TCP localhost:entextmed (LISTEN)
nxnode.bi 28286 john   21u  IPv4 14583756      0t0  UDP *:mdns 
nxnode.bi 28286 john   22u  IPv4 14583768      0t0  UDP Wagoneers.com:mdns 
------------------------------------------------


Simply Linux: Basics Linux Tackles Microsoft Using BASH on Windows 10
Practical Suggestions for Microsoft Windows
 Full Size Jeep Buyer's Guide
12 hour Video Course by john:
The Art of Linux System Administration
published by O'Reilly Media
Study Guide for the LPIC-2 Certification Exams
search for:
on the internet, or:
JohnMeister.com-fotos
LinuxMeister-Linux
BibleTech- Bible overview

overview of mankind's history
Biblical history:
"Promises and Prophets"

Wagoneers

FULL SIZE JEEPS

JeepMeister
"Jeep is America's
only real sports car."
-Enzo Ferrari


MeisterTech
Diesels +

One Page Overview of Linux Commands

click for an image of the 5 essential Linux commands

An Intro to Linux
AMSOIL product guide,
or, AMSOIL web, or 1-800-956-5695,
use customer #283461

Amsoil dealer since 1983
purchase AMSOIL
at Midway Auto on SR9 in Snohomish,
or at Northland Diesel in Bellingham, WA


SJ - 1962-1991

XJ - 1984-2001

WJ - 1999-2004

KJ - 2002-2007

WK - 2005-2010

Find the recommended
AMSOIL synthetics
for your Jeep

CJ-10A - 1984-1986

Jeepsters

MJ - 1984-1992

Willys - 1946-1965

Other Jeeps (FC)