Tuesday, August 10, 2010

How to put banner when user logging.

Display banner when user logged as root.
  1. Open this with text editor /root/.bash_profile
  2. Then include text, you want to show with echo command at the end of file as follows,
    echo "My banner".
  3. You can use this commad to show ip of the host
    "ifconfig eth0 | grep 'inet' | awk '{print $2}' | sed 's/addr://'"