Created
June 12, 2017 11:45
-
-
Save hitesh83/75c1641e759a27c5faaab7a383d61079 to your computer and use it in GitHub Desktop.
Odroid info
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
***set time zone | |
sudo dpkg-reconfigure tzdata | |
** update software | |
sudo apt update && sudo apt upgrade -y | |
sudo apt install linux-image-c2 -y | |
and change from <Yes> to <No> in the upcoming dialogue: | |
*** install mail utils | |
sudo apt-get install mailutils ssmtp -y && sudo apt-get install dnsutils -y && sudo apt-get install libpng12-dev -y && sudo apt-get install mutt | |
*** config smtp servers | |
sudo nano /etc/ssmtp/ssmtp.conf | |
[email protected] | |
mailhub=smtp.gmail.com:587 | |
[email protected] | |
AuthPass=yourpass | |
UseTLS=YES | |
UseSTARTTLS=YES | |
AuthMethod=LOGIN | |
**Config Root mail id | |
sudo nano /etc/ssmtp/revaliases | |
root:[email protected]:smtp.gmail.com:587 | |
*** script for getting data | |
<script for DATA> | |
#!/bin/bash | |
(echo "Current Date & time" && date && echo && echo "Uptime" && uptime -p && echo && free | grep Mem | awk '{print "Free RAM in MB= "$4/$2 * 100.0}' && echo && echo "cpu temp=" && cat /sys/class/thermal/thermal_zone0/temp && echo && echo CPU Freq && cat /sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_cur_freq ) | |
if [ -s file.tmp ] | |
then | |
mail -s "mail subject" -- [email protected] <file.tmp | |
fi | |
rm file.tmp | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment