1 .\" Hey Emacs! This file is -*- nroff -*- source.
3 .\" This manpage is Copyright (C) 2006 Silicon Graphics, Inc.
6 .\" Permission is granted to make and distribute verbatim copies of this
7 .\" manual provided the copyright notice and this permission notice are
8 .\" preserved on all copies.
10 .\" Permission is granted to copy and distribute modified versions of this
11 .\" manual under the conditions for verbatim copying, provided that the
12 .\" entire resulting derived work is distributed under the terms of a
13 .\" permission notice identical to this one.
15 .\" FIXME Should programs normally be using this API directly, or should
16 .\" they rather be using interfaces in the numactl package?
17 .\" (e.g., compare with recommendation in mbind(2)).
19 .\" Japanese Version Copyright (c) 2008 Akihiro MOTOKI
20 .\" all rights reserved.
21 .\" Translated 2008-10-26, Akihiro MOTOKI <amotoki@dd.iij4u.or.jp>
23 .TH MOVE_PAGES 2 2008-10-06 "Linux" "Linux Programmer's Manual"
25 move_pages \- ¤¢¤ë¥×¥í¥»¥¹¤Î¸Ä¡¹¤Î¥Ú¡¼¥¸¤òÊ̤ΥΡ¼¥É¤Ë°ÜÆ°¤¹¤ë
28 .B #include <numaif.h>
30 .BI "long move_pages(int " pid ", unsigned long count, void **" pages ,
31 .BI " const int *" nodes ", int *" status ", int " flags );
41 ¤Ç»ØÄꤵ¤ì¤¿¥á¥â¥ê¥Î¡¼¥É¤Ë°ÜÆ°¤¹¤ë¡£
46 ¤Ç¤Ï°ÜÆ°¤µ¤ì¤ë¥Ú¡¼¥¸¤Ë´Ø¤¹¤ëÀ©Ìó¤ò»ØÄꤹ¤ë¡£
49 ¤Ï¡¢°ÜÆ°¤µ¤ì¤ë¥Ú¡¼¥¸¤¬Â°¤¹¤ë¥×¥í¥»¥¹¤Î ID ¤Ç¤¢¤ë¡£
50 ÊÌ¤Î¥×¥í¥»¥¹¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤¹¤ë¤¿¤á¤Ë¤Ï¡¢¸Æ¤Ó½Ð¤·¸µ¤¬Æø¢
52 ¤ò»ý¤Ã¤Æ¤¤¤ë¤«¡¢¸Æ¤Ó½Ð¤·¤¿¥×¥í¥»¥¹¤Î¼Â¥æ¡¼¥¶ ID ¤«¼Â¸ú¥æ¡¼¥¶ ID ¤¬
53 ¥Ú¡¼¥¸°ÜÆ°ÂÐ¾Ý¤Î¥×¥í¥»¥¹¤Î¼Â¥æ¡¼¥¶ ID ¤«Êݸ set-user-ID ¤Î¤É¤Á¤é¤«¤È
54 °ìÃפ·¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
58 ¤Ï¸Æ¤Ó½Ð¤·¤¿¥×¥í¥»¥¹¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤¹¤ë¡£
61 ¤Ï°ÜÆ°¤¹¤ë¥Ú¡¼¥¸¿ô¤Ç¤¢¤ë¡£
67 ¤Î 3 ¤Ä¤ÎÇÛÎó¤ÎÂ礤µ¤¬ÄêµÁ¤µ¤ì¤ë¡£
70 ¤Ï¡¢°ÜÆ°¤¹¤Ù¤¥Ú¡¼¥¸¤Ø¤Î¥Ý¥¤¥ó¥¿¤ÎÇÛÎó¤Ç¤¢¤ê¡¢
71 ³Æ¥Ý¥¤¥ó¥¿¤Ï¥Ú¡¼¥¸¶³¦¤Ë·¤¨¤¿Ãͤò»ØÄꤹ¤Ù¤¤Ç¤¢¤ë¡£
72 .\" FIXME what if they are not aligned?
74 ¤Ç»ØÄꤵ¤ì¤¿¥×¥í¥»¥¹¤Ç¸«¤¨¤ë¥¢¥É¥ì¥¹¤ò»ØÄꤹ¤ë¡£
77 ¤Ï¡¢³Æ¥Ú¡¼¥¸¤Î´õ˾¤Î°ÜÆ°¾ì½ê¤ò¼¨¤¹À°¿ôÃͤÎÇÛÎó¤Ç¤¢¤ê¡¢
78 ÇÛÎó¤Î³ÆÍ×ÁǤϥΡ¼¥ÉÈÖ¹æ¤Ç¤¢¤ë¡£
80 ¤Ë¤Ï NULL ¤ò»ØÄꤹ¤ë¤³¤È¤â¤Ç¤¡¢¤³¤Î¾ì¹ç¤Ë¤Ï
82 ¤Ï¤É¤Î¥Ú¡¼¥¸¤â°ÜÆ°¤·¤Ê¤¤¤¬¡¢³Æ¥Ú¡¼¥¸¤¬¸½ºßÇÛÃÖ¤µ¤ì¤Æ¤¤¤ë¥Î¡¼¥É¤òÇÛÎó
84 ¤Ë³ÊǼ¤·¤ÆÊÖ¤¹¡£¤É¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤¹¤ëɬÍפ¬¤¢¤ë¤«¤òȽÃǤ¹¤ë¤¿¤á¤Ë¡¢
85 ³Æ¥Ú¡¼¥¸¤Î¾õÂ֤μèÆÀ¤¬É¬Íפʾì¹ç¤â¤¢¤ë¡£
88 ¤Ï¡¢³Æ¥Ú¡¼¥¸¤Î¾õÂÖ¤òɽ¤¹À°¿ôÃͤÎÇÛÎó¤Ç¤¢¤ë¡£
89 ¤³¤ÎÇÛÎó¤Ë͸ú¤ÊÃͤ¬³ÊǼ¤µ¤ì¤ë¤Î¤Ï¡¢
91 ¤¬¥¨¥é¡¼¤òÊÖ¤µ¤Ê¤«¤Ã¤¿¾ì¹ç¤À¤±¤Ç¤¢¤ë¡£
94 ¤Ë¤Ï¡¢¤É¤Î¼ïÎà¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤¹¤ë¤«¤ò»ØÄꤹ¤ë¡£
96 ¤Ï¡¢¤½¤Î¥×¥í¥»¥¹¤¬ÇÓ¾Ū¤Ë»ÈÍѤ·¤Æ¤¤¤ë¥Ú¡¼¥¸¤À¤±¤ò°ÜÆ°¤¹¤ë¤³¤È¤ò°ÕÌ£¤¹¤ë¡£
98 ¤Ï¡¢Ê£¿ô¤Î¥×¥í¥»¥¹´Ö¤Ç¶¦Í¤µ¤ì¤Æ¤¤¤ë¥Ú¡¼¥¸¤â°ÜÆ°¤Ç¤¤ë¤³¤È¤ò°ÕÌ£¤¹¤ë¡£
100 ¤ò»ÈÍѤ¹¤ë¤¿¤á¤Ë¤Ï¡¢¤½¤Î¥×¥í¥»¥¹¤¬Æø¢
102 ¤ò»ý¤Ã¤Æ¤¤¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
103 .SH status ÇÛÎó¤Ë³ÊǼ¤µ¤ì¤ë¥Ú¡¼¥¸¾õÂÖ
105 ÇÛÎó¤Î³ÆÍ×ÁǤȤ·¤Æ¡¢°Ê²¼¤ÎÃͤ¬ÊÖ¤µ¤ì¤ë¡£
108 ¤½¤Î¥Ú¡¼¥¸¤¬ÇÛÃÖ¤µ¤ì¤Æ¤¤¤ë¥Î¡¼¥É¤ò¼¨¤¹¡£
111 ¤½¤Î¥Ú¡¼¥¸¤ÏÊ£¿ô¤Î¥×¥í¥»¥¹¤Ë¤è¤ê¥Þ¥Ã¥×¤µ¤ì¤Æ¤ª¤ê¡¢
113 ¤¬»ØÄꤵ¤ì¤¿¾ì¹ç¤Ë¤Î¤ß°ÜÆ°¤Ç¤¤ë¡£
116 ¤½¤Î¥Ú¡¼¥¸¤¬¸½ºß¥Ó¥¸¡¼¤Ç¤¢¤ê¡¢°ÜÆ°¤Ç¤¤Ê¤¤¡£¸å¤Ç¤â¤¦°ìÅٻ¤³¤È¡£
117 ¤³¤Î¾õ¶·¤Ï¡¢¥Ú¡¼¥¸¤¬ I/O ¤Î¼Â¹ÔÃæ¤Ç¤¢¤Ã¤¿¤ê¡¢¥«¡¼¥Í¥ë¤Î¾¤Î¥µ¥Ö¥·¥¹¥Æ¥à
118 ¤¬¤½¤Î¥Ú¡¼¥¸¤Ø¤Î»²¾È¤òÊÝ»ý¤·¤Æ¤¤¤ë¾ì¹ç¤ËȯÀ¸¤¹¤ë¡£
121 ¤½¤Î¥Ú¡¼¥¸¤¬ zero page ¤Ç¤¢¤ë¤«¡¢¤½¤Î¥á¥â¥êÎΰè¤Ï¤½¤Î¥×¥í¥»¥¹¤Ë¤è¤ê
125 ¥Ú¡¼¥¸¤ò½ñ¤Ì᤹ (write back) ¤³¤È¤¬¤Ç¤¤Ê¤¤¡£
126 ¥Ú¡¼¥¸¤¬ dirty ¤Ç¡¢¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤¬ dirty ¤Ê¥Ú¡¼¥¸¤ò°ÜÆ°¤Ç¤¤ë¤è¤¦¤Ê
127 °ÜÆ°µ¡Ç½¤òÄ󶡤·¤Æ¤¤¤Ê¤¤¤¿¤á¡¢¤½¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤¹¤ë¤¿¤á¤Ë¤Ï¥Ú¡¼¥¸¤ò
128 ½ñ¤Ìᤵ¤Ê¤±¤ì¤Ð¤Ê¤é¤Ê¤¤¡£
131 dirty ¤Ê¥Ú¡¼¥¸¤ò°ÜÆ°¤Ç¤¤Ê¤¤¡£
132 ¥Õ¥¡¥¤¥ë¥·¥¹¥Æ¥à¤¬ dirty ¤Ê¥Ú¡¼¥¸¤ò°ÜÆ°¤¹¤ë¤¿¤á¤Îµ¡Ç½¤òÄ󶡤·¤Æ¤ª¤é¤º¡¢
133 ¥Ú¡¼¥¸¤ò½ñ¤Ì᤹ǽÎϤâ¤Ê¤¤¡£
139 °ÜÆ°Àè¤Î¥Î¡¼¥É¤Ç¥á¥â¥ê¤ò³ÎÊݤ¹¤ë¤³¤È¤¬¤Ç¤¤Ê¤¤¡£
144 .\" FIXME Is the following quite true: does the wrapper in numactl
145 .\" do the right thing?
146 ¥¨¥é¡¼¤Î¾ì¹ç¡¢\-1 ¤òÊÖ¤·¡¢
148 ¤Ë¥¨¥é¡¼¤ò¼¨¤¹ÃͤòÀßÄꤹ¤ë¡£
152 °ÜÆ°¤¹¤Ù¤¥Ú¡¼¥¸¤¬Â¿²á¤®¤ë¡£
155 .\" FIXME Clarify "current cpuset". Is that the cpuset of the caller
157 °ÜÆ°Àè¤Î¥Î¡¼¥É¤Î¤¤¤º¤ì¤«¤¬¸½ºß¤Î CPU ½¸¹ç¤Ç¤Ïµö²Ä¤µ¤ì¤Æ¤¤¤Ê¤¤¡£
160 ¥Ñ¥é¥á¡¼¥¿ÇÛÎó¤Ë¥¢¥¯¥»¥¹¤Ç¤¤Ê¤«¤Ã¤¿¡£
168 ¤Ç¤â¤Ê¤¤Ãͤ¬»ØÄꤵ¤ì¤¿¤«¡¢¥«¡¼¥Í¥ë¥¹¥ì¥Ã¥É¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤µ¤»¤è¤¦¤È¤·¤¿¡£
171 °ÜÆ°Àè¤Î¥Î¡¼¥É¤Î¤¤¤º¤ì¤«¤¬¥ª¥ó¥é¥¤¥ó¤Ç¤Ê¤¤¡£
174 °ÜÆ°¤¬É¬Íפʥڡ¼¥¸¤¬Á´¤¯¸«¤Ä¤«¤é¤Ê¤«¤Ã¤¿¡£
175 »ØÄꤵ¤ì¤¿Á´¤Æ¤Î¥Ú¡¼¥¸¤¬¡¢¤¹¤Ç¤Ë°ÜÆ°Àè¤Î¥Î¡¼¥É¤Ë¸ºß¤¹¤ë¤«¡¢Â¸ºß¤·¤Ê¤¤¤«¡¢
176 ̵¸ú¤Ê¥¢¥É¥ì¥¹¤Ç¤¢¤Ã¤¿¤«¡¢Ê£¿ô¤Î¥×¥í¥»¥¹¤Ë¤è¤Ã¤Æ¥Þ¥Ã¥×¤µ¤ì¤Æ¤¤¤Æ°ÜÆ°¤Ç¤
177 ¤Ê¤«¤Ã¤¿¤«¡¢¤Î¤¤¤º¤ì¤«¤Ç¤¢¤Ã¤¿¡£
182 ¤ò»ØÄꤷ¤¿¤¬¡¢½½Ê¬¤ÊÆø¢
185 ¤Þ¤¿¤Ï¡¢¸Æ¤Ó½Ð¤·¸µ¤¬Â¾¤Î¥æ¡¼¥¶¤Ë°¤¹¤ë¥×¥í¥»¥¹¤Î¥Ú¡¼¥¸¤ò°ÜÆ°¤·¤è¤¦¤È¤·¤¿¤¬¡¢
186 ¤½¤ì¤ò¹Ô¤¨¤ë¤À¤±¤ÎÆø¢
191 ¥×¥í¥»¥¹¤¬Â¸ºß¤·¤Ê¤¤¡£
194 ¤Ï¡¢¥Ð¡¼¥¸¥ç¥ó 2.6.18 ¤Ç½é¤á¤Æ Linux ¤ËÅо줷¤¿¡£
196 ¤³¤Î¥·¥¹¥Æ¥à¥³¡¼¥ë¤Ï Linux ¸ÇͤǤ¢¤ë¡£
198 ¥é¥¤¥Ö¥é¥ê¤Ë¤è¤ë¥µ¥Ý¡¼¥È¤Ë¤Ä¤¤¤Æ¤Ï
202 .\" FIXME Clarify "current cpuset". Is that the cpuset of the caller
204 ¸½ºß¤Î CPU ½¸¹ç¤Çµö²Ä¤µ¤ì¤Æ¤¤¤ë¥Î¡¼¥É¤Î½¸¹ç¤ò¼èÆÀ¤¹¤ë¤Ë¤Ï¡¢¥Õ¥é¥°
205 .B MPOL_F_MEMS_ALLOWED
207 .BR get_mempolicy (2)
209 ¼èÆÀ¤·¤¿¾ðÊó¤Ï¡¢CPU ½¸¹ç¤Î¼êÆ°¤Þ¤¿¤Ï¼«Æ°¤Ç¤ÎºÆ¹½À®¤Ë¤è¤ê
210 ¤¤¤Ä²¿»þÊѲ½¤·¤Æ¤·¤Þ¤¦¤«Ê¬¤«¤é¤Ê¤¤¡£
212 ¤³¤Î´Ø¿ô¤ò»ÈÍѤ¹¤ë¤È¡¢¥Ú¡¼¥¸¤Î°ÌÃÖ (¥Î¡¼¥É) ¤¬
213 »ØÄꤵ¤ì¤¿¥¢¥É¥ì¥¹¤ËÂФ·¤ÆÀßÄꤵ¤ì¤¿¥á¥â¥ê¥Ý¥ê¥·¡¼
215 »²¾È) ¤ä»ØÄꤵ¤ì¤¿¥×¥í¥»¥¹¤ËÂФ·¤ÆÀßÄꤵ¤ì¤¿¥á¥â¥ê¥Ý¥ê¥·¡¼
216 .RB ( set_mempolicy (2)
217 »²¾È) ¤Ë°ãÈ¿¤·¤Æ¤·¤Þ¤¦²ÄǽÀ¤¬¤¢¤ë¡£
218 ¤Ä¤Þ¤ê¡¢¥á¥â¥ê¥Ý¥ê¥·¡¼¤Ï
220 ¤Ç»È¤ï¤ì¤ë°ÜÆ°Àè¥Î¡¼¥É¤òÀ©¸Â¤·¤Ê¤¤¤È¤¤¤¦¤³¤È¤Ç¤¢¤ë¡£
222 .BR get_mempolicy (2),
224 .BR set_mempolicy (2),
229 .BR migratepages (8),