Step I: Setup VNC in Ubuntu:
VNC (Virtual Network Computer) can be setup in Ubuntu in the following four easy steps:
- Install VNC package using following command in terminal: sudo apt-get install x11vnc vnc-java
- Password Setup command in terminal: x11vnc -storepasswd
- Make sure ports 5800 and 5900 are open on your system firewall. You should not bother to do anything in this step however since Ubuntu by default does not firewall anything and once a service is set to listen on a port, there is no further configuration needed. Refer this post if you need further information about opening a port.
- Run below command in terminal to launch VNC:
- Add it for auto-starting in future sessions. Go to System–> Preferences –> Startup Applications. Click on Add button and enter the command in Step 4. This will make sure you have the VNC service up and running after system restarts.
x11vnc -forever -usepw -httpdir /usr/share/vnc-java/ -httpport 5800
Step II: Setup VNC in IPhone (though the steps should be pretty much the same for any mobile/system):
- Install a VNC client from the Apple Store. I use “Mocha VNC Lite” because of its simplicity and ease of configuration.
- Run the IPhone application and follow the instructions to connect your IPhone VNC client with the Ubuntu VNC server. Use command ifconfig to get the VNC Server IP on Ubuntu machine. Use 5900 as the default port. Enter the same password as setup in Step 2 above while installing VNC server on Ubuntu machine.
That’s it. Enjoy controlling your Ubuntu system remotely through your smart phone. Below are some screenshots previewing the same.