エディタを使って、/etc/motd ファイルを開きます。
テキストを編集して、スペース、タブ、復帰改行を含めて、ユーザーログインプロセスの一部として表示されるメッセージを挿入します。
ファイルを閉じて変更結果を保存します。
/etc/motd の内容を表示して、変更結果を確認します。
$ cat /etc/motd Welcome to the UNIX Universe. Have a nice day.
Solaris ソフトウェアのインストール時に、デフォルトのその日のメッセージが設定されます。メッセージの内容は次のような SunOS バージョン情報です。
$ cat /etc/motd Sun Microsystems Inc SunOS 5.7 Generic September 1998
次の例は、編集後の /etc/motd ファイルの内容を示します。このファイルは、ログインする各ユーザーに対してシステムの利用度に関する情報を提供します。
$ cat /etc/motd The system will be down from 7:00 a.m to 2:00 p.m.on Saturday, February 28, for upgrades and maintenance. Do not try to access the system during those hours. Thank you...