1.查看Linux内核版本
1.1 $ cat /proc/version
[heima01@heima01 ~]$ cat /proc/version
Linux version 2.6.32-573.el6.i686 (mockbuild@c6b9.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16) (GCC) ) #1 SMP Thu Jul 23 12:37:35 UTC 2015 [root@frxx ~]# cat /proc/version
Linux version 3.10.0-957.1.3.el7.x86_64 (mockbuild@kbuilder.bsys.centos.org) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-36) (GCC) ) #1 SMP Thu Nov 29 14:49:43 UTC 2018 1.2 $ uname -a
解释:x86_64表示Linux是64位版本的,i686 i386表示是32位版本的。
[heima01@heima01 ~]$ uname -a
Linux heima01 2.6.32-573.el6.i686 #1 SMP Thu Jul 23 12:37:35 UTC 2015 i686 i686 i386 GNU/Linux [root@frxx ~]# uname -a
Linux frxx 3.10.0-957.1.3.el7.x86_64 #1 SMP Thu Nov 29 14:49:43 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux 1.3 $ uname -r
[heima01@heima01 ~]$ uname -r
2.6.32-573.el6.i686 [root@frxx ~]# uname -r
3.10.0-957.1.3.el7.x86_64 2.查看Linux发行版本
2.1 $ lsb_release -a
[heima01@heima01 ~]$ lsb_release -a
LSB Version: :base-4.0-ia32:base-4.0-noarch:core-4.0-ia32:core-4.0-noarch:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-ia32:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 6.7 (Final)
Release: 6.7
Codename: Final 2.2 $ cat /etc/issue
[heima01@heima01 ~]$ cat /etc/issue
CentOS release 6.7 (Final)
Kernel \r on an \m 2.3 $ cat /etc/redhat-release
$ cat /etc/*release*
[heima01@heima01 ~]$ cat /etc/redhat-release
CentOS release 6.7 (Final) [heima01@heima01 ~]$ cat /etc/*release*
CentOS release 6.7 (Final)
LSB_VERSION=base-4.0-ia32:base-4.0-noarch:core-4.0-ia32:core-4.0-noarch:graphics-4.0-ia32:graphics-4.0-noarch:printing-4.0-ia32:printing-4.0-noarch
cat: /etc/lsb-release.d: Is a directory
CentOS release 6.7 (Final)
CentOS release 6.7 (Final)
cpe:/o:centos:linux:6:GA
     2.4 $ rpm -qi centos-release

[root@localhost ~]# rpm -qi centos-release
Name : centos-release
Version : 7
Release : 5.1804.el7.centos
Architecture: x86_64
Install Date: Wed 17 Jul 2019 05:33:06 PM CST
Group : System Environment/Base
Size : 40173
License : GPLv2
Signature : RSA/SHA256, Tue 01 May 2018 12:17:56 AM CST, Key ID 24c6a8a7f4a80eb5
Source RPM : centos-release-7-5.1804.el7.centos.src.rpm
Build Date : Sun 29 Apr 2018 12:35:55 AM CST
Build Host : x86-01.bsys.centos.org
Relocations : (not relocatable)
Packager : CentOS BuildSystem <http://bugs.centos.org>
Vendor : CentOS
Summary : CentOS Linux release file
Description :
CentOS Linux release files

3.查看是否联网
$ ping www.baidu.com
使用:
因为使用yum工具安装软件可能需要网络。 1.没有联网
[heima01@heima01 ~]$ ping www.baidu.com
PING www.a.shifen.com (182.61.200.6) 56(84) bytes of data.
^Z
[2]+ Stopped ping www.baidu.com
2.已经联网
[root@instance-fjii60o3 ~]# ping www.baidu.com
PING www.a.shifen.com (220.181.38.150) 56(84) bytes of data.
64 bytes from 220.181.38.150 (220.181.38.150): icmp_seq=1 ttl=53 time=3.69 ms
64 bytes from 220.181.38.150 (220.181.38.150): icmp_seq=2 ttl=53 time=3.50 ms
64 bytes from 220.181.38.150 (220.181.38.150): icmp_seq=3 ttl=53 time=3.66 ms 4.查看CPU信息
# cat /proc/cpuinfo [root@frxx ~]# cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 85
model name : Intel(R) Xeon(R) Gold 6148 CPU @ 2.40GHz
stepping : 4
microcode : 0x1
cpu MHz : 2399.996
cache size : 28160 KB
physical id : 0
siblings : 1
core id : 0
cpu cores : 1
apicid : 0
initial apicid : 0
fpu : yes
fpu_exception : yes
cpuid level : 13
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon rep_good nopl eagerfpu pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch ibrs ibpb fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm mpx avx512f rdseed adx smap clflushopt clwb avx512cd xsaveopt xsavec xgetbv1 arat spec_ctrl
bogomips : 4799.99
clflush size : 64
cache_alignment : 64
address sizes : 40 bits physical, 48 bits virtual
power management: [root@heima01 heima01]# cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 158
model name : Intel(R) Core(TM) i5-7300HQ CPU @ 2.50GHz
stepping : 9
microcode : 142
cpu MHz : 2496.002
cache size : 6144 KB
physical id : 0
siblings : 1
core id : 0
cpu cores : 1
apicid : 0
initial apicid : 0
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 22
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss nx pdpe1gb rdtscp lm constant_tsc up arch_perfmon xtopology tsc_reliable nonstop_tsc unfair_spinlock pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch arat xsaveopt fsgsbase bmi1 avx2 smep bmi2 invpcid rdseed adx
bogomips : 4992.00
clflush size : 64
cache_alignment : 64
address sizes : 43 bits physical, 48 bits virtual
power management: 5.查看Linux操作系统位数
$ getconf LONG_BIT [heima01@heima01 ~]$ getconf LONG_BIT
32
[root@frxx ~]# getconf LONG_BIT
64

Linux命令 查看Linux版本和是否联网的更多相关文章

  1. [Linux命令]查看Linux系统相关命令

    #查看系统内核/操作系统/CPU信息 uname -a #返回:内核名 主机名 Linux内核版本 内核编译日期 操作系统版本 CPU型号 硬件平台 GNU/Linux#查看系统是32位还是64位un ...

  2. Linux命令 -- 查看系统版本的各种方法

    适用于CentOS

  3. 如何用linux命令查看nginx是否在正常运行

      有时想知道nigix是否在正常运行,需要用linux命令查看nginx运行情况. 执行命令: ps -A | grep nginx  如果返回结果的话,说明有nginx在运行,服务已经启动. 如果 ...

  4. linux服务器查看redis版本:

    linux服务器查看redis版本:redis-server-v

  5. 20个Linux命令及Linux终端的趣事

    20个Linux命令及Linux终端的趣事 . 命令:sl (蒸汽机车) 你可能了解 ‘ls’ 命令,并经常使用它来查看文件夹的内容.但是,有些时候你可能会拼写成 ‘sl’ ,这时我们应该如何获得一些 ...

  6. Linux系统查看系统版本命令

    以下操作在centos系统上实现,有些方式可能只适用centos/redhat版本系统 uname -a |uname -r查看内核版本信息 [root@node1 ~]# uname -a Linu ...

  7. linux上查看系统内核版本命令(转载)

    uname -a uname -r 查看发行版本信息: 在RedHat系统里,存在一个/etc/redhat-release文件,里面保存了发行版的版本信息 $cat /etc/redhat-rele ...

  8. Linux中查看jdk版本

    linux查看java jdk安装路径和设置环境变量 windows: set java_home:查看JDK安装路径 java -version:查看JDK版本 linux: whereis jav ...

  9. 在linux下查看内核版本、gcc版本、操作系统多少位等参数

    1. 查看linux版本 cat /etc/issue Ubuntu 11.04 \n \l 2. 查看内核版本 1)cat /proc/version Linux version 2.6.38-13 ...

随机推荐

  1. 关于Dubbo

    什么是Dubbo 一款分布式服务框架 高性能和透明化的RPC远程服务调用方案 SOA服务治理方案 每天为2千多个服务提供大于30亿次访问量支持,并被广泛应用于阿里巴巴集团的各成员站点以及别的公司的业务 ...

  2. BZOJ 1232 [Usaco2008Nov]安慰奶牛cheer:最小生成树【树上dfs性质】

    题目链接:http://www.lydsy.com/JudgeOnline/problem.php?id=1232 题意: 给你一个无向图,n个点,m条边. 每条边有边权len[i][j],每个点有点 ...

  3. 连接并同步windows下的git仓库

    1. 需求 电脑A和电脑B本来通过服务器同步工作目录.服务器时linux系统上有个裸仓库,不管在A上还是B上工作,工作完毕后使用git go与服务器仓库同步.A和B都是windows系统,在工作目录下 ...

  4. centos7下面搭建lnmp环境

    参考大神博客: http://www.linuxzen.com/lnmphuan-jing-da-jian-wan-quan-shou-ce-si-lnmpda-jian-yuan-ma-an-zhu ...

  5. Eclipse_配置_00_资源帖

    1.Eclipse常用设置 2.eclipse设置和优化 3.Eclipse在工作中的一些常用设置及快捷键整理 4.Eclipse常用插件下载地址

  6. form 提交数据编码梳理

    之前对form单提交的操作一直都是迷迷糊糊,知道怎么用,但是随着ajax2的出现,我们有更多的方式操作form表单提交,但是底层的原理我们要好好的做个梳理. 常见的form提交有post和get这两种 ...

  7. hdu-5784 How Many Triangles(计算几何+极角排序)

    题目链接: How Many Triangles Time Limit: 10000/5000 MS (Java/Others)    Memory Limit: 65536/65536 K (Jav ...

  8. 机器学习:simple linear iterative clustering (SLIC) 算法

    图像分割是图像处理,计算机视觉领域里非常基础,非常重要的一个应用.今天介绍一种高效的分割算法,即 simple linear iterative clustering (SLIC) 算法,顾名思义,这 ...

  9. 【Lintcode】122.Largest Rectangle in Histogram

    题目: Given n non-negative integers representing the histogram's bar height where the width of each ba ...

  10. Linux系统上php-cli安装redis扩展

    下载 假设已经安装了redis-server,现在我们来安装redis扩展. 下载ZIP包: https://github.com/phpredis/phpredis/tree/master . 解压 ...