How to set up/manage services on a computer

629 B

Customize your login message (MOTD)

Static MOTD

If you just want to print a static message, put it in /etc/motd.

Dynamic MOTD

If you want to print a dynamic message, it gets a bit more complicated.

Disable other MOTD methods

First, make sure to disable other ways via which the MOTD is set.

Make sure the MOTD service is disabled:

systemctl disable motd

Delete the static motd file:

rm /etc/motd

configure dynamic scripts

The dynamic MOTD is printed by executing the scripts in /etc/update-motd.d, in numerical/alphabetical order. Simply put any scripts you want to be run in there.