1) Install packages | click here for 1 click install
sudo aptitude install x11vnc vnc-java
2) Set up password to allow clients to view
x11vnc -storepasswd
3) Open up ports 5800 and 5900 on your firewall
4) Run this command:
x11vnc -forever -usepw -httpdir /usr/share/vnc-java/ -httpport 5800
That's it!
And an optional step 5:
5) Add the command from 4) to your sessions, so that it starts at each login
If you want to test it out on a browser, type this in the URL field:
25.542.161.414:5800
Of course, replace the 25.etc. w/ your external IP address.
Addendums to this are welcome, such as how to make it more secure. I just thought it'd be nice to have a quick and dirty tutorial for getting this set up easily.
desktop share is already installed in ubuntu by default
ReplyDeleteThe above poster is correct. I think its System > Administration > Remote Desktop. It might be in System > Preferences though. Tick the box labelled something like "allow other users to control my desktop"
ReplyDeleteIt automatically makes a firewall rule, I'm fairly sure. So you just need to port forward from your router.
Yes Desktop sharing is enabled by default in Gutsy Gibson and it does automatically make a firewall rule. If you need to learn about portforwarding you can check out portforward.com
ReplyDeleteAskTheAdmin.Com
Thanks you have friends over @ AskTheAdmin.com!
But i guess that solution covers the vnc access to a not initialized session. In ubuntu default way, you can connect just if a session was initialized.
ReplyDeleteuh huh...but how does one connect using the remote desktop thing on a windows machine?
ReplyDeleteif you're on windows u can use windows remote desktop program?
i thot u needed vnc for this...
I get an error when I try and start the VNC server (via putty):
ReplyDelete04/11/2007 11:08:44 x11vnc version: 0.8.2 lastmod: 2006-07-12
Xlib: connection to "localhost:10.0" refused by server
Xlib: PuTTY X11 proxy: MIT-MAGIC-COOKIE-1 data did not match
04/11/2007 11:08:45 ***************************************
04/11/2007 11:08:45 *** XOpenDisplay failed (localhost:10.0)
*** x11vnc was unable to open the X DISPLAY: "localhost:10.0", it cannot continue.
*** There may be "Xlib:" error messages above with details about the failure.
HELP!
how do i uninstall it??
ReplyDeletehow do I control ubuntu 6.10 with windows xp?
ReplyDeleteit doesnt work when I type "(my name)-desktop:5800
To all people leaving Ubuntu-specific questions here:
ReplyDeleteHead over to http://www.ubuntuforums.org, register, browse the forums! Chances are, someone has already solved the problem you are looking to solve. If you cannot find a solution somewhere, feel free to post a thread under the appropriate section.
To uninstall,
sudo aptitude remove x11vnc vnc-java
Yes, windows remote desktop (as far as I am aware) is a proprietary piece of software that is not VNC-compliant.
And finally, a security note here: Using the default ports of 5800 and 5900 is generally bad security practice. Try changing them so something higher (40,000-65,000 is a good range). Be sure you forward the correct port, if you are behind a firewall!
Good luck!
Okay people, don't use it this way because it is very insecure!
ReplyDeleteAll VNC traffic is unencrypted! The proper procedure would be to tunnel VNC through SSH. That can be done like this:
Do all of the above except don't open the ports in your firewall, instead open port 22.
Not install the package openssh-server.
To connect to the system from a remote machine you now need to open an SSH connection like this (on the remote machine):
ssh -L 5900:localhost:5900 username@system
Now - on the remote machine - just connect VNC to localhost. If you want to use the java-thing in the browser change the ports to 5800 instead.
Again, do not underestimnate the security risk. Just using Linux doesn't make your computer secure! You have to keep it secure. On my machine I get thousands of attempts a week (from chinese IPs) to connect to the stanbdard VNC ports trying to brute force their way in.
A secure and faster alternative is NoMachine NX (even works with Compiz).
[quote]how do i uninstall it??[/quote]
ReplyDeletelmao.
Just go to Add/Remove Programs and click on uninstall.
ReplyDeleteLMAO!
sudo aptitude remove x11vnc vnc-java