14683287 virtualized block device io performance
TRANSCRIPT
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 1/16
YOUR WAY TO HIGH AVAILABILITY.
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 2/16
YOUR WAY TO HIGH AVAILABILITY.
Virtual Block Device Performance
Percona Performance Conference 2009
Santa Clara, CA
Florian Haas
LINBIT HA Solutions GmbH
Vienna, Austria
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 3/16
YOUR WAY TO HIGH AVAILABILITY.
So What Are We Talking About?
•
“Virtualization overhead” is not just CPU and memory overhead• Most applications are I/O bound
• I/O performance is critical in virtualization
• Let's take a look at block device performance in virtual settings!
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 4/16
YOUR WAY TO HIGH AVAILABILITY.
What Are We Comparing?
•
Relative virtual block device I/O performance in various opensource hypervisor environments
• I/O latency
• I/O throughput
• Reference platform: Debian 5.0 with 2.6.27 kernel (host andguest)
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 5/16
YOUR WAY TO HIGH AVAILABILITY.
Platforms tested
•
Baseline: reference system running in chroot• Xen 3.2 with paravirtualized guest
• Xen 3.2 with HVM guest
• KVM with IDE emulation
• KVM with paravirtualized block devices (virtio)
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 6/16
YOUR WAY TO HIGH AVAILABILITY.
What Are We Not Talking About?
•
Absolute block device performance• Non-open source hypervisors
• Network I/O performance
• Filesystem performance
• Non-Linux hosts
• Non-Linux guests
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 7/16
YOUR WAY TO HIGH AVAILABILITY.
I/O Throughput
„How much data you can write in a given period of time?“
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 8/16
YOUR WAY TO HIGH AVAILABILITY.
How We Test Block Device Throughput
dd if=/dev/zero of=/dev/vdb bs=1G count=1 oflag=direct
(no, really, it's that simple!)
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 9/16
YOUR WAY TO HIGH AVAILABILITY.
Comparative Throughput Results
chroot chroot Xen dom0 Xen Paravirt Xen HVM KVM KVM VirtIO0
5
10
15
20
25
30
35
40
45
50
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 10/16
YOUR WAY TO HIGH AVAILABILITY.
Huh?
?
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 11/16
YOUR WAY TO HIGH AVAILABILITY.
Comparative Throughput Results (Caches Off, Really?)
chroot chroot Xen dom0 Xen Paravirt Xen HVM KVM KVM VirtIO0
5
10
15
20
25
30
35
40
45
50
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 12/16
YOUR WAY TO HIGH AVAILABILITY.
I/O Latency
„How fast you can write the smallest possible chunk of data?“
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 13/16
YOUR WAY TO HIGH AVAILABILITY.
How We Test Block Device Latency
dd if=/dev/zero of=/dev/vdb bs=512 count=1000 oflag=direct
(subtle changes make a big difference)
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 14/16
YOUR WAY TO HIGH AVAILABILITY.
Comparative Latency Results
chroot chroot Xen dom0 Xen Paravirt Xen HVM KVM KVM VirtIO0
100
200
300
400
500
600
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 15/16
YOUR WAY TO HIGH AVAILABILITY.
What Do We Take Away From This?
• Xen bashing is en vogue, but in terms of performance it's actuallypretty damn good
• KVM performance is sorry with full device emulation (expected)
• KVM+VirtIO is better, but nowhere near Xen Paravirt
• Hosts lie to qemu-based guests by default
• Disabling caches in Xen 3.2 HVM... doesn't.
8/3/2019 14683287 Virtualized Block Device IO Performance
http://slidepdf.com/reader/full/14683287-virtualized-block-device-io-performance 16/16
YOUR WAY TO HIGH AVAILABILITY.
Get in touch!
• On the web:
- www.linbit.com
- http://blogs.linbit.com/florian
• By email: