1. Linux 系统登录之后,显示如下
Last login: Thu Jan  :: UTC  on ttyS0
Linux xxx 4.1. # PREEMPT Wed Jul :: CST armv7l

那么这些信息是哪里获取到的呢,比如Jul19 13:15....

Kernel每次编译的时间在源码的什么位置?

include/generated/compile.h

2. Kernel版本信息存放在源码什么位置?

include/generated/utsrelease.h

3. 如何定制自己的登录前后信息?

/etc/issue, 可以选择在这里做登录提示,或者项目标志打印, 可以选择\n \l可以看到hostname和tty登录信息

/etc/issue: 登录之前提示信息

/etc/motd: 登录之后提示信息

推荐ASCII PIC制作网站:http://patorjk.com/software/taag/#p=display&f=Graffiti&t=Type%20Something%20

/etc/issue – escape code

The issue-file (/etc/issue or the file set with the -f option) may contain certain escape codes to display the system name, date and time etc. All escape codes consist of a backslash (\) immediately followed by one of the letters explained below.

\b : Insert the baudrate of the current line.
\d : Insert the current date.
\s : Insert the system name, the name of the operating system.
\l : Insert the name of the current tty line.
\m : Insert the architecture identifier of the machine, eg. i486
\n : Insert the nodename of the machine, also known as the hostname.
\o : Insert the domainname of the machine.
\r : Insert the release number of the OS, eg. 1.1..
\t : Insert the current time.
\u : Insert the number of current users logged in.
\U : Insert the string “ user” or “ users” where is the number of current users logged in.
\v : Insert the version of the OS, eg. the build-date etc.
4. 如何查看系统的登录信息和一些操作log?

/var/log/auth.log

最新文章

  1. python2.7 学习笔记--列表的使用
  2. rsync传输性能测试总结 转
  3. 5-JS函数
  4. ASP.net MVC3 报错"未找到视图“Index”或其母版视图,或没有视图引擎支持搜索的位置 "的解决方法
  5. protoc-gen-lua
  6. WSAAsyncSelect模型
  7. Android(java)学习笔记246:ContentProvider使用之学习ContentProvider(内容提供者)的目的
  8. 常用LINUX脚本汇总(1)
  9. Windows Server 2008 安装好之后的简单配置
  10. SEO-外部链接类型以及标准
  11. Android性能优化典例(二)
  12. ArcGIS API for JavaScript 4.2学习笔记[20] 使用缓冲区结合Query对象进行地震点查询【重温异步操作思想】
  13. .net 中写 psql 匿名函数、过程语言
  14. docker-machine on azure
  15. 7.5 GRASP原则五:高内聚 High Cohesion
  16. CCF-权限查询-201612-3
  17. Spring MVC实现上传文件报错解决方案
  18. notbook1.1
  19. jenkins免密添加SSH Servers
  20. 一个有趣的python排序模块:bisect

热门文章

  1. PHP生成缩略图、加水印
  2. macOS Sierra Git Gui Crash 解决方法
  3. JS如何利用定时器实现长按事件
  4. HDUOJ----(1016)Prime Ring Problem
  5. 用Python实现BP神经网络(附代码)
  6. oc Delegate
  7. [ASP.NET]HttpCookieCollection to CookieCollection的最简单方法
  8. android中调用系统的发送短信、发送邮件、打电话功能
  9. 傅立叶级数(Fourier Series)和周期现象
  10. vim打造开发IDE