virtualization (VMs)
Tags: computers
KVM (kernel virtual machine)
- linux based virtualization, they work together
QUEMU
qcow2/3
- Virtual filesystems for QUEMU
Hot Plug Memory
- https://github.com/qemu/qemu/blob/db596ae19040574e41d086e78469014191d7d7fc/docs/memory-hotplug.tx11t
Xen
- Why is it important to provide timers?
- Because OS’s aren’t used to being preempted! We want to provide the OS real timers so they can do actual things
- Timing estimates, for example from TCP
- Hypervisors are meant to be tiny, has direct machine access
- Hypervisor control node actually runs as a VM
- IO rings, similar to io_uring
- Changes made to make virtualization easier
- Guest OS runs at 1, which works nicely for CPU x86 priv rings
- when the guest starts to run and gets scheduled, it communicates with the hypervisor to register a set of addresses
- When there’s a syscall, jump to this part in the OS
- GuestOSs have realtime and virtual time
- real time for congestion
- virtual time for when you get descheduled
- Hypercalls manages guests to the OS
- Paging
-
Virtualizing the MMU is very difficult, since the MMU is allowed to walk the page tables
-
Xen allows the guest to maintain its own page tables, but Xen checks all modifications to the page tables
- Software managed TLB or TLB with address space modifiers, but x86 doesn’t have this
-
everyone manages their own page tables
-
minimized involvement for xen
-
So Xen lives in the unused memory space
-
When guest operating systems creates tables, they create the table ds with address space, any memory that’s required is part of that address space
- when they register the page table with xen, then it’s read only
- Xen does recieves updates, it can batch em
-
Guest runs at 1
-