Linux命令(52)之lsmem

linux命令之lsmem

1.lsmem介绍

linux命令lsmem是用来查看服务器内存的情况。在linux下,我们可以使用free -m、cat /proc/meminfo命令来查看内存,对于运维来说,lsmem命令了解即可

2.lsmem用法

lsmem [参数]

lsmem参数
参数 说明
-a 列出每个单独的内存块,而不是组合具有相似属性的内存块

3.实例

3.1.查看服务器内存情况

命令:

lsmem -a

OR 

lsmem

[root@rhel77 ~]# lsmem
RANGE                                  SIZE  STATE REMOVABLE BLOCK
0x0000000000000000-0x0000000007ffffff  128M online        no     0
0x0000000008000000-0x000000002fffffff  640M online       yes   1-5
0x0000000030000000-0x000000003fffffff  256M online        no   6-7
0x0000000040000000-0x00000000afffffff  1.8G online       yes  8-21
0x00000000b0000000-0x00000000bfffffff  256M online        no 22-23
0x0000000100000000-0x0000000177ffffff  1.9G online       yes 32-46
0x0000000178000000-0x000000017fffffff  128M online        no    47
0x0000000180000000-0x0000000197ffffff  384M online       yes 48-50
0x0000000198000000-0x00000001b7ffffff  512M online        no 51-54

Memory block size:       128M
Total online memory:     5.9G
Total offline memory:      0B
[root@rhel77 ~]# lsmem -a
RANGE                                  SIZE  STATE REMOVABLE BLOCK
0x0000000000000000-0x0000000007ffffff  128M online        no     0
0x0000000008000000-0x000000000fffffff  128M online       yes     1
0x0000000010000000-0x0000000017ffffff  128M online       yes     2
0x0000000018000000-0x000000001fffffff  128M online       yes     3
0x0000000020000000-0x0000000027ffffff  128M online       yes     4
0x0000000028000000-0x000000002fffffff  128M online       yes     5
0x0000000030000000-0x0000000037ffffff  128M online        no     6
0x0000000038000000-0x000000003fffffff  128M online        no     7
0x0000000040000000-0x0000000047ffffff  128M online       yes     8
0x0000000048000000-0x000000004fffffff  128M online       yes     9
0x0000000050000000-0x0000000057ffffff  128M online       yes    10
0x0000000058000000-0x000000005fffffff  128M online       yes    11
0x0000000060000000-0x0000000067ffffff  128M online       yes    12
0x0000000068000000-0x000000006fffffff  128M online       yes    13
0x0000000070000000-0x0000000077ffffff  128M online       yes    14
0x0000000078000000-0x000000007fffffff  128M online       yes    15
0x0000000080000000-0x0000000087ffffff  128M online       yes    16
0x0000000088000000-0x000000008fffffff  128M online       yes    17
0x0000000090000000-0x0000000097ffffff  128M online       yes    18
0x0000000098000000-0x000000009fffffff  128M online       yes    19
0x00000000a0000000-0x00000000a7ffffff  128M online       yes    20
0x00000000a8000000-0x00000000afffffff  128M online       yes    21
0x00000000b0000000-0x00000000b7ffffff  128M online        no    22
0x00000000b8000000-0x00000000bfffffff  128M online        no    23
0x0000000100000000-0x0000000107ffffff  128M online       yes    32
0x0000000108000000-0x000000010fffffff  128M online       yes    33
0x0000000110000000-0x0000000117ffffff  128M online       yes    34
0x0000000118000000-0x000000011fffffff  128M online       yes    35
0x0000000120000000-0x0000000127ffffff  128M online       yes    36
0x0000000128000000-0x000000012fffffff  128M online       yes    37
0x0000000130000000-0x0000000137ffffff  128M online       yes    38
0x0000000138000000-0x000000013fffffff  128M online       yes    39
0x0000000140000000-0x0000000147ffffff  128M online       yes    40
0x0000000148000000-0x000000014fffffff  128M online       yes    41
0x0000000150000000-0x0000000157ffffff  128M online       yes    42
0x0000000158000000-0x000000015fffffff  128M online       yes    43
0x0000000160000000-0x0000000167ffffff  128M online       yes    44
0x0000000168000000-0x000000016fffffff  128M online       yes    45
0x0000000170000000-0x0000000177ffffff  128M online       yes    46
0x0000000178000000-0x000000017fffffff  128M online        no    47
0x0000000180000000-0x0000000187ffffff  128M online       yes    48
0x0000000188000000-0x000000018fffffff  128M online       yes    49
0x0000000190000000-0x0000000197ffffff  128M online       yes    50
0x0000000198000000-0x000000019fffffff  128M online        no    51
0x00000001a0000000-0x00000001a7ffffff  128M online        no    52
0x00000001a8000000-0x00000001afffffff  128M online        no    53
0x00000001b0000000-0x00000001b7ffffff  128M online        no    54

Memory block size:       128M
Total online memory:     5.9G
Total offline memory:      0B
[root@rhel77 ~]# 

你可能感兴趣的:(Linux命令,linux,运维,服务器,lsmem)