Changing the MOTD in Ubuntu Server

Ubuntu server display a message everytime,when users log in at the terminal, this message is known as MOTD (the message of the day). Ubuntu Server generates this message automatically from a collection of scripts and motd contains the user’s last login time, the system version and information about available software updates.

Sometime, we don’t want to show all these informaitons to the login user and want to show customize message. To do this, we have to follow these steps.

First,we need to edit /etc/motd.tail file:

sudo nano /etc/motd.tail

Here is mine custom MOTD that I want to show to the users after login:

 ######################################
 # If you are not authorized to access#
 # or use this system, disconnect now #
 ######################################

Move to this directory:

cd /etc/update-motd.d

In order to disable all the unwanted information, we need to disable the execution of these scripts:

sudo chmod -x 00-header
sudo chmod -x 50-landscape-sysinfo
sudo chmod -x 10-help-text
sudo chmod -x 90-updates-available

Now, when we login to our Ubuntu Server, it will show us the MOTD that we just configured above:

Enjoy 🙂

Extra Info:

If you want that your server didn’t show MOTD at all after login, then just do this:

sudo dpkg-reconfigure landscape-common

Select “Do not display sysinfo on login”

Hope this will help you!

Please Remember me in your prayers!

3 responses to “Changing the MOTD in Ubuntu Server

  1. Pingback: Configurer motd (message of the day)

  2. chris white March 23, 2013 at 2:52 am

    thanks for that! was wanting to disable part of the motd script and add a tail!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: