When logging in, /etc/motd file is re-created by running scripts in /etc/update-motd.d directory.
For editing the header, use the file: /etc/update-motd.d/00-header
For testing the result of generating the whole motd, run:
run-parts /etc/update-motd.d/
Don't forget to escape chars in ASCII-art!;-)
Printf in my 00-header file:
printf "
_ _
(_) (_)
_ .--. __ _ _ __ __ .---. .--. _ .--..--. _ .--.
[ \`.-. | [ |[ \ [ \ [ ][ | / /'\`\]/ .'\`\ \[ \`.-. .-. |[ '/'\`\ \
| | | | | | \ \/\ \/ / | | | \__. | \__. | | | | | | | | \__/ |
[___||__][___] \__/\__/ [___]'.___.' '.__.' [___||__||__]| ;.__/
[__|
Welcome to Niwicomp - %s (%s %s %s)\n" "$DISTRIB_DESCRIPTION" "$(uname -o)" "$(uname -r)" "$(uname -m)"
Welcome to Niwicomp - %s (%s %s %s)\n" "$DISTRIB_DESCRIPTION" "$(uname -o)" "$(uname -r)" "$(uname -m)"