linux查看显卡信息_Linux硬件信息查看(2)—内存条 硬盘 pci 网卡 - Go语言中文社区

linux查看显卡信息_Linux硬件信息查看(2)—内存条 硬盘 pci 网卡


ab47bec64acc21f0a7b8e68e0e39020c.png

一、查看内存信息
(1)查看内存硬件信息

root@Master ~]# dmidecode -t memory | head -45 | tail -24Handle 0x000C, DMI type 17, 40 bytesMemory Device        Array Handle: 0x000A        Error Information Handle: Not Provided        Total Width: 72 bits        Data Width: 64 bits        Size: 16384 MB        Form Factor: DIMM        Set: None        Locator: PROC 1 DIMM 1        Bank Locator: Not Specified        Type: DDR4        Type Detail: Synchronous Registered (Buffered)        Speed: 2133 MHz        Manufacturer: HP             Serial Number: Not Specified        Asset Tag: Not Specified        Part Number: 752369-081        Rank: 2        Configured Clock Speed: 2133 MHz        Minimum Voltage:  1.2 V        Maximum Voltage:  1.2 V        Configured Voltage:  1.2 V

 (2)最大支持多少内存

[root@Master ~]# dmidecode|grep -P 'Maximums+Capacity'

d9a2ef026e7f17d50c920f2c652a18e3.png(3)Linux 查看内存的插槽数,已经使用多少插槽.每条内存多大:

bef2b68744245a1c9076208e5afa29a3.png

 (4)Linux 查看内存的频率:
[root@Master ~]# dmidecode|grep -A16 "Memory Device"|grep 'Speed'

f01155c5362ee33c7707e96a82b7da5d.png

(5)Linux 查看内存的详细信息:

[root@Master ~]# cat /proc/meminfo |head -20MemTotal:       131897620 kBMemFree:          414124 kBBuffers:         1040560 kBCached:         111083180 kBSwapCached:         1320 kBActive:          7637912 kBInactive:       110607108 kBActive(anon):    4406900 kBInactive(anon):  1714900 kBActive(file):    3231012 kBInactive(file): 108892208 kBUnevictable:    10878976 kBMlocked:         5521652 kBSwapTotal:      16777212 kBSwapFree:       16737536 kBDirty:               180 kBWriteback:             0 kBAnonPages:      16999324 kBMapped:           149020 kBShmem:               172 kB

(6)Linux 查看内存的使用情况

[root@Master ~]# free -m    // -b,-k,-m,-g show output in bytes, KB, MB, or GBtotal       used       free     shared    buffers     cachedMem:        128806     123407       5398          0       1015     103474-/+ buffers/cache:      18918     109888Swap:        16383         38      16345

  二、查看硬盘信息
(1)查看挂接的分区状态

[root@Master ~]# fdisk -l |grep Disk

b8277ca0a0f2e62030d3d4c24bd3fde4.png

(2)查看硬盘和分区分布

[root@Master ~]# lsblkNAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINTsda      8:0    0 279.4G  0 disk ├─sda1   8:1    0    50M  0 part /boot├─sda2   8:2    0   100G  0 part /├─sda3   8:3    0    50G  0 part /home├─sda4   8:4    0     1K  0 part ├─sda5   8:5    0    16G  0 part [SWAP]├─sda6   8:6    0  13.3G  0 part /tmp└─sda7   8:7    0   100G  0 part /usrsdb      8:16   0  83.7T  0 disk └─sdb1   8:17   0  83.7T  0 part /PureDisk

(3)查看硬盘和分区的详细信息

[root@Master ~]# fdisk -l           Disk /dev/sda: 300.0 GB, 299966445568 bytes255 heads, 63 sectors/track, 36468 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 262144 bytes / 262144 bytesDisk identifier: 0x000384d9 Device Boot      Start         End      Blocks   Id  System/dev/sda1   *           1           7       51200   83  LinuxPartition 1 does not end on cylinder boundary./dev/sda2               7       13061   104857600   83  Linux/dev/sda3           13061       19588    52428800   83  Linux/dev/sda4           19588       36469   135597056    5  Extended/dev/sda5           19588       21677    16777216   82  Linux swap / Solaris/dev/sda6           21677       23415    13962240   83  Linux/dev/sda7           23416       36469   104854528   83  LinuxWARNING: GPT (GUID Partition Table) detected on '/dev/sdb'! The util fdisk doesn't support GPT. Use GNU Parted.Disk /dev/sdb: 92017.3 GB, 92017310654464 bytes255 heads, 63 sectors/track, 11187134 cylindersUnits = cylinders of 16065 * 512 = 8225280 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 262144 bytes / 6029312 bytesDisk identifier: 0x00000000 Device Boot      Start         End      Blocks   Id  System/dev/sdb1               1      267350  2147483647+  ee  GPTPartition 1 does not start on physical sector boundary.

(4)查看挂接的分区状态

[root@Master ~]# mount | column -t/dev/sda2  on  /                         type  ext4         (rw)proc       on  /proc                     type  proc         (rw)sysfs      on  /sys                      type  sysfs        (rw)devpts     on  /dev/pts                  type  devpts       (rw,gid=5,mode=620)tmpfs      on  /dev/shm                  type  tmpfs        (rw)/dev/sda1  on  /boot                     type  ext4         (rw)/dev/sda3  on  /home                     type  ext4         (rw)/dev/sda6  on  /tmp                      type  ext4         (rw)/dev/sda7  on  /usr                      type  ext4         (rw)/dev/sdb1  on  /PureDisk                 type  ext4         (rw)none       on  /proc/sys/fs/binfmt_misc  type  binfmt_misc  (rw

(5)查看挂接的分区状态

[root@Master ~]# swapon -s   Filename      Type          Size    Used    Priority/dev/sda5     partition     16777212 39676   -1

 (6)查看硬盘使用情况

[root@Master ~]# df -hTFilesystem     Type   Size  Used Avail Use% Mounted on/dev/sda2      ext4    99G  561M   93G   1% /tmpfs          tmpfs   63G   76K   63G   1% /dev/shm/dev/sda1      ext4    45M   38M  4.9M  89% /boot/dev/sda3      ext4    50G   52M   47G   1% /home/dev/sda6      ext4    13G   34M   13G   1% /tmp/dev/sda7      ext4    99G   21G   73G  23% /usr/dev/sdb1      ext4    84T   41T   40T  51% /PureDisk

(7) 硬盘检测命令smartctl

[root@Master ~]# smartctl -a /dev/sdasmartctl 5.43 2012-06-30 r3573 [x86_64-linux-2.6.32-642.el6.x86_64] (local build)Copyright (C) 2002-12 by Bruce Allen, http://smartmontools.sourceforge.net Vendor:               HP      Product:              LOGICAL VOLUME  Revision:             3.56User Capacity:        299,966,445,568 bytes [299 GB]Logical block size:   512 bytesLogical Unit id:      0x600508b1001cc8a1b9ec4dacc5ab35dcSerial number:        PDNNK0BRH9U0AG  Device type:          diskLocal Time is:        Mon Feb  5 13:13:33 2018 CSTDevice supports SMART and is EnabledTemperature Warning Disabled or Not SupportedSMART Health Status: OKError Counter logging not supportedDevice does not support Self Test logging

三、查看网卡信息

(1)查看网卡硬件信息
[root@Master ~]#  lspci | grep -i 'eth'

eb587c0716800d88b3d3d6027d758fd1.png

(2)查看系统的所有网络接口

[root@Master ~]# ifconfig -a[root@Master ~]# ip link show

(3)查看某个网络接口的详细信息,例如eth0的详细参数和指标

[root@Master ~]# ethtool eth0Settings for eth0:        Supported ports: [ FIBRE ]        Supported link modes:   10000baseT/Full         Supported pause frame use: No        Supports auto-negotiation: No        Advertised link modes:  10000baseT/Full         Advertised pause frame use: No        Advertised auto-negotiation: No        Speed: 10000Mb/s        Duplex: Full        Port: FIBRE        PHYAD: 0        Transceiver: external        Auto-negotiation: off        Supports Wake-on: d        Wake-on: d        Current message level: 0x00000007 (7)                               drv probe link        Link detected: yes

(4)查看所有网卡的链路状态

[root@Master ~]# for i in `seq 0 9`;do ethtool eth${i} | egrep 'eth|Link';doneSettings for eth0:        Link detected: yes   Settings for eth1:        Link detected: yesSettings for eth2:        Link detected: noSettings for eth3:        Link detected: noSettings for eth4:        Link detected: noSettings for eth5:        Link detected: noSettings for eth6:        Link detected: noSettings for eth7:        Link detected: noSettings for eth8:        Link detected: noSettings for eth9:        Link detected: no

四、列出所有PCI设备信息

[root@Master ~]# lspci -tv | more-+-[0000:ff]-+-08.0  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 QPI Link 0 |           +-08.3  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 QPI Link 0 |           +-09.0  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 QPI Link 1 |           +-09.3  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 QPI Link 1 |           +-0b.0  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 R3 QPI Link 0 & 1 Monitoring |           +-0b.1  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 R3 QPI Link 0 & 1 Monitoring |           +-0b.2  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 R3 QPI Link 0 & 1 Monitoring |           +-0c.0  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.1  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.2  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.3  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.4  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.5  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.6  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0c.7  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0d.0  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0d.1  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Unicast Registers |           +-0f.0  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Buffered Ring Agent |           +-0f.1  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Buffered Ring Agent |           +-0f.2  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Buffered Ring Agent |           +-0f.3  Intel Corporation Xeon E7 v3/Xeon E5 v3/Core i7 Buffered Ring Agent

fb4b738dfeb575c763ecfc5df3cb4208.png

好了,每天进步一点点。

所有大神,都是来源于小白点点滴滴不停的积累,加油吧,少年。

版权声明:本文来源CSDN,感谢博主原创文章,遵循 CC 4.0 by-sa 版权协议,转载请附上原文出处链接和本声明。
原文链接:https://blog.csdn.net/weixin_39908758/article/details/111266423
站方申明:本站部分内容来自社区用户分享,若涉及侵权,请联系站方删除。
  • 发表于 2021-05-17 21:22:00
  • 阅读 ( 1221 )
  • 分类:Linux

0 条评论

请先 登录 后评论

官方社群

GO教程

猜你喜欢