motd - message of the day

How to change your motd when you log into your system. On a standard debian box you normally see something like this:

Linux 2.6.32-amd64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.

Last login: Mon Feb 13 09:25:06 2012 from xx.xx.xx.xx

How to change that?

Modifying /etc/motd directly will not work because this is acutally a link to /var/run/motd

You have to edit /etc/motd.tail. On every boot your motd is generated by /etc/init.d/bootlogs like so:

uname -snrvm > /var/run/motd
[ -f /etc/motd.tail ] && cat /etc/motd.tail >> /var/run/motd

Instead the default you might want to use someting like this:

/etc/motd.tail
------------------------------------------------------------------------------
    You are on a private system.
    Unauthorized use is prohibited, all activity is monitored.
------------------------------------------------------------------------------

motd described above works for Debian Squeeze - with Wheezy things are a little bit different!

linux/motd.txt · Last modified: 2014-02 by tb
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0 ipv6 ready