查看Linux 的版本号命令:
总结几个方法哈:
uname -r

uname -a

lsb_release -a
登录到服务器执行 lsb_release -a ,即可列出所有版本信息,这个命令适用于所有的linux,包括Redhat、SuSE、Debian等发行版。

cat /etc/redhat-release
登录到linux执行cat /etc/redhat-release,这种方式下可以直接看到具体的版本号,比如:Red Hat Enterprise Linux Server release 5.1 (Tikanga)
登录到linux执行cat /etc/redhat-release,这种方式下可以直接看到具体的版本号,比如:Red Hat Enterprise Linux Server release 5.1 (Tikanga)

cat /etc/issue

cat /proc/version

rpm -q redhat-release
登录到linux执行rpm -q redhat-release
登录到linux执行rpm -q redhat-release

这种方式下可看到一个所谓的release号5.1.0.2