Just to clarify my problems: For each KVM virtual machine, it is actually a process running on the host. The $pid in "/proc/$pid/io" represents the VM process’s PID. All my work is done on the host, not inside the VMs. Take the VM process’s pid is “pid”, What the /proc/$pid/io records is io statistics of the VM from the host’s perspective. I understand that qemu might do some I/O coalescing kind of work, but /proc/$pid/io reveals the actual IOs submitted to the host kernel. For example, through “ps” command, i get the following info of one of my VMs: (the pid of the VM process is 4438) qemu 4438 1 0 Jun24 ? 00:06:25 /usr/bin/qemu-system-x86_64 ... [unrelevant data fields are ignored] Command line "virsh domblkstat $vmname vda” get the results below: vda rd_bytes 639415808 vda wr_bytes 728186880 Command line "cat /proc/4438/io” get the result below: read_bytes: 772415488 write_bytes: 734040064 I execute the above two commands consecutively using “&&", but we can that the results vary a lot, especially for the read_bytes. Since libvirt virDomainBlockStats API reads data from qemu i should ask the qemu folks for the answers. Great thanks, anyway. On Jun 25, 2014, at 3:45 AM, Eric Blake <eblake@xxxxxxxxxx> wrote: On 06/24/2014 02:24 AM, coperd wrote:never exceed the value of the physical disk respectively, right ? |
_______________________________________________ libvirt-users mailing list libvirt-users@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvirt-users