Is there a way to run a script on login irrespective of the shell? I would like to have something on the lines of the ssh login to an Ubuntu server - which displays the free RAM etc.
I understand that the welcome message itself is in
/etc/motd, but the file seems to update on each login. How is this done? I do not want to use
~/.profile and would like to have one for all users in the system by default.