Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


FreeBSD (12) + KVM bad performance
New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

FreeBSD (12) + KVM bad performance

jordynegen11jordynegen11 Member
edited May 2019 in Help

Hello,

Currently we're running QEMU/KVM on a CentOS 7 server. We found out that the performance of a FreeBSD VM is significant lower then a Ubuntu VM.

We're talking about 15% less CPU/mem performance and 60% less disk IO performance.

Result of CPU benchmark on FreeBSD VM: (2 CPU cores)

--- proc/mem/performance test single core ---
................................................................
64 rounds~ 1.00 GB -> 171.89 MB/s
--- proc/mem/performance test multi-core ---
................
4 times 64 rounds ~ 4.00 GB -> 364.98 MB/s

Result of CPU benchmark on Ubuntu VM: (2 CPU cores)

--- proc/mem/performance test single core ---
................................................................
64 rounds~ 1.00 GB -> 231.36 MB/s
--- proc/mem/performance test multi-core ---
................
4 times 64 rounds ~ 4.00 GB -> 500.66 MB/s

Result of disk benchmark on FreeBSD VM:

--- disk test ---
Sequential writing
.................................................................................................................................
347.55 MB/s
Random writing
.................................................................................................................................
304.57 MB/s
Sequential reading
.................................................................................................................................
699.01 MB/s
Random reading
.................................................................................................................................
690.14 MB/s

Result of disk benchmark on Ubuntu VM:

--- disk test ---
Sequential writing
.................................................................................................................................
725.89 MB/s
Random writing
.................................................................................................................................
1.247 GB/s
Sequential reading
.................................................................................................................................
2.391 GB/s
Random reading
.................................................................................................................................
2.152 GB/s

Both VMs are located on the same node so they have the same CPU and RAM. All drivers are set to VIRTIO.

Mabe there is someone here that has or had the same problem as us? Is this normal?

I think mabe it's a driver issue in FreeBSD, (for the disk problems) but i'm not sure yet.

help is appreciated :)

Comments

  • Try https://www.netbsd.org and see what kind of performance that gives you?

  • jsgjsg Member, Resident Benchmarker

    @theblackesthat said:
    Try https://www.netbsd.org and see what kind of performance that gives you?

    Uhm, what would that tell him about the problem he described?

  • angstromangstrom Moderator

    @theblackesthat said:
    Try https://www.netbsd.org and see what kind of performance that gives you?

    If the OP wants to use FreeBSD, it's not clear that "try NetBSD" (for that matter, why not: "try OpenBSD") is such useful advice.

    @jordynegen11:

    As far as I'm aware, VirtIO yields better results with Linux than with *BSD, so I'm not sure that one is able to replicate Linux performance with *BSD on KVM even in the best of cases. But the difference that you observe isn't fully explained by this.

    By the way, are you using CPU host-passthrough on both KVMs?

    Thanked by 1jordynegen11
  • deankdeank Member, Troll
    edited May 2019

    Sending a complaint to EU might help.

    Thanked by 2First-Root luper769
  • angstromangstrom Moderator

    Also, what file system are you using on FreeBSD? It may be better to try with UFS (UFS2).

  • jordynegen11jordynegen11 Member
    edited May 2019

    Hi,

    Thanks for your answer.

    By the way, are you using CPU host-passthrough on both KVMs?

    Yes, I enabled host-passthrough on both VMs

    Also, what file system are you using on FreeBSD? It may be better to try with UFS (UFS2).

    Gonna try that!

  • angstromangstrom Moderator

    @jordynegen11 said:

    Hi,

    Thanks for your answer.

    By the way, are you using CPU host-passthrough on both KVMs?

    Yes, I enabled host-passthrough on both VMs

    Also, what file system are you using on FreeBSD? It may be better to try with UFS (UFS2).

    Gonna try that!

    By the way, as a general sanity test, it may be good to try the same version of FreeBSD with the same guest settings on a KVM at another provider in order to see whether the results are comparable.

    Also, how are you doing the benchmarks? Any chance that they may be Linux-biased in some way?

  • angstrom said: the way, as a general sanity test, it may be good to try the same version of FreeBSD with the same guest settings on a KVM at another provider in order to see whether the results are comparable.

    Also, how are you doing the benchmarks? Any chance that they may be Linux-biased in some way?

    I used 3 diffrent benchmarks special made for FreeBSD and Linux. All the same results.

  • FalzoFalzo Member

    good luck with your provider tag.

    Thanked by 2First-Root Amitz
  • jordynegen11jordynegen11 Member
    edited June 2019

    @Falzo said:

    good luck with your provider tag.

    We don't have any FreeBSD hypervisors and since bhyve only runs on FreeBSD, this is not an option. @FiroSolutions

  • jsgjsg Member, Resident Benchmarker

    @jordynegen11 said:

    @Falzo said:

    good luck with your provider tag.

    We don't have any FreeBSD hypervisors and since bhyve only runs on FreeBSD, this is not an option. @FiroSolutions

    And you are right. While Bhyve is really nice it also is really young, even still immature.

  • FHRFHR Member, Host Rep
    edited June 2019

    2.4GB/s random reads sound awfully like Linux cache. I reckon it's a benchmarking error.

Sign In or Register to comment.