wpa_supplicantwas installed and then I had to edit:
Adding the part in red below
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
iface lo inet loopback
# The primary network interface
iface eth0 inet dhcp
iface wlan0 inet static
Then I added
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
# In order to enable or disable this script just change the execution
# By default this script does nothing.
I had to make
to do that I did:
chmod +x /etc/rc.local
/root/.webcamrc trailing webcam is the config file I want it use
The final thing was to write a script that would email and text me if the server went down.Using
ping, grep and sendEmail
ping -c 5 192.168.0.0 > ping.log ;
GREP_STRING=`grep -c Unreachable /home/USERNAME/.logs/ping.log`
if [ $GREP_STRING -ne 0 ]
(sendEmail -t firstname.lastname@example.org -t email@example.com -f firstname.lastname@example.org -u "Dog Cam" -m "Down" -s smtp.send.com -xu EMAIL-USERNAME -xp EMAIL-PASSWORD)
So I set up crontab:
*/5 * * * * /usr/bash /home/USERNAME/.bashscripts/servernotify.sh
Done for now.