Libvirt Functions
PHP Manual

libvirt_domain_memory_peek

(php-libvirt 0.1)

libvirt_domain_memory_peekRead the contents of a domain's memory

Description

string libvirt_domain_memory_peek ( resource $domain , integer $start , integer $size , integer $flags )

This function allows you to read the contents of a domain's memory. The memory which is read is controlled by the 'start', 'size' and 'flags' parameters. If 'flags' is VIR_MEMORY_VIRTUAL then the 'start' and 'size' parameters are interpreted as virtual memory addresses for whichever task happens to be running on the domain at the moment. Although this sounds haphazard it is in fact what you want in order to read Linux kernel state, because it ensures that pointers in the kernel image can be interpreted coherently. 'buffer' is the return buffer and must be at least 'size' bytes. 'size' may be 0 to test if the call would succeed. NB. The remote driver imposes a 64K byte limit on 'size'. For your program to be able to work reliably over a remote connection you should split large requests to <= 65536 bytes.

This function is experimental and untested.

Return Values

String containing requested memory


Libvirt Functions
PHP Manual