Skip to contentSkip to conversation

Performance comparaison with dbench on KVM

DISCUSSION Laurent Vivier 2 participants 5 messages May 24, 2007 – May 25, 2007 4 messages not in the archive KVM

lore
Share & tools
lore
#0 lore raw

Hi,

I made some benchmarks with dbench on linux/KVM.

IDE means I use an image disk with "-hda"
SCSI means I use an image disk with "-sda"
(see the patch I proposed on qemu list:
http://www.mail-archive.com/[email protected]/msg08679.html )

threads KVM-21  KVM-21  KVM-24  KVM-24  KVM-25  KVM-25
        IDE     SCSI    IDE     SCSI    IDE     SCSI
1       215.272 94.8775 318.626 319.533 307.111 331.757
2       212.061 91.3193 313.217 315.163 314.577 323.715
4       197.586 81.7551 291.752 276.044 292.084 271.191
8       144.814 58.5725 188.819 198.995 168.273 165.564
16      111.505 66.3605 139.824 157.617 150.822 123.671
32      43.4109 15.7386 48.2109 50.4114 59.1074 69.5717
64      21.0567 8.3535  11.3457 19.9483 20.4877 24.5627

results are in MB/sec

Conclusion:

KVM-25 is really better than KVM-21
in most cases, SCSI is better than IDE

Cheers,
Laurent

Signature · 3 lines
------------- Laurent.Vivier-6ktuUTfB/[email protected]  --------------
       "Any sufficiently advanced technology is
  indistinguishable from magic." - Arthur C. Clarke

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

_______________________________________________
kvm-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/kvm-devel

A message that is not in the archive (sent off-list or not yet received): 46559FDF.5000609-6ktuUTfB/[email protected]

#2 lore raw
Quoted 20 lines · Laurent Vivier

Hi,

I made some benchmarks with dbench on linux/KVM.

IDE means I use an image disk with "-hda"
SCSI means I use an image disk with "-sda"
(see the patch I proposed on qemu list:
http://www.mail-archive.com/[email protected]/msg08679.html )

threads KVM-21  KVM-21  KVM-24  KVM-24  KVM-25  KVM-25
        IDE     SCSI    IDE     SCSI    IDE     SCSI
1       215.272 94.8775 318.626 319.533 307.111 331.757
2       212.061 91.3193 313.217 315.163 314.577 323.715
4       197.586 81.7551 291.752 276.044 292.084 271.191
8       144.814 58.5725 188.819 198.995 168.273 165.564
16      111.505 66.3605 139.824 157.617 150.822 123.671
32      43.4109 15.7386 48.2109 50.4114 59.1074 69.5717
64      21.0567 8.3535  11.3457 19.9483 20.4877 24.5627
Quoted 7 lines

results are in MB/sec

Conclusion:

KVM-25 is really better than KVM-21
in most cases, SCSI is better than IDE

Were you using libposix-aio? If not, did you change the aio_init function in block-raw.c (assuming that you're using a raw disk). Otherwise, QEMU by default will limit the glibc aio library to a single thread so you won't see a lot of the benefits of SCSI emulation.

Regards,

Anthony Liguori

Quoted 12 lines

Cheers,
Laurent

------------------------------------------------------------------------

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
------------------------------------------------------------------------

Quoted 5 lines

_______________________________________________
kvm-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/kvm-devel

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

A message that is not in the archive (sent off-list or not yet received): [email protected]

#4 lore raw
Quoted 25 lines · Anthony Liguori
Quoted 24 lines · Laurent Vivier

Hi,

I made some benchmarks with dbench on linux/KVM.

IDE means I use an image disk with "-hda"
SCSI means I use an image disk with "-sda"
(see the patch I proposed on qemu list:
http://www.mail-archive.com/[email protected]/msg08679.html )

threads KVM-21  KVM-21  KVM-24  KVM-24  KVM-25  KVM-25
        IDE     SCSI    IDE     SCSI    IDE     SCSI
1       215.272 94.8775 318.626 319.533 307.111 331.757
2       212.061 91.3193 313.217 315.163 314.577 323.715
4       197.586 81.7551 291.752 276.044 292.084 271.191
8       144.814 58.5725 188.819 198.995 168.273 165.564
16      111.505 66.3605 139.824 157.617 150.822 123.671
32      43.4109 15.7386 48.2109 50.4114 59.1074 69.5717
64      21.0567 8.3535  11.3457 19.9483 20.4877 24.5627

results are in MB/sec

Conclusion:

Quoted 8 lines
Quoted 3 lines

KVM-25 is really better than KVM-21
in most cases, SCSI is better than IDE

Were you using libposix-aio? If not, did you change the aio_init function in block-raw.c (assuming that you're using a raw disk). Otherwise, QEMU by default will limit the glibc aio library to a single thread so you won't see a lot of the benefits of SCSI emulation.

Hi Anthony,

I didn't modify aio_init limit...

I made some benchmarks with liposix-aio, but results are worst with IDE and crashes with SCSI (because I need to make some additional works).

It's the part on which I work now (to align buffers to avoid redundant buffer copy and open image disk with O_DIRECT).

Regards,
Laurent

Signature · 3 lines
------------- Laurent.Vivier-6ktuUTfB/[email protected]  --------------
       "Any sufficiently advanced technology is
  indistinguishable from magic." - Arthur C. Clarke

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

_______________________________________________
kvm-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/kvm-devel

A message that is not in the archive (sent off-list or not yet received): 4655A4BA.5080108-6ktuUTfB/[email protected]

#6 lore raw
Quoted 6 lines · Laurent Vivier

Anthony Liguori wrote:

Hi Anthony,

I didn't modify aio_init limit...

It would be pretty useful to give it a try. In qemu_aio_init() where aio_init() get's called. If you just bump aio_threads and aio_num from 1 to, say, 32. You should see a big difference in SCSI performance.

Regards,

Anthony Liguori

Quoted 10 lines

I made some benchmarks with liposix-aio, but results are worst with IDE and crashes with SCSI (because I need to make some additional works).

It's the part on which I work now (to align buffers to avoid redundant buffer copy and open image disk with O_DIRECT).

Regards,
Laurent

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

A message that is not in the archive (sent off-list or not yet received): [email protected]

#8 lore raw
Quoted 11 lines · Anthony Liguori
Quoted 5 lines · Laurent Vivier

Anthony Liguori wrote:
Hi Anthony,

I didn't modify aio_init limit...

It would be pretty useful to give it a try. In qemu_aio_init() where aio_init() get's called. If you just bump aio_threads and aio_num from 1 to, say, 32. You should see a big difference in SCSI performance.

I made some tests as you explained, but results are worst.

with:

        ai.aio_threads = 32;
        ai.aio_num = 32;

I have:

KVM-25 + SCSI + aio_init(32 threads)

Throughput 332.305 MB/sec 1 procs
Throughput 316.832 MB/sec 2 procs
Throughput 246.741 MB/sec 4 procs
Throughput 142.115 MB/sec 8 procs
Throughput 107.227 MB/sec 16 procs
Throughput 54.6614 MB/sec 32 proc
Throughput 21.3738 MB/sec 64 procs

Laurent

Signature · 3 lines
------------- Laurent.Vivier-6ktuUTfB/[email protected]  --------------
       "Any sufficiently advanced technology is
  indistinguishable from magic." - Arthur C. Clarke

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

_______________________________________________
kvm-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/kvm-devel