Remote control of desktop

Lance DeVooght cyborghunter at gmail.com
Wed Jul 7 21:25:09 UTC 2010


Michael,

Thanks for not taking offense to the word "contradict."
I forgot to emphasize the "seem to" before that and say that I know that
it is surely a matter of my own ignorance.

I will indeed (and have begun to) read the ssh and VNC documentation.

I really appreciate the walk-through that will help a great deal.

Perhaps one (or two) last bit of clarification?
The home desktop (and only the desktop) only runs a ssh server?
And mom's laptop (and only the laptop) only runs a VNC server?

Or, put another way the laptop is a ssh client only and the desktop is
a VNC client only... yes?

Hmmm, re-reading your directions, it seems that mom's laptop would need to 
be running ssh-server also... no?

Oh, and yes, I have no given mom her laptop yet, so I still have it.

Anyway, thanks again,

Lance



Michael Hirsch wrote:

> On Wed, Jul 7, 2010 at 1:58 PM, Lance DeVooght <cyborghunter at gmail.com>
> wrote:
>> Michael,
>>
>> If I understand you correctly, then, yes that sounds like it may work.
>> However, cobbling all of those pieces together and automating it
>> with scripts will take a considerable amount of study on my part.
> 
> There is an "autossh" that may help with some of it, but there really
> isn't a whole lot here.  Practice on the command line, then paste the
> commands into a script and you are mostly done.
> 
>> I am not a new Linux user, but I have not worked with ssh and VNC,
>> not having had a need.
>>
>> Never the less, I do have a DynDNS account (that I haven't been using)
>> and I don't mind a challenge. So, I'll probably jump in and give it a
>> try.
>>
>> A few questions though please?
>>
>> You say, "I have the laptop ssh to my home system and do a remote
>> forward." I'm not sure what all of that means, but then you seem to
>> contradict it with, "For your mom you'd probably want to forward to her
>> VNC port which is 5900, I think."
> 
> Not a contradiction, but a different application.  I forward to the
> ssh port (22) because I want to ssh.  You should forward to the VNC
> port because you want to VNC.
> 
>> In addition, you describe doing ssh forwarding on your, "Host home,"  not
>> your laptop. Why?
>>
>> And, why do you do the whole, "RemoteForward 2222 localhost:22" thing?
> 
> All the "magic" of this technique is in that line.  That line in the
> .ssh/config file tells ssh that when the laptop logs in to my home
> desktop, it instructs the desktop to forward any connection to port
> 2222 on the desktop to port 22 on the laptop.  So now there is a
> tunnel from my home to my laptop, without any need to modify routers
> fiddle with DNS or anything.
> 
> I recommend reading the ssh man pages
> 
>> I mean, what's the point of port 2222?
> 
> It is what I use.  I need some port on my desktop and port 22 is
> already in use, so I chose 2222.  It can be almost anything.  I
> suggest that you use the same port number on home and laptop to reduce
> confusion.
> 
> Try this.  You'll need to have both your home system and your mom's
> system available.
> 1. Generate an ssh key for your mother.
> 2. Configure your home system and router so that she can "ssh
> lance.dyndns.org" (or whatever your home IP address is) and login to
> your machine.
> 3. On the laptop, setup her .ssh/config file so that she can login
> with just "ssh lance".  So you'll need a simple entry in the config
> file that looks like
> Host lance
>      Hostname lance.dyndns.org
> 4. Test that it works.
> 5. Add this line to the configuration your built in the previous step.
>     RemoteForward 5900 localhost:5900
> 6. "ssh lance" from the laptop and stay logged in.
> 7. Run a vnc server on the laptop on port 5900 (i.e. vnc port :0)
> 8. Test that it woks.
> 7. Try to vnc to localhost:0 from the desktop.
> 
> If all that works for you, then you just have to put steps 6 and 7
> into a script on the laptop and you are done.
> Michael
>>
>>
>> Thank you very much,
>>
>> Lance
>>
>>
>> Michael Hirsch wrote:
>>
>>> On Sat, Jun 26, 2010 at 7:38 PM, Lance DeVooght <cyborghunter at gmail.com>
>>> wrote:
>>>>
>>>> I want to be able to remotely login to her laptop and control her
>>>> desktop. That way I can fix any problems she runs into, such as the
>>>> need to install a new application. I could also use it to walk her
>>>> through any operation that she is unfamiliar with.
>>>
>>> I do this all the time.  I have a dyndns address for my home system.
>>> I have the laptop ssh to my home system and do a remote forward.  You
>>> can do it on the ssh commandline, or put it in your .ssh/config file
>>> like I do:
>>> Host home
>>> User myuser
>>> Hostname my.dyndns.address
>>> RemoteForward 2222 localhost:22
>>> so now when I connect to port 2222 on my home machine it ends up going
>>> to port 22 on my laptop.
>>>
>>> For your mom you'd probably want to forward to her VNC port which is
>>> 5900, I think.
>>>
>>> So you'd want to create a script for you mom that starts a VNC server
>>> in the background, then ssh's to your home system and port forwards
>>> from your home port 5900 to her port 5900.  Create a desktop icon for
>>> this script so she just has to click it.
>>>
>>> Then after she does that, you would vnc to localhost:0 which would get
>>> forward3ed to her vnc server and voila!  You are controlling her
>>> desktop.
>>>
>>> HTH,
>>>
>>> Michael
>>
>>
>>
>> --
>> kubuntu-users mailing list
>> kubuntu-users at lists.ubuntu.com
>> Modify settings or unsubscribe at:
>> https://lists.ubuntu.com/mailman/listinfo/kubuntu-users
>>
> 






More information about the kubuntu-users mailing list