3DX'yd2m0
51Testing软件测试网]]j.H
ji*N4NjG!kg
51Testing软件测试网8t`$ou?WcE
--写在开始--4A@5RtP0
服务器入门篇~4z(vc*{V([0
玩Linux,不同的版本会有一些细微区别;51Testing软件测试网KOY!IE#\#v-C"p
so,经常需要查看服务器版本号;51Testing软件测试网,\j3y}$k7C
*x-S6{v8h%Y8Z051Testing软件测试网)v!}2O@7qH)pM*FA
)p:h"o_?lth1K-i0
--正文--N8X5m#C,By,C:z/H0
有以下命令可以查看linux服务器版本号:6Ay(p$pL*~c0
%uw%]T:K{L)DQ0
# lsb_release -a51Testing软件测试网5lPzA1m6S6{r9r)l6L
LSB Version::base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch51Testing软件测试网(ABWErR
Distributor ID:CentOS%X_kV'A0
Description:CentOS release 6.5 (Final)6q$d0{"G'ZA0
Release:6.551Testing软件测试网\4e3t+~HpG6@6m&w3RsoV
Codename:Final7g9D/`1c)d0]0
I;ecp{;i4c%w0
51Testing软件测试网4OO(@9}U#z
这个命令适用于所有的linux,包括Redhat、SuSE、Debian等发行版。51Testing软件测试网$L2E
\TV` s@:a
root@idolaoxu ~ # uname51Testing软件测试网p,g;tA4E.u7tB5H
Linux51Testing软件测试网&P,R\.s \
root@idolaoxu ~ # uname -rSXnfL h9sX6j0
2.6.18-164.el551Testing软件测试网_rz9T dRb&M
[root@idolaoxu ~]# uname -aG/I1G^r-D,ZG\0
Linux iZ94b31ttqsZ 2.6.32-431.23.3.el6.x86_64 #1 SMP Thu Jul 31 17:20:51 UTC x86_64 x86_64 x86_64 GNU/Linux51Testing软件测试网$z&?1hfJ-K6wD
Jp,RNU?^0
以下二种方法适用于RedHat,CentOS*_ilBA0
51Testing软件测试网'k9c;a-H\Y/}
root@idolaoxu ~ # cat /etc/redhat-release51Testing软件测试网!i/?3f'^HXON
CentOS release 5.4 (Final)51Testing软件测试网|b5Nk-y"L,t
51Testing软件测试网1U(A;Ut.t0[x2q:g"W
AFl^9{mW+frby0
51Testing软件测试网Q/yI+Lz
登录到linux执行rpm -q redhat-releaser'pir_!vb0
51Testing软件测试网3c0h)s9G;h
#rpm -q redhat-releaseuN,}urNNK0
或CentOSC$KZzY^n0
51Testing软件测试网$jb#a
o sY;A$X9R
root@idolaoxu ~ # rpm -q centos-release[@iY$p*}0
centos-release-5-4.el5.centos.1tP y1BC\z.o KM1_0
如果觉得《linux测试怎样看 linux入门篇:如何查看centos版本》对你有帮助,请点赞、收藏,并留下你的观点哦!