Skip to contentSkip to conversation

Looking for ideas: Single process vs multi process qemu instances

Qemu-devel Ajallooiean Hossein 2 participants 3 messages Jun 21, 2017 – Jun 24, 2017

lore
Share & tools
lore
#0 lore raw

Hi All,

we are trying to do server simulation and for that purpose we need to have multiple Qemu instances (each can have a different spec) that are part of a virtual network (ns-3 in our case).

Now for the Qemu implementation part: would it be easier/better to have all the Qemu instances under a single process or multiple processes? i am assuming if one single process is used, there will be a threading conflict that would probably need to be looked at.

I am looking at this purely from a management/performance view.

Any ideas/suggestions?

Thanks

Hoss

#1 lore raw
Quoted 6 lines · Ajallooiean Hossein

Hi All,

we are trying to do server simulation and for that purpose we need to have multiple Qemu instances (each can have a different spec) that are part of a virtual network (ns-3 in our case).

So you are talking about using TCG for simulation rather than KVM here?

Quoted 6 lines

Now for the Qemu implementation part: would it be easier/better to have all the Qemu instances under a single process or multiple processes? i am assuming if one single process is used, there will be a threading conflict that would probably need to be looked at.

QEMU isn't really setup for multiple machine instances in the one binary. If you are simulating a complex set of communicating machines then you will need one QEMU instance per machine.

TCG can now use multiple threads (one per emulated vCPU) but this has only been enabled for a subset of architectures so far. You don't say what architecture your servers machines are.

Quoted 11 lines

I am looking at this purely from a management/performance view.

Any ideas/suggestions?

Thanks

Hoss

--
Alex Bennée

#2 lore raw

Hi Alex,

Thanks for you email.

I'm on x86-64 and am emulating ARM64 using TCG - QEMU 2.9.

Well I was hoping to see if I can use a single process to have all the machines within it to do a simple lockstep execution among the emulating machines.

Im assuming the biggest issue is the thread conflicts the machines would have? other than that do you see any other obstacles?

Thanks
Hoss

________________________________________
From: Alex Bennée <[email protected]>
Sent: Thursday, June 22, 2017 11:45 AM
To: Ajallooiean Hossein
Cc: [email protected]
Subject: Re: [Qemu-devel] Looking for ideas: Single process vs multi process qemu instances

Quoted 6 lines · Ajallooiean Hossein

Hi All,

we are trying to do server simulation and for that purpose we need to have multiple Qemu instances (each can have a different spec) that are part of a virtual network (ns-3 in our case).

So you are talking about using TCG for simulation rather than KVM here?

Quoted 6 lines

Now for the Qemu implementation part: would it be easier/better to have all the Qemu instances under a single process or multiple processes? i am assuming if one single process is used, there will be a threading conflict that would probably need to be looked at.

QEMU isn't really setup for multiple machine instances in the one binary. If you are simulating a complex set of communicating machines then you will need one QEMU instance per machine.

TCG can now use multiple threads (one per emulated vCPU) but this has only been enabled for a subset of architectures so far. You don't say what architecture your servers machines are.

Quoted 11 lines

I am looking at this purely from a management/performance view.

Any ideas/suggestions?

Thanks

Hoss

--
Alex Bennée