Skip to content


OpenSSH seeing double in Ubuntu 10.04 LTS? Dealing with the “motd issue”.

I’ve had that annoying issue for a while on this very server: after some update of Ubuntu 10.04, the SSH welcome message (with system load, disk usage, updates needed and everything) right after the log-in prompt became doubled. That was particularly a pain since the “duplicated” welcome screen was in fact static, always displaying outdated information, like that:

Linux s15429750 2.6.32-25-generic-pae #45-Ubuntu SMP Sat Oct 16 21:01:33 UTC 2010 i686 GNU/Linux
Ubuntu 10.04.2 LTS

Welcome to Ubuntu!
* Documentation: https://help.ubuntu.com/

System information as of Sat Jun 11 09:54:52 CEST 2011

System load: 0.86 Processes: 109
Usage of /home: 84.6% of 12.99GB Users logged in: 1
Memory usage: 42% IP address for eth0: 82.165.148.117
Swap usage: 1%

Graph this data and manage this system at https://landscape.canonical.com/

6 packages can be updated.
3 updates are security updates.

I eventually found out that this is due to some junk (some copy of the welcome message) making its way into /etc/motd.tail, which is shown at the end of the “real” welcome message. So just empty this file (or replace it with whatever content you wish) to get rid of the double message.

On a side note, you can modify what’s output by motd by editing the scripts in /etc/update-motd.d. A dirty way to disable it is to set those scripts as non-executable: chmod -x * but maybe add back the header to display kernel version: chmod +x 00-header

Sources:

Posted in Linux, servers.


0 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.



Some HTML is OK

or, reply to this post via trackback.

Please solve the CAPTCHA below in order to fight spamWordPress CAPTCHA