Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a Mac with Vine server installed sitting inside the firewall (actually a router connect to cable model, and has a LAN to internal).

What if I want to remote desktop to Vine server from internet, how should I configure my router? Here's my thoughts:

  • Allow port XXXX
  • Port forwarding XXXX to the Mac


  • What are the ports need to be open and forwarded?
  • Is there anything missed?


share|improve this question
up vote 1 down vote accepted

You can set the port Vine uses in the preferences. Be aware that it has a persistent server mode and a manual mode. It defaults to 5900, but you van easily change that to 5901 or whatever you like. The VNC server built into the OS uses 5900, so I use 5901 for Vine.

You just need to open a port on your router to point to the IP of the Mac. You will want to give the Mac a static IP. If you have trouble opening the port provide us with the model of router you have.

Also since Vine (or any flavor of VNC) is not secure I'd suggest opening a port to SSH on your Mac and tunnel your Vine connection over SSH. You can use a command like this to connect, although change the 5900s to the port you use. If you open the port to SSH you don't need to open the port for Vine.

ssh -L 5900: username@public_IP

After running that command on the the VNC client computer you can then VNC to localhost and your session will be secure. You could accomplish this in safari by typing vnc://localhost

Also, instead of using your public IP you could instead get a account so when your ISP gives you a new IP you'll still be able to connect. Your router may support DynDNS updates automatically, or you can get their app to keep up to date.

You would then use:

ssh -L 5900:

share|improve this answer
Thanks for the awesome answer! – Stan Jul 27 '10 at 2:02
Sure. Also, if you're using the built in screensharing app from a Mac client it won't like the attempt to connect to localhost. To allow it use defaults write skipLocalAddressCheck -boolean YES – ridogi Jul 27 '10 at 3:11
My router is D-Link DI-524. A quite old model. – Stan Jul 27 '10 at 6:38
The end of this article explains how to set up a port forward on that model.… You will want to use 22 instead of the ports they mention. Also, the type for SSH is TCP. – ridogi Jul 27 '10 at 15:56

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.