Skip to contentSkip to conversation

Can VMWare modules run alongside in XEN kernel?

DISCUSSION Peter Teoh 3 participants 7 messages Aug 7, 2007 – Aug 14, 2007

lore
Share & tools
lore

Peter Teoh

author
#0 lore raw

I would like to have VMware modules running in the XEN kernel, NOT in DOM0 kernel but outside at the hypervisor level, is that possible?

Architecturally, I noticed that xen subbranch does not implement any modules loading. If I were to load the VMware modules directly as an ELF image, will it break any existing architectural feature in XEN?

Thanks :-).

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel

#1 lore raw
Quoted 2 lines

I would like to have VMware modules running in the XEN kernel, NOT in DOM0 kernel but outside at the hypervisor level, is that possible?

Nope, afraid that can't work. Xen doesn't provide all the facilities that a Linux kernel does, so it's not able to support Linux modules at all. As you noticed, it also doesn't allow loadable modules...

The VMware modules really both need a) to run in ring0 (satisfied by your suggestion) and to b) be supported by a full host Linux kernel. Unfortunately, with Linux running in ring 1, whatever you do you are not going to be able to satisfy both of these :-(

Depending on what you're trying to do, you might find that some combination of QEmu, KVM, VMware, Xen and the various other virtualisers is able to serve your purpose better...

Cheers,
Mark

Signature · 4 lines
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!
#2 lore raw
Quoted 6 lines · Mark Williamson
Quoted 2 lines

I would like to have VMware modules running in the XEN kernel, NOT in DOM0 kernel but outside at the hypervisor level, is that possible?

Nope, afraid that can't work. Xen doesn't provide all the facilities that a Linux kernel does, so it's not able to support Linux modules at all. As you noticed, it also doesn't allow loadable modules...

Urm, sure it does - whether the xen kernel allows modules or not is just a KConfig setting. The XenSource kernel builds may not allow loadable modules but all Fedora Xen kernels are fully modular. You're right that VMware won't load/work, but that's a separate issue to the question of loadable module support in general.

Quoted 4 lines

The VMware modules really both need a) to run in ring0 (satisfied by your suggestion) and to b) be supported by a full host Linux kernel. Unfortunately, with Linux running in ring 1, whatever you do you are not going to be able to satisfy both of these :-(

Might be able to run VMware inside a HVM/fullyvirt guest.

Dan.

Signature · 4 lines
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 
#3 lore raw
Quoted 8 lines · Mark Williamson
Quoted 6 lines
Quoted 2 lines

I would like to have VMware modules running in the XEN kernel, NOT in DOM0 kernel but outside at the hypervisor level, is that possible?

Nope, afraid that can't work. Xen doesn't provide all the facilities that a Linux kernel does, so it's not able to support Linux modules at all. As you noticed, it also doesn't allow loadable modules...

Quoted 5 lines

Urm, sure it does - whether the xen kernel allows modules or not is just a KConfig setting. The XenSource kernel builds may not allow loadable modules but all Fedora Xen kernels are fully modular. You're right that VMware won't load/work, but that's a separate issue to the question of loadable module support in general.

That's true, but the OP was asking about running the modules in Xen itself "at the hypervisor level" and not in the dom0 Linux kernel. Xen used to support Linuxy APIs for modules, but even those have mostly gone now, so it's definitely not doable.

Quoted 6 lines
Quoted 4 lines

The VMware modules really both need a) to run in ring0 (satisfied by your suggestion) and to b) be supported by a full host Linux kernel. Unfortunately, with Linux running in ring 1, whatever you do you are not going to be able to satisfy both of these :-(

Might be able to run VMware inside a HVM/fullyvirt guest.

Yes, that's true :-) I can run Xen inside HVM already - regularly, in fact - but never tried VMware.

Cheers,
Mark

Signature · 4 lines
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!
#4 lore raw
Quoted 14 lines · Mark Williamson
Quoted 8 lines · Mark Williamson
Quoted 6 lines
Quoted 2 lines

I would like to have VMware modules running in the XEN kernel, NOT in DOM0 kernel but outside at the hypervisor level, is that possible?

Nope, afraid that can't work. Xen doesn't provide all the facilities that a Linux kernel does, so it's not able to support Linux modules at all. As you noticed, it also doesn't allow loadable modules...

Quoted 5 lines

Urm, sure it does - whether the xen kernel allows modules or not is just a KConfig setting. The XenSource kernel builds may not allow loadable modules but all Fedora Xen kernels are fully modular. You're right that VMware won't load/work, but that's a separate issue to the question of loadable module support in general.

Quoted 4 lines

That's true, but the OP was asking about running the modules in Xen itself "at the hypervisor level" and not in the dom0 Linux kernel. Xen used to support Linuxy APIs for modules, but even those have mostly gone now, so it's definitely not doable.

Sorry, yes, my mistake - mis-reading the earlier part of the thread.

Quoted 9 lines
Quoted 6 lines
Quoted 4 lines

The VMware modules really both need a) to run in ring0 (satisfied by your suggestion) and to b) be supported by a full host Linux kernel. Unfortunately, with Linux running in ring 1, whatever you do you are not going to be able to satisfy both of these :-(

Might be able to run VMware inside a HVM/fullyvirt guest.

Yes, that's true :-) I can run Xen inside HVM already - regularly, in fact - but never tried VMware.

Dan.

Signature · 4 lines
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 
author
#5 lore raw
In reply to Mark Williamson
Quoted 4 lines

The VMware modules really both need a) to run in ring0 (satisfied by your suggestion) and to b) be supported by a full host Linux kernel. Unfortunately, with Linux running in ring 1, whatever you do you are not going to be able to satisfy both of these :-(

1. I am not sure what is missing in the Xen hypervisor which will be needed
by a running VMware module. But I think it can be specifically patched for
Vmware. So theoretically it should be possible to run multiple emulator
(for robustness) like VirtualPC, VMWare, Xen all alongside one another. What is needed is just another hyper-hypervisor to manage these multiple "HYPERVISOR".

2. As for Linux running in Ring1 running a VMware module, I hope it could be
done in future. What is missing in the current XEN hypervisor that forbids
the guest Linux from running VMware? Logic is that in software anything
can be done (ie, if hardware is the limitation, then simulate the hardware). Eg, Look at Joanna's New Blue Pill implementation -
http://bluepillproject.org/ where nested hypervisor is supported.

Thanks :-).

#6 lore raw
Quoted 3 lines

1. I am not sure what is missing in the Xen hypervisor which will be needed
by a running VMware module. But I think it can be specifically patched
for Vmware.

Well, Xen lacks any form of disk or network IO that VMware could use to provide virtual devices to its guests - that's all done by dom0. dom0 really provides all the facilities VMware would need *except* the need to run in ring 0. See below...

Quoted 4 lines
Quoted 1 line

So theoretically it should be possible to run multiple

emulator (for robustness) like VirtualPC, VMWare, Xen all alongside one another. What is needed is just another hyper-hypervisor to manage these multiple "HYPERVISOR".

As Daniel mentioned, you might be able to use Xen as the hyper-hypervisor if you have HVM-capable hardware. It may be possible to get VMware running in a Xen HVM domain which has a "virtual ring 0" to keep VMware happy.

HVM guests can't themselves use the HVM hardware, however. This is because Xen doesn't (yet) provide emulation for it. So you can't run an HVM guest inside a Xen running in an HVM guest.

Quoted 6 lines

2. As for Linux running in Ring1 running a VMware module, I hope it could
be done in future. What is missing in the current XEN hypervisor that
forbids the guest Linux from running VMware? Logic is that in software
anything can be done (ie, if hardware is the limitation, then simulate the hardware). Eg, Look at Joanna's New Blue Pill implementation -
http://bluepillproject.org/ where nested hypervisor is supported.

The VMware module really expects to be run in ring0 directly, so that it can bang at the real physical hardware in order to work its magic. If run in a Xen paravirtualised guest at ring 1, that code would cause General Protection Faults and crash the guest... However, appropriate emulations *is* added by the combination of Xen and some HVM-capable hardware: VMware should work in an HVM guest.

HTH,
Cheers,
Mark

Signature · 4 lines
Dave: Just a question. What use is a unicyle with no seat?  And no pedals!
Mark: To answer a question with a question: What use is a skateboard?
Dave: Skateboards have wheels.
Mark: My wheel has a wheel!