How set the Message of the Day (MOTD) as Ubuntu Server?
It looks like the /etc/update-motd.d
directory can no longer have links to the scripts. (This happened to the Cronjob directories a number of release back, and is part of the security stuff I would guess).
If you list the directory (ls -l /etc/update-motd.d
) you will see the following
50-landscape-sysinfo -> /usr/share/landscape/landscape-sysinfo.wrapper
If you want the System information back just copy the script into /etc/update-motd.d
with the following command.
$ sudo cp /usr/share/landscape/landscape-sysinfo.wrapper /etc/update-motd.d/52-landscape-sysinfo
Note that when landscape fixes the problem you will get two copy of the script and then you can just delete the file.
The text displayed (Message of the Day, MOTD) is created by running in numerical order the scripts in /etc/update-motd.d
and joining together the output. I'm not certain which package contains the difference between the server and desktop versions, but you should be able to edit those scripts, or add new ones to create whatever message you want.
You can output things manually by
sudo run-parts /etc/update-motd.d/
Normally the only way to update the file is by triggering pam_motd and on 'standard' ubuntu systems the services 'login' and 'sshd' do that.
Look at
grep pam_motd /etc/pam.d/*
if you want to know more. If you want to update /etc/motd you can redirect the output there:
run-parts /etc/update-motd.d/ | sudo tee /etc/motd
To speed up logins you can switch from libpam-motd to update-motd. Update-motd uses a cronjob instead of triggering the update on login. sudo apt-get remove libpam-motd; sudo apt-get install update-motd
Hope that helps somebody.