Xen dom0 root mount fails

Thankyou to the answerers for your time.
I am trying out xen for the first time with a view to desktop virtualisation at home.
It seems that mounting doesn’t work in xen, and with root mount timeout set to no-limit there is no error message and no obvious way to reach a terminal.
a) Why does mount work in non-virtualised startup but not in xen startup?
b) How do you get to a dracut terminal if there is no-limit timeout on root mount?
c) How do you change the root mount timeout limit?

I’ve mostly been researching xen root mount fail dom0 but also initrd debug and dracut.
I’ve read all the xen dom0 wiki pages and some of the domU wiki pages
as well as that I read a bunch of bug reports around root mount problems but they are all quite old.

I will post some logs soon.

Adam.

This log is from a failed dom0 boot under xen, followed by a successful native boot.
https://www.dropbox.com/s/00vsob4s4vahflo/xenbootlog.txt?dl=0

Hey Guys,
Why am I not getting any response?
Is my question off topic?, am I trying to do something silly?

Thanks,
Adam.

Wondering what you are trying to do…

  1. Install Xen using YaST, run the module that installs virtualization. You’ll have options to install Xen, KVM and LXC.
  2. Once installed, you simply reboot and select the Xen kernel in your Grub boot menu.
  3. When bootup completes, you should either manually or be automatically be logged in and in most cases view a Desktop (unless of course you chose not to install a Desktop environment).

That’s all there is to be running in Dom0. Dom0 is when you have a running HostOS, which is different than running Guests.

If you have any Q about what you might have expected or provide a more exact description what you are trying to do, post again.

TSU

Tsu,
Thanks for your response.
What am I trying to do? Yes install xen,
I did exactly as you described, up to 3. Bootup never completes.
Xen loads and dom0 is supposed to start booting, but screen goes blank.
I added to the boot script “acpi=off”, then dom0 starts to boot but nothing mounts (not root, not swap). Why would this happen?
I reboot and select native kernel (not Xen kernel) and it boots fine.
I tried native kernel with acpi=off and that boots fine too.
I tried other boot script options, but nothing relevant to post here.

In xen kernel I am trying to debug mounting, but have no keyboard in dracut debug console at the point of cmdline. I will try more debug breakpoints and editing fstab.

Adam.

Perhaps you didn’t update your system?
I didn’t mention as a prerequisite before installing Xen, but i’s my SOP before making any major changes to a system (and installing virtualization is a major change).
Before installing (or you can attempt now), run the following in a console

zypper up

If you’re still having problems, you can try a later version which can be found in the virtualization repo, you can add it with the following command in an elevated console

zypper ar -f http://download.opensuse.org/repositories/Virtualization/openSUSE_Leap_42.2/ Virtuulazation:42.2

Followed by updating your system as follows, which should not only refresh your rpm cache with the contents of your new repo but also automatically suggest upgrades to your xen install

zypper up

TSU

@Tsu
Thanks, will give that a try.

Updates did not fix it - the result was the same.
I did format my disk and install fresh before updating.

Booting natively works fine.
Booting Xen doesn’t. It stalls at dom0 mounting and turning on debug shows mount waiting but never succeeding.

I tried all the dracut debug I could find but dracut emergency shell does not respond to keyboard.
I will try that natively - I just realised I don’t know if that is xen related. I will try a serial console tomorrow.

This doesn’t make much sense and there is no obvious way to debug it. Help?

Did you try installing a newer version from the Virtualization repo (you have to add it) as I described?

And, what do you mean that you can mount a Xen “Dom0” from a normal kernel?
Although it’s probably possible in theory, it’s not likely you are actually doing that (my guess)?
You’ll have to describe exactly what you think you did in this case including your actual commands.

Assuming that you haven’t actually mounted Xen at all, you might also go back to basics… Like verifying your CPU supports virtualization extensions and is enabled. I posted a link to a site that describes a number of ways to do this (although is a VBox thread, determining CPU virtualization extensions is the same)
https://forums.opensuse.org/showthread.php/524158-Virtual-Box-installed-but-won-t-start?p=2819715#post2819715

You should also post the Xen packages you have installed, which should be returned with the following command

zypper se -i "xen"

TSU

Tsu thanks so much for your help. So far I didn’t find any cause for not being able to boot Dom0:

Did you try installing a newer version from the Virtualization repo (you have to add it) as I described?

Yes

And, what do you mean that you can mount a Xen “Dom0” from a normal kernel?
Although it’s probably possible in theory, it’s not likely you are actually doing that (my guess)?

Good guess - Not mount but boot (re-check my post)
What I mean is in GRUB boot menu I select either boot native, or boot Xen virtualised. One works, the other does not. I am assuming (perhaps wrongly?) that the same kernel and root partition are used in both cases.

You’ll have to describe exactly what you think you did in this case including your actual commands.

I installed Leap42.2. I booted the system. I installed Xen hypervisor using Yast.
I rebooted (into the ‘native’ non-hypervisor kernel, by selecting it in the GRUB boot menu). That worked.
I rebooted Xen virtualised (by selecting the Xen hypervisor in the Grub Boot menu) which has never worked - it gets past the XEN stage and starts initrd for dom0 but never mounts root.

Assuming that you haven’t actually mounted Xen at all, you might also go back to basics… Like verifying your CPU supports virtualization extensions and is enabled. I posted a link to a site that describes a number of ways to do this (although is a VBox thread, determining CPU virtualization extensions is the same)

I’m pretty sure IOMMU is not supported by my hardware. ***I assume that is NOT a showstopper??? <<<—
Output of egrep vmx /proc/cpuinfo

flags        : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr  pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe  syscall nx lm constant_tsc arch_perfmon pebs bts rep_good nopl  aperfmperf pni dtes64 monitor ds_cpl ***vmx*** est tm2 ssse3 cx16 xtpr pdcm  lahf_lm dtherm tpr_shadow
flags        : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca  cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall  nx lm constant_tsc arch_perfmon pebs bts rep_good nopl aperfmperf pni  dtes64 monitor ds_cpl ***vmx*** est tm2 ssse3 cx16 xtpr pdcm lahf_lm dtherm  tpr_shadow

You should also post the Xen packages you have installed, which should be returned with the following command

zypper se -i "xen"

Output

Loading repository data...
Reading installed packages...

S | Name                         | Summary                                                  | Type   
--+------------------------------+----------------------------------------------------------+--------
i | grub2-x86_64-xen             | Bootloader with support for Linux, Multiboot and more    | package
i | libvirt-daemon-xen           | Server side daemon & driver required to run XEN guests   | package
i | patterns-openSUSE-xen_server | Xen Virtual Machine Host Server                          | package
i | xen                          | Xen Virtualization: Hypervisor (aka VMM aka Microkernel) | package
i | xen-doc-html                 | Xen Virtualization: HTML documentation                   | package
i | xen-libs                     | Xen Virtualization: Libraries                            | package
i | xen-tools                    | Xen Virtualization: Control tools for domain 0           | package
i | xen_server                   | Xen Virtual Machine Host Server                          | pattern

Is there a way to debug Xen to find out if a driver or something is failing prior to Dom0 initrd? Thanks again.

You may have to ask your question on the Virtualization mail list where more expert Xen users (and maintainers) can be found
Click on the “subscribe link” at the following page

https://lists.opensuse.org/opensuse-virtual/

I don’t know if the Xen kernel is compiled with VT-d enabled (The upstream distribution supposedly has it disabled and requires you to enable). I suspect there may be other xen kernel customizations that might also need to be altered for a releatively uncommon hardware CPU that doesn’t support CPU extensions.

At the very least, even if you are eventually successful, you should know that you won’t ever likely be able to run any Guest that’s not uses a Linux kernel (eg. No Windows guests).

TSU