【RHCA+】numactl命令(管理numa)

" 目录:RHCA+ -> 15 硬件管理 -> 12 numactl命令(管理numa) "

查看、管理numa;语法格式:numactl 参数

|-------------------|-------------------------------------|
| 参数 | 作用 |
| --hardware, -H | 查看numa结构 |
| --show, -s | 查看策略 |
| --interleave, -i | 平均使用各node资源 |
| --membind, -m | 使用哪个node的内存 |
| --cpunodebind, -N | 使用哪个node的cpu |
| --preferred, -p | 应该优先用哪个node的cpu和内存 |
| --localalloc, -l | 限制程序只使用node本地内存,不能使用其他node内存;cpu不限制 |

一、安装

root@wuzuniao \~# yum -y install numactl #安装工具

二、使用

root@wuzuniao \~# numactl -H #查看服务器上的numa数量及每个node内的cpu和内存数

available: 1 nodes (0)

node 0 cpus: 0

node 0 size: 958 MB

node 0 free: 89 MB

node distances:

node 0

0: 10

root@wuzuniao \~# numactl -s #查看策略

policy: default

preferred node: current

physcpubind: 0

cpubind: 0

nodebind: 0

membind: 0

root@wuzuniao \~# numactl #输入错误就会弹出命令帮助

usage: numactl --all \| -a --interleave= \| -i --preferred= \| -p

--physcpubind= \| -C \] \[--cpunodebind= \| -N

--membind= \| -m --localalloc \| -l command args ...

numactl --show \| -s

numactl --hardware \| -H

numactl --length \| -l --offset \| -o --shmmode \| -M

--strict \| -t

--shmid \| -I --shm | -S

--shmid \| -I --file | -f

--huge \| -u\] \[--touch \| -T

memory policy | --dump | -d | --dump-nodes | -D

memory policy is --interleave | -i, --preferred | -p, --membind | -m, --localalloc | -l

is a comma delimited list of node numbers or A-B ranges or all.

Instead of a number a node can also be:

netdev:DEV the node connected to network device DEV

file:PATH the node the block device of path is connected to

ip:HOST the node of the network device host routes through

block:PATH the node of block device path

pci:seg:bus:dev:func The node of a PCI device

is a comma delimited list of cpu numbers or A-B ranges or all

all ranges can be inverted with !

all numbers and ranges can be made cpuset-relative with +

the old --cpubind argument is deprecated.

use --cpunodebind or --physcpubind instead

can have g (GB), m (MB) or k (KB) suffixes

root@wuzuniao \~#

相关推荐
飞奔的瓜牛1 小时前
CentOS 7 系统优化实战指南:从内核参数到服务精简
linux·运维·centos
少司府11 小时前
嵌入式外设篇(二)GPIO·二:GPIO输出与LED控制
linux·stm32·单片机·嵌入式硬件·mcu·51单片机·系统
H.莓飛12 小时前
【C++】【STL】stack_OJ题
服务器·c语言·开发语言·数据结构·c++·算法·visual studio
Rabitebla13 小时前
【Linux操作系统】 文件篇(一):文件描述符与 Linux 文件管理机制
linux·网络·c++·笔记·学习
发疯的技术鼠14 小时前
03-优先级与调度
linux
无足鸟ICT16 小时前
【RHCA+】sosreport(收集诊断文档)
linux·运维·服务器
GeW16 小时前
世界目光聚焦中国:底层技术、Linux、数据库的破局逻辑
linux·数据库
IT大白鼠16 小时前
当 AI 开始自动化渗透:FBI ARTEX 警报的防守对策
运维·人工智能·自动化
Decay__17 小时前
SQLServer 运维自动化平台 —— PowerShell + SQL Agent 作业:部署、监控、巡检、告警、工单闭环一体化
运维·数据库·sql·mysql·架构