These are scripts to check if the IP addresses of a given machine in a dynamic IPs network have changed. It sends e-mails if a change is detected.
In a linux terminal, execute the following commands:
cd /home/pi
git https://github.com/HaraldoFilho/pi_utils.git
cd pi_utils/check_ip_changes
mv _config.sh config.sh
Open the file config.sh for edit and include the from and to e-mail addresses in its respective variables.
There are two scripts to run:
The scripts don’t provide any output in the terminal, if a change has been detected an e-mail will be sent with the new IP.
TIP: To periodically check for changes, include one of the scripts in the user’s crontab. Do not include in the root crontab, because the script will not run.