vmo 명령어 (AIX 5.3·6.1)
https://archive.horanglab.com/posts/aix-cmd-vmo
핵심 정리
- 가상 메모리 관리자(VMM)의 조정 값을 보고 바꿉니다. root만 실행할 수 있습니다.
vmo -a(모든 값),vmo -o 이름(값 보기),vmo -o 이름=값(바꾸기),vmo -L [이름](현재·기본·부팅 값, 범위, 유형),vmo -h 이름(도움말).-p는 현재 값과 다음 부팅 값(/etc/tunables/nextboot)을 함께,-r은 다음 부팅 값만 바꿉니다.-d 이름·-D는 기본값으로 되돌립니다.- 유형: D(동적), S(정적), R(재부팅), B(bosboot 필요), M(마운트), I(증가만), C(연결), d(폐기 예정). R·B 유형은
-r로만 바꿉니다. - 자주 보는 값:
minfree·maxfree(빈 목록 기준),minperm%,maxpin%,npswarn·npskill(페이징 공간 부족 경고·종료),lgpg_regions·lgpg_size(대형 페이지). - 6.1에서는 많은 값이 제한된(restricted) 조정 값이 되어
-F를 줘야 목록에 보입니다. 잘못 바꾸면 성능이 떨어지거나 시스템이 멈출 수 있습니다.
| 항목 | 내용 |
|---|---|
| 버전 | AIX 5.3, AIX 6.1 (6.1에서 -F(제한된 조정 값 표시)가 더해지고, 문서에 실린 조정 값이 53개에서 32개로 바뀜) |
| 원문 | IBM Commands Reference — 5.3 Volume 6, 6.1 Volume 6 |
| 파일 | /usr/sbin/vmo, /etc/tunables/nextboot |
| 관련 명령어 | ioo, schedo, no, nfso, raso, vmstat -v, bosboot |
목적
가상 메모리 관리자(VMM)의 조정 값을 관리합니다.
영어 원문
Manages Virtual Memory Manager tunable parameters.
구문
vmo [ -p | -r ] [ -y ] { -o Tunable [ = Newvalue ] }
vmo [ -p | -r ] [ -y ] { -d Tunable }
vmo [ -p | -r ] [ -y ] -D
vmo [ -p | -r ] [ -F ] -a
vmo -h [ Tunable ]
vmo [ -F ] -L [ Tunable ]
vmo [ -F ] -x [ Tunable ]
-o, -d, -x, -L은 여러 번 쓸 수 있습니다. -F는 6.1 구문에만 있습니다.
설명
참고: vmo는 root만 실행할 수 있습니다. vmo는 스스로 설명하는 명령이라 이 문서의 플래그나 조정 값 정보가 빠졌거나 오래됐을 수 있습니다. 최신 목록은 -h, -L, -x로 봅니다.
vmo 명령으로 VMM 조정 값을 설정합니다. 모든 VMM 조정 값의 현재 값이나 다음 부팅 값을 설정하거나 보여 주며, 바꾼 것을 영구로 하거나 다음 재부팅까지 미룰 수 있습니다. 설정할지 보여 줄지는 함께 주는 플래그가 정하며, -o는 둘 다 합니다.
- VMM은 빈 실제 메모리 페이지 프레임의 목록을 유지합니다. 이 프레임은 페이지 폴트를 해결하는 데 필요한 가상 메모리 페이지를 담습니다. 빈 목록의 페이지 수가
minfree보다 적어지면 VMM은 페이지를 빼앗아(steal) 빈 목록에 더하기 시작하고, 적어도maxfree만큼 될 때까지 계속합니다. - 메모리의 파일 페이지(영구 페이지) 수가
minperm%보다 적으면 VMM은 재페이지 비율과 상관없이 계산용 페이지나 파일 페이지에서 프레임을 빼앗습니다.maxperm%보다 많으면 파일 페이지에서만 빼앗습니다. 둘 사이에서는 보통 파일 페이지만 빼앗지만, 파일 페이지의 재페이지 비율이 계산용 페이지보다 높으면 계산용 페이지도 빼앗습니다. - 페이징 공간이 모자라다고 판단하는 기준도 바꿀 수 있습니다.
npswarn은 쓸 수 있는 페이징 공간 페이지가 이만큼일 때 프로세스에 경고를 시작하는 값이고,npskill은 이만큼일 때 페이징 공간을 풀려고 프로세스를 끝내기 시작하는 값입니다.
참고(6.1): VMM 조정 값을 바꾸려는 -o, -d, -D는 WPAR 안에서 지원하지 않습니다.
조정 값을 바꾸는 영향
이 명령을 잘못 쓰면 성능이 떨어지거나 운영 체제가 실패할 수 있습니다. vmo로 실험하기 전에 Performance management의 "Performance overview of the Virtual Memory Manager"와 "Enhanced JFS file system cache limit with the maxclient parameter"를 익힙니다.
조정 값을 바꾸기 전에 아래 조정 값 절에서 그 값의 특성을 모두 꼼꼼히 읽고, Refer To 안내를 따라가 목적을 완전히 이해합니다. 그다음 그 값의 Diagnosis와 Tuning 설명이 정말 지금 상황에 맞는지, 값을 바꾸면 성능이 나아질지 확인합니다. Diagnosis와 Tuning이 모두 "N/A"면, AIX 개발 부서가 따로 지시하지 않는 한 바꾸지 않는 것이 좋습니다.
영어 원문
Note: The vmo command can only be executed by root. The vmo command is a self-documenting command. The information about some of the flags or tunable parameters might be missing or out-of-date. You can find an up-to-date list of all the flags and tunable parameters by using the -h,-L, or -x flag.
Use the vmo command to configure Virtual Memory Manager tuning parameters. This command sets or displays current or next boot values for all Virtual Memory Manager tuning parameters. This command can also make permanent changes or defer changes until the next reboot. Whether the command sets or displays a parameter is determined by the accompanying flag. The -o flag specifies both actions. It can either display the value of a parameter or set a new value for a parameter.
The Virtual Memory Manager (VMM) maintains a list of free real-memory page frames. The page frames are available to hold virtual-memory pages that are needed to satisfy a page fault. When the number of pages on the free list falls below the values that are specified by the minfree parameter, the VMM begins to steal pages to add to the free list. The VMM continues to steal pages until the free list has at least the number of pages that are specified by the maxfree parameter.
If the number of file pages (permanent pages) in memory is less than the number specified by the minperm% parameter, the VMM steals frames from either computational or file pages, regardless of repage rates. If the number of file pages is greater than the number specified by the maxperm%
parameter, the VMM steals frames only from file pages. Between the two, the VMM normally only steals file pages, but if the repage rate for file pages is higher than the repage rate for computational pages, computational pages are stolen as well.
You can also modify the thresholds that are used to decide when the system is running out of paging space. The npswarn parameter specifies the number of paging-space pages available at which the system begins warning processes that paging space is low. The npskill parameter specifies the number of paging-space pages available at which the system begins stopping processes to release paging space.
Note: Options -o, -d, and -D, which attempt to change the value of a virtual memory manager tunable parameter, are not supported within a workload partition.
Understanding the Effect of Changing Tunable Parameters
Misuse of this command can cause performance degradation or operating-system failure. Before you experiment with the vmo command, familiarize yourself with both Performance overview of the Virtual Memory Manager and Enhanced JFS file system cache limit with the maxclient parameter.
Before modifying any tunable parameter, you should first carefully read about all its characteristics in the Tunable Parameters section below, and follow any Refer To pointer, in order to fully understand its purpose.
You must then make sure that the Diagnosis and Tuning sections for this parameter truly apply to your situation and that changing the value of this parameter could help improve the performance of your system.
If the Diagnosis and Tuning sections both contain only "N/A", you should probably never change this parameter unless specifically directed by AIX development.
플래그
| 플래그 | 설명 |
|---|---|
-a |
모든 조정 값의 현재 값(-r이면 재부팅 값, -p면 영구 값)을 한 줄에 Tunable = Value 하나씩 보여 줍니다. 영구 값은 재부팅 값과 현재 값이 같을 때만 보이고, 아니면 NONE입니다. |
-d Tunable |
조정 값을 기본값으로 되돌립니다. 기본값이 아니어서 바꿔야 하는데 Bosboot·Reboot 유형이거나, Incremental 유형이 기본값에서 바뀌었고 -r을 함께 쓰지 않았으면, 경고만 내고 바꾸지 않습니다. |
-D |
모든 조정 값을 기본값으로 되돌립니다. 제약은 -d와 같습니다. |
-F |
-a, -L, -x만 줘서 모든 조정 값을 나열할 때 제한된 조정 값도 보여 줍니다. -F가 없으면 이름을 직접 지정하지 않는 한 제한된 조정 값은 보이지 않습니다. 6.1부터 |
-h [Tunable] |
조정 값의 도움말을 보여 줍니다. 이름이 없으면 사용법을 보여 줍니다. |
-L [Tunable] |
조정 값 하나나 전부의 특성을 한 줄에 하나씩 보여 줍니다(아래 형식). |
-o Tunable[=Newvalue] |
값을 보여 주거나 Newvalue로 바꿉니다. 바꿔야 하는데 Bosboot·Reboot 유형이거나, Incremental 유형이고 현재 값이 새 값보다 크며 -r이 없으면 바꾸지 않고 경고합니다. -r과 함께 새 값 없이 쓰면 다음 부팅 값을, -p와 함께 새 값 없이 쓰면 현재 값과 다음 부팅 값이 같을 때만 값을(아니면 NONE) 보여 줍니다. |
-p |
-o, -d, -D와 함께 쓰면 현재 값과 재부팅 값을 함께 바꿉니다. 곧 현재 값과 함께 /etc/tunables/nextboot도 고칩니다. 현재 값을 바꿀 수 없는 Reboot·Bosboot 유형에는 쓸 수 없습니다. -a나 새 값 없는 -o와 함께 쓰면 현재 값과 다음 부팅 값이 같을 때만 값을 보여 줍니다. |
-r |
-o, -d, -D와 함께 쓰면 재부팅 값을 바꿉니다(/etc/tunables/nextboot를 고침). Bosboot 유형을 바꾸면 bosboot를 실행하라고 묻습니다. -a나 새 값 없는 -o와 함께 쓰면 현재 값 대신 다음 부팅 값을 보여 줍니다. |
-x [Tunable] |
조정 값 하나나 전부의 특성을 스프레드시트 형식으로 한 줄에 하나씩 보여 줍니다: tunable,current,default,reboot,min,max,unit,type,{dtunable} |
-y |
bosboot를 실행하기 전의 확인 질문을 하지 않습니다. |
-L의 출력 형식:
NAME CUR DEF BOOT MIN MAX UNIT TYPE
DEPENDENCIES
--------------------------------------------------------------------------------
memory_frames 128K 128K 4KB pages S
--------------------------------------------------------------------------------
maxfree 1088 1088 130 16 200K 4KB pages D
minfree
memory_frames
--------------------------------------------------------------------------------
| 열 | 뜻 |
|---|---|
| CUR, DEF, BOOT | 현재 값, 기본값, 재부팅 값 |
| MIN, MAX | 최솟값, 최댓값 |
| UNIT | 단위 |
| TYPE | D 동적(Dynamic), S 정적(Static), R 재부팅(Reboot), B bosboot(Bosboot), M 마운트(Mount), I 증가만(Incremental), C 연결(Connect), d 폐기 예정(Deprecated) |
| DEPENDENCIES | 이 값과 관련된 조정 값 목록(한 줄에 하나) |
- 제한된 조정 값을 바꾸면 제한 사용 유형의 조정 값을 바꿨다는 경고를 보여 주고,
-r이나-p를 주면 확인을 받습니다. 또-r·-p로 기본값과 다르게 바꿔/etc/tunables/nextboot에 남은 제한된 조정 값은 재부팅할 때 오류 로그 항목을 남깁니다. - 값에는 K(2의 10제곱), M(20제곱), G(30제곱), T(40제곱), P(50제곱), E(60제곱) 같은 단위 약어를 쓸 수 있습니다. 예를 들어 1024는
1K로 씁니다. - Mount 유형을
-o,-d,-D로 바꾸면 이후에 마운트하는 것에만 적용된다는 경고가 나옵니다.
영어 원문
-a— Displays current, reboot (when used with the-roption), or permanent (when used with the-poption) values for all tunable parameters, one per line in pairs Tunable = Value. For the permanent option, a value is displayed only for a parameter if its reboot and current values are equal. Otherwise,NONEis displayed as the value.-dTunable — Resets the Tunable parameter to its default value. If a Tunable parameter, which must be changed because it is not set to its default value, meets one or more of the following sets of criteria, a warning message is displayed and no change is made to the parameter: • The tunable parameter is of type Bosboot or Reboot. • The tunable parameter is of type Incremental and was changed from its default value, and the-rflag is not used in combination.-D— Resets all Tunable values to their default values. If Tunables that need to be changed because they are not set to their default values meet one or more of the following sets of criteria, a warning message is displayed and no change is made: • The tunable is of type Bosboot or Reboot. • The tunable is of type Incremental and was changed from its default value, and-ris not used in combination.-F— Forces display of the restricted tunable parameters when the-a,-Lor-xoptions are specified alone on the command line to list all tunables. When the-Fflag is not specified, restricted tunables are not displayed, unless these restricted tunables are specifically named with a display option.-h[Tunable] — Displays help about the Tunable parameter if one is specified. Otherwise, displays the vmo command usage statement.-L[ Tunable ] — Lists the characteristics of one or all tunables, one per line, using the following format:NAME CUR DEF BOOT MIN MAX UNIT TYPE DEPENDENCIES -------------------------------------------------------------------------------- memory_frames 128K 128K 4KB pages S -------------------------------------------------------------------------------- maxfree 1088 1088 130 16 200K 4KB pages D minfree memory_frames -------------------------------------------------------------------------------- minfree 960 960 122 8 200K 4KB pages D maxfree memory_frames -------------------------------------------------------------------------------- ... where: CUR = current value DEF = default value BOOT = reboot value MIN = minimal value MAX = maximum value UNIT = tunable unit of measure TYPE = parameter type: D (for Dynamic), S (for Static), R for Reboot), B (for Bosboot), M (for Mount), I (for Incremental), C (for Connect), and d (for Deprecated) DEPENDENCIES = list of dependent tunable parameters, one per line-oTunable[=Newvalue] — Displays the value or sets tunable to Newvalue. If a tunable must be changed (the specified value is different than the current value), is of type Bosboot or Reboot, or if it is of type Incremental and its current value is greater than the specified value, and-ris not used in combination, the tunable value is not changed but a warning is displayed. When the-rflag is used in combination without a new value, the nextboot value for tunable is displayed. When-pis used in combination without a new value, a value is displayed only if the current and next boot values for the tunable are the same. Otherwise,NONEis displayed as the value.-p— When used in combination with-o,-dor-D, makes changes apply to both current and reboot values, that is, turns on the updating of the /etc/tunables/nextboot file in addition to the updating of the current value. These combinations cannot be used on Reboot and Bosboot type parameters because their current value can't be changed. When used with-aor-owithout specifying a new value, values are displayed only if the current and next boot values for a parameter are the same. OtherwiseNONEis displayed as the value.-r— When the-rflag is used with the-aor-ooptions without specifying a new value, the values are displayed only if the current and next boot values for a parameter are the same. Otherwise, NONE is displayed as the value. The-rflag changes the reboot values when it is used with the-o,-d, or-Dflags. For example, you can update the/etc/tunables/nextbootfile when you use the-rflag. If any parameter of type Bosboot is changed, the user will be prompted to run the bosboot command. When used with the-aor the-ooptions without specifying a new value, next boot values for tunables are displayed instead of current values.-x[Tunable] — Lists characteristics of one or all tunables, one per line, using the following (spreadsheet) format:tunable,current,default,reboot,min,max,unit,type,{dtunable } where: current = current value default = default value reboot = reboot value min = minimal value max = maximum value unit = tunable unit of measure type = parameter type: D (for Dynamic), S (for Static), R (for Reboot), B (for Bosboot), M (for Mount), I (for Incremental), C (for Connect), and d (for Deprecated) dtunable = list of dependent tunable parameters-y— Suppresses the confirmation prompt before running the bosboot command.
If a restricted tunable parameter is changed, a warning message is displayed that indicates that a tunable of the restricted use type has been modified. If the -r or the -p option is specified, you are prompted to confirm the change. In addition, at system reboot, restricted tunables that are displayed in the
/etc/tunables/nextboot file and are changed to values that are different from their default values (using a command line specifying the -r or -p option) causes an error log entry that identifies the list of these changed tunables.
When modifying tunable, the tunable value might be specified using abbreviations such as K, M, G, T, P and E to indicate units. See the following lists for abbreviations and their correspondent values:
K=210
M=220
G=230
T=240
P=250
E=260
Thus, a tunable value of 1024 might be specified as 1K.
Any change (with -o, -d or -D) to a parameter of type Mount will result in a message being displayed to warn the user that the change is only effective for future mountings.
Any change (with -o, -d or -D flags) to a parameter of type Connect will result in inetd being restarted, and a message displaying a warning to the user that the change is only effective for future socket connections.
Any attempt to change (with -o, -d or -D) a parameter of type Bosboot or Reboot without -r, will result in an error message.
Any attempt to change (with -o, -d or -D but without -r) the current value of a parameter of type Incremental with a new value smaller than the current value, will result in an error message.
Tunable Parameters Type
All the tunable parameters manipulated by the tuning commands (no, nfso, vmo, ioo, raso, and schedo) have been classified into these categories:
- Dynamic — If the parameter can be changed at any time
- Static — If the parameter can never be changed
- Reboot — If the parameter can only be changed during reboot
- Bosboot — If the parameter can only be changed by running bosboot and rebooting the machine
- Mount — If changes to the parameter are only effective for future file systems or directory mounts
- Incremental — If the parameter can only be incremented, except at boot time
- Connect — If changes to the parameter are only effective for future socket connections
- Deprecated — If changing this parameter is no longer supported by the current release of AIX.
For parameters of type Bosboot, whenever a change is performed, the tuning commands automatically prompt the user to ask if they want to execute the bosboot command. For parameters of type Connect, the tuning commands automatically restart the inetd daemon.
Note that the current set of parameters managed by the vmo command only includes Static, Dynamic, and Bosboot types.
Compatibility Mode
When running in compatibility mode (controlled by the pre520tune attribute of sys0), reboot values for parameters, except those of type Bosboot, are not really meaningful because in this mode they are not applied at boot time. For more information, see Performance management.
In compatibility mode, you can set reboot values to tuning parameters by imbedding calls to tuning commands in scripts called during the boot sequence. Parameters of type Reboot can be set without using the -r flag, so that existing scripts continue to work.
조정 값
각 조정 값의 기본값과 범위는 vmo -h 이름으로 봅니다. 아래는 6.1 문서에 실린 조정 값과 그 쓰임입니다.
| 조정 값 | 목적 | 조정 참고 |
|---|---|---|
ame_cpus_per_pool |
압축 메모리 풀당 CPU 비율. 이 수의 CPU마다 압축 풀이 적어도 하나 생김 | 비율을 낮추면 압축 풀 경합이 줄어듦. 메모리 양과 배치도 풀 수에 영향을 줌 |
ame_maxfree_mem |
압축 풀 빈 목록의 평균 빈 메모리가 이만큼이면 VMM이 압축 풀을 줄임 | 작업 집합이 자주 바뀌어 늘고 줄기가 잦으면 값을 올림 |
ame_min_ucpool_size |
압축되지 않은 풀의 최소 크기 | 압축 풀이 너무 커져 성능이 떨어지면 올림 |
ame_minfree_mem |
압축 풀 빈 목록의 빈 메모리가 이만큼이면 VMM이 압축 풀을 키움 | 압축 메모리를 기다리느라 늦어지면 올림. ame_maxfree_mem보다 적어도 64KB 작아야 함 |
ams_loan_policy |
공유 메모리(AMS) 모드에서 하이퍼바이저에 메모리를 빌려주는 방식 | 0은 빌려주지 않음, 1은 파일 캐시만, 2는 모든 데이터 |
force_relalias_lite |
0이면 mmap 영역을 해제할 때 원본 세그먼트 잠금을 피할지 휴리스틱으로 정함 | 1이면 relalias_percentage와 상관없이 되도록 잠금을 피함(확장성과 계산 시간의 맞바꿈) |
kernel_heap_psize |
커널 힙의 기본 페이지 크기 | 권고 설정. 64KB는 POWER5+ 이후, 16MB는 고성능 환경에서만 |
lgpg_regions |
shmget()의 SHM_LGPAGE로 쓸 대형 페이지 수를 예약 |
lgpg_size도 함께 지정하며, 응용 프로그램이 SHM_LGPAGE를 써야 함. TLB 미스가 많고 메모리를 많이 쓸 때 성능이 좋아짐 |
lgpg_size |
대형 페이지의 크기(바이트) | POWER4 이후. lgpg_regions와 함께 씀. DLPAR 시스템에서 동적이지만 bosboot 때 부팅 이미지에도 기록 |
low_ps_handling |
페이징 공간이 모자랄 때의 프로세스 종료 동작 | 1은 기존 동작, 2는 다른 프로세스로 해결이 안 되면 SIGDANGER 처리기를 둔 프로세스도 끝냄 |
maxfree |
페이지 빼앗기를 멈추는 빈 목록의 프레임 수 | vmstat로 빈 목록 크기를 보고, 자주 minfree 아래로 내려가면 올림. 너무 높이면 응용 프로그램 메모리가 빼앗김 |
maxpin% |
고정할 수 있는 실제 메모리의 최대 비율 | 빈 메모리가 있는데 고정할 수 없을 때 바꿈. 커널용으로 적어도 4MB는 고정하지 않고 남겨야 함 |
memory_frames |
유효한 메모리 프레임 수 | N/A |
memplace_data |
데이터(주 실행 파일의 데이터·BSS, 힙, 공유 라이브러리)의 기본 메모리 배치 정책 | 0 자동, 1 first-touch, 2 시스템 전체 round-robin |
memplace_mapped_file |
shmat()·mmap()으로 대응한 파일의 기본 배치 정책 |
0, 1, 2 위와 같음 |
memplace_shm_anonymous |
익명 공유 메모리(만든 프로세스와 자손만 접근)의 기본 배치 정책 | 0, 1, 2 위와 같음 |
memplace_shm_named |
이름 있는 공유 메모리(shmget()·shm_open())의 기본 배치 정책 |
0, 1, 2 위와 같음 |
memplace_stack |
프로그램 스택의 기본 배치 정책 | 0, 1, 2 위와 같음 |
memplace_text |
응용 프로그램 텍스트(주 실행 파일만)의 기본 배치 정책 | 0, 1, 2 위와 같음 |
memplace_unmapped_file |
read()·write()로 접근하는 파일의 기본 배치 정책 |
0, 1, 2 위와 같음 |
minfree |
VMM이 빈 목록을 채우려고 페이지를 빼앗기 시작하는 빈 목록의 프레임 수 | 페이지 빼앗기로 프로세스가 늦어지면 올림. maxfree와의 차이는 maxpgahead 정도로 |
minperm% |
재페이지 비율과 상관없이 파일·계산용 페이지를 빼앗기 시작하는 기준 | 파일 페이지가 많아 작업 저장소 페이지가 밀려나면 내림. 반복해 읽는 파일이 있으면 너무 낮지 않은지 봄 |
nokilluid |
이 값보다 작은 사용자 ID는 페이징 공간 부족으로 끝내지 않음 | 0은 끔. 관리 프로세스가 끝나는 것을 막을 때 씀 |
npskill |
운영 체제가 프로세스를 끝내기 시작하는 빈 페이징 공간 페이지 수 | 기본은 64와 (페이징 공간 페이지 수)/128 중 큰 값. 0보다 크고 전체보다 작아야 함 |
npswarn |
SIGDANGER 신호를 보내기 시작하는 빈 페이징 공간 페이지 수 | 기본은 512와 4*npskill 중 큰 값. 프로세스가 끝나는 일이 있으면 올림 |
numpsblks |
페이징 공간 블록의 전체 수 | N/A |
pinnable_frames |
고정할 수 있는 페이지 수 | N/A |
relalias_percentage |
force_relalias_lite가 0일 때 잠금을 피할지 정하는 휴리스틱의 비율 |
해제하는 페이지 수가 이 값으로 나눈 크기보다 작으면 잠금을 피함 |
scrub |
지연 페이징 공간 할당(DPSA) 정책 페이지에서 메모리에 있는 페이징 공간 디스크 블록을 풀지 | 0은 끔, 1은 빈 페이징 공간 블록이 npsscrubmin보다 적으면 npsscrubmax를 넘을 때까지 풂 |
v_pinshm |
1이면 공유 메모리 세그먼트를 고정할 수 있게 함 | 0은 끔. 응용 프로그램이 shmget()에 SHM_PIN을 쓰고 공유 메모리로 AIO를 할 때만 쓸모 |
vmm_default_pspa |
페이지 크기 승격의 기본 공격성 | 0은 승격 임계값 100%(실제 메모리를 100% 차지해야 승격), 100은 그보다 공격적 |
wlm_memlimit_nonpg |
고정 페이지 크기(16M, 16G)를 WLM의 realmem·virtmem 계산에 넣을지 | 0이면 페이징 가능한 페이지(4K, 64K)만 WLM 한도에 셈 |
5.3 문서에는 이 밖에 maxperm%, maxclient%, strict_maxperm, strict_maxclient, lrubucket, page_steal_method, mempools, framesets, defps, npsrpgmin·npsrpgmax, npsscrubmin·npsscrubmax, vmm_mpsize_support 등 더 많은 조정 값이 실려 있습니다. 6.1에서는 이들 중 다수가 제한된 조정 값이 되어 vmo -F -L로 봅니다.
영어 원문
To view the default and range of values allowed for the tunables, run the vmo command with the -h option as follows: vmo -h <tunable_parameter_name>
Tunable Description ame_cpus_per_pool Purpose
Determines the ratio of CPUs per compressed memory pool. For every ame_cpus_per_pool CPUs, at least one compressed memory pool is created.
Tuning
Lower ratios are used to reduce contention on compressed memory pools. This ratio is not the only factor used to determine the number of compressed memory pools (amount of memory and the layout is also considered) so certain changes to this ratio may not result in any change to the number of compressed memory pools.
ame_maxfree_mem Purpose
Specifies the average amount of free memory in a compressed memory pool free list at which the VMM will shrink the compressed pool.
Tuning
Excessive shrink and grow operations can occur if compressed memory pool size tends to change significantly. This can occur if the workload working set size frequently changes. Increase this tunable to raise the threshold at which the VMM will shrink a compressed memory pool and thus reduce the number of overall shrink and grow operations.
ame_min_ucpool_size Purpose
Defines the minimum size of the uncompressed pool.
Tuning
If compressed memory pool grows too large, there may not be enough space in memory to house uncompressed memory which can slow down application performance due to excessive use of the compressed memory pool. Increase this value to limit the size of the compressed memory pool and make more uncompressed pages available.
Tunable Description ame_minfree_mem Purpose
Specifies the amount of free memory in a compressed memory pool free list at which the VMM will grow the compressed pool.
Tuning
If processes are being delayed waiting for compressed memory to become available, increase ame_minfree_mem to improve response time. Note, that this must be at least 64 KB less than ame_maxfree_mem.
ams_loan_policy Purpose
This tunable toggles the loaning behavior when shared memory mode is enabled.
Tuning
When the tunable is set to 0, loaning is disabled. When set to 1, loaning of file cache is enabled. When set to 2, loaning of any type of data is enabled. In response to low memory in the AMS pool, the VMM will free memory and loan it to the hypervisor.
force_relalias_lite Purpose
If set to 0, a heuristic is used, when tearing down a mmap region, to determine when to avoid locking the source mmapped segment
Tuning
This is a scalability tradeoff, controlled by relalias_percentage, possibly costing more compute time used. If set to 1, the source segment lock is avoided whenever possible, regardless of the value of relalias_percentage.
kernel_heap_psize Purpose
Specifies the default page size to use for the kernel heap.
Tuning
This is an advisory setting. Support for 64 KB pages is provided by POWER5+ and later machines and used when vmm_mpsize_support is enabled. The 16 MB pages, provided by POWER4 and later machines, should only be used for the kernel heap under high performance environments. A value of 0 indicates that the kernel will use the preferred default value of 64 KB, if that page size is supported, else 4 KB pages are used.
Tunable Description lgpg_regions Purpose
Specifies the number of large pages to reserve for implementing with the shmget() system call with the SHM_LGPAGE flag
Tuning
The lgpg_size parameter must also be used in addition to this option. The application must be modified to specify the SHM_LGPAGE flag when calling shmget(). This will improve performance in the case where there are many TLB misses and large amounts of memory is being accessed.
Although this parameter is Dynamic on DLPAR-capable systems, the nextboot value is written into the boot image when a bosboot command is run so that the setting is optimally restored at reboot.
lgpg_size Purpose
Specifies the size in bytes of the hardware-supported large pages used for the implementation for the shmget() system call with the SHM_LGPAGE flag.
Tuning
Supported on systems from POWER4 onwards. Although this parameter is Dynamic on DLPAR-capable systems, the nextboot value is written into the boot image when a bosboot command is issued so that the setting is optimally restored at reboot. The lgpg_regions parameter must be set to a non-zero value in addition to this parameter. The application must be modified to specify the SHM_LGPAGE flag when calling the shmget() subroutine. This will improve the performance in the case where there are many TLB misses and large amounts of memory is being accessed.
low_ps_handling Purpose
Specifies the action to change the system behavior in relation to process termination during low paging space conditions.
Tuning
A value of 1 indicates current behavior of process termination on low paging space. A value of 2 indicates a new behavior where processes with SIGDANGER handler will be killed, if no other processes were found earlier to recover from low paging space condition.
maxfree Purpose
Specifies the number of frames on the free list at which page-stealing is to stop.
Tuning
Observe free-list-size changes with vmstat -n command. If the vmstat -n command displays the free-list size frequently driven below minfree by application demands, increase the maxfree value to reduce calls to replenish the free list. Setting the value too high causes page replacement to run for a longer period of time. The difference between maxfree and minfree should be of the order of maxpgahead, and no less than 8.
Tunable Description maxpin% Purpose
Specifies the maximum percentage of real memory that can be pinned.
Tuning
Change if cannot pin memory, although free memory is available. If this value is changed, the new value should ensure that at least 4 MB of real memory will be left unpinned for use by the kernel. The vmo command converts maxpin% to the corresponding maxpin absolute value, which is the value used by the kernel. Change this parameter only in extreme situations, such as maximum-load benchmarking.
This dynamic parameter will have its nextboot value written into the boot image if a bosboot command is issued.
memory_frames Purpose
Number of valid memory frames.
Tuning
N/A
memplace_data Purpose
Specifies the default memory placement policy for data.
Tuning
Refers to the data of the main executable (initialized data, BSS), heap, shared library and object modules loaded at run-time. Data placement can be set to first-touch (value of 1), round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
memplace_mapped_file Purpose
Specifies the default memory placement policy for files that are mapped into the address space of a process (such as through shmat() and mmap()).
Tuning
Default placement of memory mapped files can be set to first-touch (value of 1) or round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
Tunable Description memplace_shm_anonymous Purpose
Specifies the default memory placement policy for anonymous shared memory.
Tuning
Anonymous shared memory refers to working storage memory, created via shmget() or mmap(), that can be accessed only by the creating process or its descendants. This memory is not associated with a name (or key). Default placement of anonymous shared memory can be set to first-touch (value of 1) or round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
memplace_shm_named Purpose
Specifies the default memory placement policy for named shared memory.
Tuning
Named shared memory refers to working storage memory, created via shmget() or shm_open(), which is associated with a name (or key) that allows more than one process to access it simultaneously. Default placement of named shared memory can be set to first-touch (value of 1) or round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
memplace_stack Purpose
Specifies the default memory placement policies for the program stack.
Tuning
Stack placement can be set to first-touch (value of 1) or round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
memplace_text Purpose
Specifies the default memory placement policy for the application text.
Tuning
This applies only to the text of the main executable and not to its dependencies. Text placement can be set to first-touch (value of 1) or round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
Tunable Description memplace_unmapped_file Purpose
Specifies the default memory placement policy for unmapped file access, such as through read()/write().
Tuning
Default placement of unmapped file access can be set to first-touch (value of 1) or round-robin across the system (value of 2) or automatic (value of 0), where the system decides the best placement for the memory.
minfree Purpose
Specifies the number of frames on the free list at which the VMM starts to steal pages to replenish the free list.
Tuning
Page replacement occurs when the number of free frames reaches minfree. If the processes are being delayed by page stealing, increase minfree to improve response time. The difference between maxfree and minfree should be of the order of maxpgahead, and no less than 8.
minperm% Purpose
Specifies the point below which the page-stealer will steal file or computational pages regardless of repaging rates.
Tuning
You can decrease this parameter if large number of file pages in memory is causing working storage pages to be replaced. On the other hand, if some files are known to be read repetitively, and I/O rates do not decrease with time from startup, minperm may be too low.
nokilluid Purpose
The user IDs lower than this value will be exempt from getting killed due to low page-space conditions.
Tuning
A value of 0 indicates off. Useful when system is out of paging space and the system administration processes are being killed. Either set this tunable to 1 in order to protect specific user ID processes from getting killed due to low page space or ensure there is sufficient paging space available.
npskill Purpose
Specifies the number of free paging-space pages at which the operating system begins killing processes.
Tuning
The default value is the maximum of 64 and (number of paging space pages)/128. The npskill value must be greater than zero and less than the total number of paging space pages on the system.
Tunable Description npswarn Purpose
Specifies the number of free paging-space pages at which the operating system begins sending the SIGDANGER signal to processes.
Tuning
The default value is the maximum of 512 and (4*npskill). The value of npswarn must be greater than zero and less than the total number of paging space pages on the system. Increase the value if you experience processes being killed because of low paging space.
numpsblks Purpose
Total number of paging-space blocks.
Tuning
N/A
pinnable_frames Purpose
Number of pages available for pinning
Tuning
N/A
relalias_percentage Purpose
If force_relalias_lite is set to 0, then this specifies the factor used in the heuristic to decide whether to avoid locking the source mmapped segment.
Tuning
This is used when tearing down an mmapped region and is a scalability statement, where avoiding the lock may help system throughput, but, in some cases, at the cost of more compute time used. If the number of pages being unmapped is less than this value divided by 100 and multiplied by the total number of pages in memory in the source mmapped segment, then the source lock is avoided. A value of 0 for relalias_percentage, with force_relalias_lite also set to 0, will cause the source segment lock to always be taken. Effective values for relalias_percentage will vary by workload, however, a suggested value is 200.
scrub Purpose
Enables or Disables freeing of paging space disk blocks from pages in memory for Deferred Page Space Allocation Policy pages.
Tuning
A value of 0 disables scrubbing completely. A value of 1 enables scrubbing of in memory paging space disk blocks when the number of system free paging space blocks is below npsscrubmin, and continues until above npsscrubmax.
Tunable Description v_pinshm Purpose
If set to 1, will allow pinning of shared memory segments.
Tuning
A value of 0 indicates off. Change this value when the overhead is high and in pinning or unpinning of AIO buffers from shared memory segments. Useful only if the application also sets the SHM_PIN flag when doing a shmget() call and if doing async I/O from shared memory segments.
vmm_default_pspa Purpose
This tunable controls the default aggressiveness of page size promotion. The value is an abstract aggressiveness weighting which is treated by the operating system as the inverse of the page promotion threshold.
Tuning
A value of 0 for the vmm_default_pspa setting is equivalent to a page promotion threshold of 100%, that is, a memory range must have 100% real memory occupancy in order to be promoted. A value of 100 for the vmm_default_pspa setting is equivalent to a page promotion threshold of 0%, that is, a memory range should be promoted immediately on first reference to memory in the range. A value of -1 for the vmm_default_pspa setting is equivalent to a page promotion threshold of -1, that is, never do page promotion for a memory range. Page size promotion thresholds are only considered at segment creation time. Thus, changing vmm_default_pspa will only affect the page size promotion thresholds for segments created after the tunable is adjusted.
wlm_memlimit_nonpg Purpose
Selects whether non-pageable page sizes (16M, 16G) are included in the WLM realmem and virtmem counts. If 1 is selected, then non-pageable page sizes are included in the realmem and virtmem limits count. If 0 is selected, then only pageable page sizes (4K, 64K) are included in the realmem and virtmem counts. This value can only be changed when WLM Memory Accounting is off, or the change will fail.
Tuning
When this tunable is set to 0, WLM virtual and real memory limits will only apply to pageable pages consumed by a WLM class. Because heavy use of pageable pages is what causes paging on a system, a value of 0 provides more granular control over how much a WLM class pages when non-pageable pages are in use. This tunable should only be adjusted when WLM real or virtual memory limits are being used on a system configured with non-pageable pages.
보안
RBAC 사용자와 Trusted AIX 사용자는 주의하세요. 이 명령은 특권 작업을 할 수 있으며, 특권 작업은 특권 사용자만 할 수 있습니다. 특권과 권한 목록은 lssecattr 명령이나 getcmdattr 하위 명령으로 봅니다.
영어 원문
Attention RBAC users and Trusted AIX users: This command can perform privileged operations. Only privileged users can run privileged operations. For more information about authorizations and privileges, see Privileged Command Database in Security. For a list of privileges and the authorizations associated with this command, see the lssecattr command or the getcmdattr subcommand.
예제
| 명령 | 하는 일 |
|---|---|
vmo -L |
모든 조정 값의 현재·재부팅 값, 범위, 단위, 유형, 의존 관계 |
vmo -o lgpg_regions=10 -o lgpg_size=16777216 |
POWER4 시스템에서 16MB 대형 페이지를 켜고 예약. bosboot를 제안하고 재부팅해야 적용된다고 경고 |
vmo -h nokilluid |
nokilluid의 도움말 |
vmo -r -o v_pinshm=1 |
다음 재부팅 뒤 v_pinshm을 켬 |
vmo -p -D |
모든 조정 값을 영구로 기본값으로 되돌림 |
vmo -r -a |
모든 조정 값의 재부팅 값 |
vmo -x |
모든 조정 값의 특성을 스프레드시트 형식으로 |
자주 쓰는 형태:
vmo -a | egrep "minfree|maxfree|minperm|maxperm|maxclient"
vmo -L minfree
vmo -p -o minfree=960 -o maxfree=1088
관련 명령어: ioo, schedo, no, nfso, raso
영어 원문
To list the current and reboot value, range, unit, type and dependencies of all tunable parameters managed by the vmo command, enter:
vmo -LTo turn on and reserve 16MB large pages on a POWER4 system, enter:
vmo -o lgpg_regions=10 -o lgpg_size=16777216This command will propose bosboot to the user, and warn that a reboot is necessary before the change will be effective.To display help on nokilluid, enter:
vmo -h nokilluidTo turn on
v_pinshmafter the next reboot, enter:vmo -r -o v_pinshm=1To permanently reset all vmo tunable parameters to default, enter:
vmo -p -DTo list the reboot value for all virtual memory manager tuning parameters, enter:
vmo -r -aTo list (spreadsheet format) the current and reboot value, range, unit, type and dependencies of all tunable parameters managed by the vmo command, enter:
vmo -x
Related information:
- ioo command
- schedo command
- no command
- nfso command
- raso command
리눅스(GNU)와 다른 점
리눅스에서는 sysctl(/proc/sys/vm/*, 예: vm.swappiness, vm.min_free_kbytes, vm.dirty_ratio)로 비슷한 조정을 하고, 영구 설정은 /etc/sysctl.conf에 둡니다. AIX의 -p(현재+다음 부팅)와 -r(다음 부팅만)에 해당하는 구분은 리눅스에서 sysctl -w와 설정 파일로 나뉩니다.