The server I administrate, inconveniently enough, has a dynamic IP address assigned by DHCP. The convenient counterbalance, though, is that it happens to be set up about two feet from where I sit. I know how to edit /etc/issue to show different values before the login prompt is delivered to the display, but I'd like to know if it's possible for /etc/issue to display the current IP address of eth0 (re-evaluated at boot time) so that I can see it and then ssh in without having to log in to run ifconfig.
/etc/issue is unfortunately a plain text, it has some options you can add to it (see man agetty) but not the IP Address of eth0..
If you put this in /etc/rc.local:
Then you will see something like this:
Building on Alex's answer and Rebs' comment, this is what I have for my
So long story short, these 4 lines keep the original info displayed by
And as Rebs' said, keep in mind that every time you reboot the server, this script will override the
Good luck and happy BASHing :)