bash 的进站与欢迎讯息: /etc/issue, /etc/motd
2015-06-28 17:24
513 查看
bash 也有进站画面与欢迎讯息!在终端机接口 (tty1 ~ tty6) 登入的时候,会有几行提示的字符串,那就是进站画面! 那个字符串写在 /etc/issue 里面!先来看看:
linux-peej:~ # cat /etc/issue
Welcome to SUSE Linux Enterprise Server 11 (x86_64) - Kernel \r (\l).
如果想要让使用者登入后取得一些讯息,例如想要让大家都知道的讯息, 那么可以将讯息加入 /etc/motd
里面去!例如:当登入后,告诉登入者, 系统将会在某个固定时间进行维护工作,可以这样做:
linux-peej:~ # vi /etc/motd
Hello everyone, Our server will be maintained at 2015/06/28 0:00 ~ 24:00. Please don't login server at that time. ^_^
那么当你的使用者(包括所有的一般账号与 root)登入主机后,就会显示这样的讯息出来:
Last login: Sat Jun 28 11:20:16 2015 from 192.168.137.1
Hello everyone, Our server will be maintained at 2009/02/28 0:00 ~ 24:00. Please don't login server at that time. ^_^
linux-peej:~ # cat /etc/issue
Welcome to SUSE Linux Enterprise Server 11 (x86_64) - Kernel \r (\l).
如果想要让使用者登入后取得一些讯息,例如想要让大家都知道的讯息, 那么可以将讯息加入 /etc/motd
里面去!例如:当登入后,告诉登入者, 系统将会在某个固定时间进行维护工作,可以这样做:
linux-peej:~ # vi /etc/motd
Hello everyone, Our server will be maintained at 2015/06/28 0:00 ~ 24:00. Please don't login server at that time. ^_^
那么当你的使用者(包括所有的一般账号与 root)登入主机后,就会显示这样的讯息出来:
Last login: Sat Jun 28 11:20:16 2015 from 192.168.137.1
Hello everyone, Our server will be maintained at 2009/02/28 0:00 ~ 24:00. Please don't login server at that time. ^_^
相关文章推荐
- tee命令用法小结
- shell基础
- shell脚本之脚本接收选项
- shell脚本之数组
- shell脚本编程常识
- Shell编程——基于IBM培训教程的总结
- 比较bash和perl的比较运算符
- Linux Shell学习之基础篇(不适合学习,仅为本人笔记)
- shell学习小总结----本章小结
- shell学习三十一天----函数问题
- shell脚本:猜数字游戏
- shell脚本:猜数字游戏
- shell下的一些符号问题
- shell学习三十天----break,continue,shift,getopts
- shell脚本中的引用
- shell脚本中的命令替换
- shell脚本中的输入输出
- shell awk入门
- shell学习指南-阅读笔记
- Linux Shell脚本之自动修改IP