[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: ssh again



On Tue, 14 Jun 2016 19:23:23 +0200
Jörg-Volker Peetz <jvpeetz@web.de> wrote:

> Lisi Reisz wrote on 06/14/16 16:32:
> <snip>
> > After all this, my main motivation for learning right now was to
> > ssh into two computers that I administer 11 miles away, without
> > having to bother the owners (I would just have to say: leave your
> > computers turned on), and I'm not going to be able to do it, I
> > think, because their ISP uses dynamic IPs. :-(  (I have a static
> > IP.)  
> 
> That's where Dynamic DNS comes to aid, see
> https://en.wikipedia.org/wiki/Dynamic_DNS . Just choose a free DynDNS
> provider, like no-ip, and a web-hostname.
> 

Or for a bit of bash practice, you can do it yourself. A couple of years
ago, I needed to track a dynamic IP for a couple of months, until a
fixed one was organised. I ran this on the client's Linux server with a
cron job once an hour:

wget -qO- http://ipecho.net/plain | /usr/bin/mutt -s "IP report"
joe@jretrading.com

I did actually get a bit creative later, and automated the moving of
the address from the latest email into my workstation's /etc/hosts
file, but I made use of a web server, which you may not have in your own
network, and my IMAP processing script was in php. A semi-automatic
method would be to save the latest email as a text file, and run a bash
script to pick out the address and poke it into the local /etc/hosts.

-- 
Joe


Reply to: