Send mail with ssmtp over SSL GMail on OpenWRT (updated)

Install (thx Mike, for upd):

opkg install msmtp 
opkg install ca-certificates

Edit /etc/msmtprc:

defaults
tls on
tls_starttls on
tls_trust_file /etc/ssl/certs/GeoTrust_Global_CA.crt
account default
host smtp.gmail.com
port 587
auth on
user username@gmail.com
password your_password
from username@gmail.com
logfile /var/log/msmtp.log

Test:

echo -e "Subject: Test Mail\r\n\r\nThis is a test mail" |msmtp --from=default -t username@gmail.com

If problem, add “–debug” to msmtp params.

Ubuntu Linux lost password, change root password from boot

  1. Reboot your computer
  2. Press SHIFT or ESC at the grub prompt (as earlier)
  3. Select your image, and highlight the line that begins kernel and press ‘e’ to edit
  4. Go to the very end of the line, change the ro to rw and add init=/bin/bash press enter, then press b to boot your system. Your system will boot up to a passwordless root shell
  5. Type in passwd username