码迷,mamicode.com
首页 > 系统相关 > 详细

Shell中uname命令查看系统内核、版本

时间:2019-06-19 12:24:42      阅读:297      评论:0      收藏:0      [点我收藏+]

标签:tin   net   int   x86   lin   -o   version   用法   处理   

uname命令

    描述

    用于打印内核名称和版本、主机名等系统信息。

    用法

uname   [OPTION]...

 
参数     用法

-a     print all information
-s     print the kernel name
-n     print the network node hostname
-r     print the kernel release
-v     print the kernel version
-m     print the machine hardware name
-p     print the processor type or “unknown”
-i     print the hardware platform or “unknown”
-o     print the operating system

 
默认uname命令只打印内核的名称

[root@test ~]# uname
Linux

 
只打印系统的主机名(与hostname命令相同)

[root@test ~]# uname -n
test.xuptip.com

 
打印内核版本信息

[root@test ~]# uname -r
3.10.0-123.el7.x86_64

 
打印系统的硬件名称

[root@test ~]# uname -m
x86_64

 
打印系统的处理器类型的信息

[root@test ~]# uname -p
x86_64

 
打印系统的硬件平台信息

[root@test ~]# uname -i
x86_64

 
打印上述所有信息

[root@test ~]# uname -a
Linux test.xuptip.com 3.10.0-123.el7.x86_64 #1 SMP Mon May 5 11:16:57 EDT 2014 x86_64 x86_64 x86_64 GNU/Linux

 



Shell中uname命令查看系统内核、版本

标签:tin   net   int   x86   lin   -o   version   用法   处理   

原文地址:https://www.cnblogs.com/kangleweb/p/11050435.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!