/etc/issue 与 /etc/motd 作用一致,都是用于显示欢迎信息,区别在于 /etc/issue 是在 login 提示符之前显示,而 /etc/motd 则在在用户成功登录系统之后显示

[root@localhost ~]$ cat /etc/issue
\S
Kernel \r on an \m

/etc/issue

可用的代码:

/l  显示第几个终端机接口
/m  显示硬件的等级(i386/i686...)
/n  显示主机的网络名称
/o  显示 domain name
/r  显示操作系统的版本/t  显示本地端时间的时间
/s  显示操作系统的名称
/v  显示操作系统的版本

另外,还有一个 /etc/issue.net 文件,/etc/issue 针对本地登录,/etc/issue.net 针对远程网络登录(通过ssh或telnet等)

如果要让 /etc/issue.net 生效,还需要先配置 /etc/ssh/sshd_config 的 Banner 属性,而且,/etc/issue.net 只会输出原始数据,不会自行转换

/etc/issue

/etc/issue

 

 

 

 

 

       

相关文章:

  • 2021-08-30
  • 2022-03-07
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-06-12
  • 2021-06-19
  • 2022-12-23
  • 2022-12-23
  • 2021-06-01
相关资源
相似解决方案