

- #Vnc viewer for mac that works with ubuntu how to
- #Vnc viewer for mac that works with ubuntu install
Next, make the script executable: chmod +x ~/x11vnc.sh We will then set the script to run at login: echo "/usr/bin/x11vnc -forever -bg -usepw -httpdir /usr/share/vnc-java/ -httpport 5901 -display :0" > ~/x11vnc.sh To configure autostart of x11vnc on the server:Īdd the command, that we use to start the VNC server, to a script in your home directory. Disable it by going to system preferences > Sharing and un-tick/de-select ‘Screen Sharing’. NOTE: In order to connect successfully to the tunnelled ‘localhost’ you must disable screen sharing on your mac. We’re using OSX’s built in VNC viewer, so in finder: shift+cmd+k and type: vnc://localhost Start the x11vnc vnc server on the Ubuntu server: x11vnc -forever -bg -usepw -httpdir /usr/share/vnc-java/ -httpport 5901 -display :0 On you mac, enter the following to tunnel port 5900 to server port 5900 over SSH (it would be more secure to use non-standard ports).
#Vnc viewer for mac that works with ubuntu install
Install the VNC server on Ubuntu: sudo apt-get install x11vncĬonfigure the password for VNC (you will be promoted to enter and then confirm the password and for a location to store it – I used the default values): x11vnc -storepasswd Public keys are used to speed up connections as passwords don’t need to be entered in order to establish connections over SSH.I also beefed up the security of my SSH connections by revoking password & root authentication.This is important to note X11vnc is a tool for sharing existing desktop sessions on the server – if you are looking to create new user/desktop sessions then you will need to use a different VNC server

Server has auto-login enabled as there is no keyboard, mouse or monitor connected.I used x11vnc so that I can connect to existing desktop sessions on the server.OverviewĬlient: OS X 10.10.1 (Macbook) || Server: Ubuntu 14.04 I’d be interested to hear other experiences. I thought I’d document the process for my own and anyone else’s benefit.
#Vnc viewer for mac that works with ubuntu how to
This time, after having a server compromised recently I wanted a more secure way of connecting to VNC from remote locations so here I will also explain how to setup an SSH tunnel for the VNC session. I’ve configured VNC for ubuntu on a couple of occasions and it’s always taken me far longer than necessary.
