原文网址:http://www.shangxueba.com/jingyan/121649.html
查看ubuntu版本号
方法一:
cat /etc/issue
返回结果:
Ubuntu 6.06.2 LTS \n \l
方法二:
sudo lsb_release -a
返回结果:
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 6.06.2 LTS
Release: 6.06
Codename: dapper
方法三:
cat /etc/lsb-release
返回结果:
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=6.06
DISTRIB_CODENAME=dapper
DISTRIB_DESCRIPTION="Ubuntu 6.06.2 LTS"
方法四:
cat /proc/version
返回结果:
Linux version 2.6.15-51-386 ([email protected]) (gcc version 4.0.3 (Ubuntu 4.0.3-1ubuntu5)) #1 PREEMPT Tue Oct 23 21:42:16 UTC 2007
方法五:
uname -a
返回结果:
Linux jpsiteserver 2.6.15-51-386 #1 PREEMPT Tue Oct 23 21:42:16 UTC 2007 i686 GNU/Linux
方法六:仅仅查看内核版本
uname -r
返回结果:
2.6.15-51-386
1、查看内核版本命令:
1) cat /proc/version
2) uname -a
3) uname -r
2、查看发行版本命令
1) lsb_release -a
2) 用命令找到/etc目录下的issue文件release文件