Ubuntu – How to remove the landscape.canonical.com greeting from motd

landscape

Logging into a server with ssh produces the landscape-generated message of the day, which includes the suggestion for using https://landscape.canonical.com/ to graph data:

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

How can I trim this or other lines from the ssh greeting? With legal boilerplate added to the login banner already, I'd like to keep some information from landscape-sysinfo, but see less of it.

Best Answer

To remove the landscape.canonical.com line, create or edit (as root) the file /etc/landscape/client.conf.

In /etc/landscape/client.conf, add these lines:

[sysinfo]
exclude_sysinfo_plugins = LandscapeLink 

This works for all default plugins:

 Load, Disk, Memory, Temperature, Processes, LoggedInUsers, LandscapeLink, Network

So, to have your motd look more like this :

  System load:  0.83                Swap usage:          0%
  Usage of /:   59.5% of 117.38GB   Users logged in:     3
  Memory usage: 7%                  IP address for eth0: 10.10.30.70

...you would want to remove Temperature, LandscapeLink, Processes from the landscape-sysinfo process.

These can be added in the client.conf file as before, comma separated:

[sysinfo]
exclude_sysinfo_plugins = LandscapeLink,Temperature,Processes

This can be tested one the command line with:

landscape-sysinfo --exclude-sysinfo-plugins=Temperature,LandscapeLink,Processes

See landscape-sysinfo --help for some additional information.

Related Question