Ubuntu 16.04 Outdated MOTD

Over the past few months while testing some new servers running Ubuntu 16.04 LTS, we noticed that the Dynamic MOTD system seems to be outdated or completely broken when logging in via ssh. While this is a minor annoyance, it needed to be fixed. Initially we referenced our previous article Ubuntu 14.04 Outdated MOTD as a starting point. As pictured below, the solution is to log on to your server as root.  Once logged on, navigate to /etc/pam.d/sshd and search for “noupdate” and then remove it and save the file. ubuntu-16-sshd
Next we will want to delete the existing file motd.dynamic and install the required package update-motd with the commands below.

# delete stale dynamic motd
rm /var/run/motd.dynamic
# install update-motd
apt-get install update-motd

Now close your session and re-open a new one and you will notice that your Dynamic MOTD is now working like it is supposed to. On a side note, if you are running Debian Server and would like a Dynamic MOTD, see our article Debian Wheezy Dynamic MOTD or Debian Jessie Dynamic MOTD.

Did you find this article useful? Why not share it with your friends?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.