[clug] Fixed IP or dynamic
Stephen.Gibson at anu.edu.au
Mon May 4 17:38:57 MDT 2015
For the dynamic IP address access, I use the following shell script
(taken from the raspberry pi forums), run as a cron job every 15
minutes, to email any IP address changes.
EMAIL="your email address"
read ip1 < ip.txt
ip2=$(wget -qO- ifconfig.me/ip)
if [ -z "$ip2" ]
if [ "$ip1" = "$ip2" ]
echo "$ip2" > ip.txt
echo "$ip2" | mail -s $SUBJ $EMAIL
More information about the linux