| 1 |
Warning: |
| 2 |
|
| 3 |
The xenpaging code is new and not fully debugged. |
| 4 |
Usage of xenpaging can crash Xen or cause severe data corruption in the |
| 5 |
guest memory and its filesystems! |
| 6 |
|
| 7 |
Description: |
| 8 |
|
| 9 |
xenpaging writes memory pages of a given guest to a file and moves the |
| 10 |
pages back to the pool of available memory. Once the guests wants to |
| 11 |
access the paged-out memory, the page is read from disk and placed into |
| 12 |
memory. This allows the sum of all running guests to use more memory |
| 13 |
than physically available on the host. |
| 14 |
|
| 15 |
Requirements: |
| 16 |
|
| 17 |
xenpaging relies on Intel EPT or AMD RVI, other hardware is not |
| 18 |
supported. Only HVM guests are supported. The dom0 kernel needs |
| 19 |
paging-aware backend drivers to handle paged granttable entries. |
| 20 |
Currently only dom0 kernels based on classic Xen Linux support this |
| 21 |
functionality. |
| 22 |
|
| 23 |
Usage: |
| 24 |
|
| 25 |
Up to now xenpaging is not integrated into libxl/xend, so it has to be |
| 26 |
started manually for each guest. |
| 27 |
|
| 28 |
Once the guest is running, run xenpaging with the guest_id and the path |
| 29 |
to the pagefile: |
| 30 |
|
| 31 |
/usr/lib/xen/bin/xenpaging -f /path/to/page_file -d dom_id & |
| 32 |
|
| 33 |
Once xenpaging runs it needs a memory target, which is the memory |
| 34 |
footprint of the guest. This value (in KiB) must be written manually to |
| 35 |
xenstore. The following example sets the target to 512MB: |
| 36 |
|
| 37 |
xenstore-write /local/domain/<dom_id>/memory/target-tot_pages $((1024*512)) |
| 38 |
|
| 39 |
Now xenpaging tries to page-out as many pages to keep the overall memory |
| 40 |
footprint of the guest at 512MB. |
| 41 |
|
| 42 |
Todo: |
| 43 |
- integrate xenpaging into libxl |
| 44 |
|
| 45 |
# vim: tw=72 |