Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VNC in to multiple workstations?

Status
Not open for further replies.

Lizardkng

Technical User
Oct 21, 2002
135
0
0
US
Im trying to allow multiple users remote access to 2 different workstations on the local network.

Currently I have the router set to forward connections to a static IP address, but this only supports the one system with the static IP.

What I need, is to be able to set up VNC (or something else?) on two different workstations, on the same external IP address, like this:

Employee 1 connects to external IP and is forwarded to PC 1 (their normal workstation)

Employee 2 connects to same external IP address as employee 1, but gets forwarded to PC 2 (a different workstation than employee 1)

2 employees, 2 different workstations, 1 external IP, each being forwarded to a different system inside our local network.

Anyone know if thats possible, or should I seek a different solution than VNC?

Thanks in advance.
 

Q52 Which TCP/IP ports does VNC use?
A VNC server listens on two ports. The exact port numbers depend on the VNC display number, because a single machine may run multiple servers.
The most important one is 59xx, where xx is the display number. The VNC protocol itself runs over this port. So for most PC servers, the port will be 5900, because they use display 0 by default.

In addition, VNC servers normally have a small and very restricted web server built in, which allows you to connect a browser to them and use the Java viewer. This runs on port 58xx. Note that this is the HTTP port used for downloading pages and applets, but once the applet is running it uses 59xx for VNC just like any other viewer.

The servers can be changed to listen on other ports if, for any reason, these are not suitable for you. See the server's documentation for more details. Most of the viewers, if given a display number larger than 99, will interpret it as a direct port number and will not add 5900. See also the next question.

If you are running a viewer in 'listening' mode, where it accepts connections initiated by the server, it will listen for incoming VNC on port 5500.

Q53 Can I run VNC over a port normally used for a standard service? (eg.port 21, or port 80)
In rare circumstances, people may want to do this, perhaps because they have a firewall which only allows connections to certain ports. This can be done, at least for the Windows and Unix servers (see their documentation), but the following points need to be borne in mind:
a.. On some systems (eg. most forms of Unix), ordinary users are not allowed to run servers on ports below 1024.
b.. You obviously can't run a VNC server on a port that's already being used for other things.
c.. Many VNC servers use two ports: one for the VNC server, and one for the HTTP server that provides the Java applet (see previous question). If you plan to use the Java viewer, you may want to change both. Not all servers will allow this at present.
d.. You need to tell the viewer the right display number. Normally, display numbers come between 0 and 99. If you specify any number smaller than 99, the viewers add 5900 to get the port number. If you specify a larger number, the viewers take it as a port number directly. So how do you use port numbers lower than 99? You have to specify a negative display number! For example, to connect to a server running on port 80 on machine 'snoopy':

vncviewer snoopy:-5820

because -5820 + 5900 = 80. This may not work with all viewers, but Unix and Windows seem to be fine.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top