LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Mobile (https://www.linuxquestions.org/questions/linux-mobile-81/)
-   -   Remotely accessing a PC with a wireless modem (https://www.linuxquestions.org/questions/linux-mobile-81/remotely-accessing-a-pc-with-a-wireless-modem-824297/)

dazz 08-05-2010 03:10 AM

Remotely accessing a PC with a wireless modem
 
Hi

I know how to set up a wireless modem (eg. Zte Mf636) on a PC to then access the internet. I want to go the other way. I want to make the connection the connection from a home PC, over the internet, to a remote PC. If I can set up the comms link, I can admin the remote PC and also grab the webcam images (stills only, no video).

This has to be data byte efficient. I will get charged for each kByte.

I want to have a webcam connected to a remote PC fitted with a wireless modem. I want to be able to make a connection to the remote PC through the internet. I do not want to allow public access to the remote PC webcam (no Apache web server). I can find lots of info on making a connection from a remote PC back to a home server. I can't find info on getting access from the internet to a remote PC.

My question is, how do I establish comms with a remote wireless PC from the internet?

Meson 08-05-2010 08:16 PM

If the computer is on, it makes no different than if it's wired. The only limitation is that you can not to Wake-On-Lan to a wireless card.

damgar 08-05-2010 10:11 PM

Sounds like a job for an ssh server, possibly with X forwarding and something like dyndns depending on your exact needs and circumstances.

http://knol.google.com/k/dirk-h-schu...ee0ik2900p/16#
http://www.faqs.org/docs/Linux-HOWTO/XDMCP-HOWTO.html

Meson 08-05-2010 10:31 PM

Quote:

Originally Posted by damgar (Post 4057466)
Sounds like a job for an ssh server, possibly with X forwarding and something like dyndns depending on your exact needs and circumstances.

http://knol.google.com/k/dirk-h-schu...ee0ik2900p/16#
http://www.faqs.org/docs/Linux-HOWTO/XDMCP-HOWTO.html

ssh yes, but x-forwarding? He wants to minimize bandwidth. XDMCP is overkill. You want to setup and ssh server and when you connect set the highest level of compression. On the server you can set up your webcam to capture pictures and deposit them in a directory (at low resolution) and then transfer them as needed over ssh.

dazz 08-05-2010 11:36 PM

As Meson suggested, I do plan to run an app that will drop images into a directory. I will just need to connect with the remote PC and pull the files back to my home PC.

The thing I don't know is how to initially setup comms with the wireless modem. In the old days, a connection to a wired modem began with calling the phone number the modem was connected to. With mobile phones that included a data mode, two mobile phones and attached PCs could be linked by dialing up the other phone.

I want to use a wireless modem connected to a USB port. I am guessing I need to connect from my home PC to the Telco gateway first (via internet) to then get access to the modem. I am guessing the other option is to connect a modem to the home PC and dial-up the remote modem/PC just like the old days.

Meson 08-06-2010 06:00 AM

Ohhh, I didn't realize what you meant by wireless modem. I kinda figured you just meant an 802.11 wireless card or something. You're probably going to have to leave it connected at all times. Hopefully your ISP doesn't generate superfluous traffic.

You'll probably need to sign up for something like DynDNS.com's free service because you're IP address will be changing regularly (but who knows, it might not and if you can remember the number you don't need to). You can get a domain name like blahblahblah.homelinux.net... Then you can get a little client to run on your computer and update dyndns with your IP address regularly. You can probably tweak the client a little bit so that it doesn't update as often as the default, to save bandwidth.

The next hurdle might be getting a port open on this modem. Your ISP may block ALL ports to the device.... I have no experience with this. The default SSH port is 22, but anything will do just fine.

At this point, your possibilities are endless. You'll just need to be extra specially careful to minimize bandwidth.

dazz 08-06-2010 05:38 PM

Hi

I run IPCop firewall and the logs show lots of hits from random sources. All this traffic would burn up my data allocation on a remote wireless PC if was always on the network.

I guess I could do this the other way round and have the remote PC initiate the connection with chron jobs and SSH into my web server (that I am in the process of getting on line), then upload the stills from the webcam. This would avoid leaving the remote PC always connected.

Alternatively, I could get the remote PC to email the images,then I don't need a web server. I only want images sent about once an hour. This method should help minimise data overhead.

With both of these methods, I would still have the problem of making a SSH connection so I can administer the remote PC. I guess I could do this with a chron job that connected to the network at specific times so I could then SSH into the remote PC.

I will ask the telco what they will let through. They may well filter out all the general internet dross to avoid clogging their network. If so I might be able to leave the modem always on.

These wireless modems have a sim card and phone number. It should be possible to call up and make a data connection.

I can't be the only person on the planet that has this problem. There must be a solution.

damgar 08-06-2010 09:00 PM

Quote:

Originally Posted by Meson (Post 4057474)
ssh yes, but x-forwarding? He wants to minimize bandwidth. XDMCP is overkill. You want to setup and ssh server and when you connect set the highest level of compression. On the server you can set up your webcam to capture pictures and deposit them in a directory (at low resolution) and then transfer them as needed over ssh.

That's whay I said possibly.

If dumping files is all you need, then the simplest thing to do is just set up a cron job that does something like
Code:

scp /path/to/directory/with/stills/* user@remote-host:/path/to/dump/stills
with an && to move or delete the stills.

Meson 08-06-2010 09:37 PM

+1 on letting the remote pc initiate the connection via a cron job. Bringing down the modem will be big on saving bandwidth. You'll probably need to do a bit more than just run scp or rsync directly.

Your script will need to:

1. Bring up your modem and get a connection to the internet.

2. Ensure the connection is established.

3. Do the transfer (scp or rsync most likely).

4. Bring down the connection.

The more error checking you do the better.

You also might want to capture the shots at the highest resolution/quality and also save a copy with reduced res/quality for the transfer. You can do it as step 0 or as part of the routine that does the capture. Then if you want the highest res, you can pick them up whenever you have physical access.


All times are GMT -5. The time now is 07:45 AM.