答案1
好吧,我自己已经找到了答案。答案是debugvm statistics
。
它输出 xml,但为了简单起见,我将使用 grep:
MinGW$ VBoxManage debugvm $MY_VM statistics | grep name=\"/Devices.\*Bytes\"
<Counter c="1184613888" unit="bytes" vis="used" name="/Devices/AHCI0/Port0/ReadBytes"/>
<Counter c="331036672" unit="bytes" vis="used" name="/Devices/AHCI0/Port0/WrittenBytes"/>
<Counter c="184550400" unit="bytes" vis="used" name="/Devices/AHCI0/Port1/ReadBytes"/>
<Counter c="396939264" unit="bytes" vis="used" name="/Devices/AHCI0/Port1/WrittenBytes"/>
<Counter c="1079296" unit="bytes" vis="used" name="/Devices/AHCI0/Port2/ReadBytes"/>
<Counter c="331808713" unit="bytes" name="/Devices/E1k0/ReceiveBytes"/>
<Counter c="19335791" unit="bytes" name="/Devices/E1k0/TransmitBytes"/>
AHCI
名称中包含的条目是 SATA 磁盘,E1k0
显然是网络适配器