Opened 6 years ago

Closed 4 years ago

#491 closed defect (fixed)

Xen kernels not found

Reported by: apollo13 Owned by: bruno
Priority: normal Milestone: 3.0.5
Component: mindi Version: 2.2.9.7
Severity: normal Keywords:
Cc:

Description (last modified by bruno)

Hi, I am using Mindi v2.0.7.8-r2840, the mindi log shows that a xen kernel is found:

Your Xen kernel is /boot/vmlinuz-2.6.26-2-xen-amd64 (v2.6.26-2-xen-amd64)

but it never returns that kernel from TryToFindKernelPath?, $output is only set for normal kernels. As such mindi fails to find the kernel, is that wanted behavior?

Attachments (1)

mindi.log (6.1 KB) - added by apollo13 6 years ago.

Download all attachments as: .zip

Change History (20)

comment:1 Changed 6 years ago by apollo13

Ok, this is a debian system and the problem is that it doesn't find a version for the kernels (eg KernelVer? always returns ). Plz tell me which infos you need exactly;

ls /boot/
config-2.6.26-2-amd64	   initrd.img-2.6.26-2-amd64	  initrd.img-2.6.26-2-xen-amd64.bak  System.map-2.6.26-2-xen-amd64  xen-3.2-1-amd64.gz
config-2.6.26-2-xen-amd64  initrd.img-2.6.26-2-amd64.bak  lost+found			     vmlinuz-2.6.26-2-amd64
grub			   initrd.img-2.6.26-2-xen-amd64  System.map-2.6.26-2-amd64	     vmlinuz-2.6.26-2-xen-amd64

menu.lst:

title		Xen 3.2-1-amd64 / Debian GNU/Linux, kernel 2.6.26-2-xen-amd64
root		(hd0,0)
kernel		/xen-3.2-1-amd64.gz dom0_mem=256M
module		/vmlinuz-2.6.26-2-xen-amd64 root=/dev/mapper/vg1-serv0--root ro console=tty0
module		/initrd.img-2.6.26-2-xen-amd64

comment:2 Changed 6 years ago by bruno

  • Description modified (diff)
  • Status changed from new to assigned

Of course, this is not the wanted behaviour :-(

Could you attach your full /var/log/mindi.log please ? Which Debian version are you running ? (in order to make package for you to test)

comment:3 Changed 6 years ago by apollo13

serv0:~# cat /etc/issue.net 
Debian GNU/Linux 5.0

Changed 6 years ago by apollo13

comment:4 Changed 6 years ago by bruno

Could you try to test the new beta version available at ftp://ftp.mondorescue.org/test/debian/5.0 ?

If it still doesn't work, I'd like to get from you the result of the command:

sh -x mindi --findkernel 2>&1 > /tmp/mindi.res

and provide me with both the /tmp/mindi.res and /var/log/mindi.log files please.

$output is indeed only set for normal kernels. But the TryToFindKernelPath? function should set up some variables for the Xen kernel. It seems this doesn't work correctly in your case.

comment:5 Changed 6 years ago by bruno

I found another issue with mindi and kernel detection that may have been also behind the problem you've reported here.

Please check the new beta I just released for Debian 5 at ftp://ftp.mondorescue.org/test/debian/5.0 (2.0.7.9-0.20111006012303)

This should now be fixed

comment:6 follow-up: Changed 6 years ago by apollo13

Ok, first of all I have Debian 6 by now -- I hope I got the correct package (I installed mindi manually from the 5.0 repo):

florian@serv1:~$ apt-cache policy mindi
mindi:
  Installed: 2.0.7.9-0.20111006012303
  Candidate: 2.0.7.9-0.20111006012303
  Version table:
 *** 2.0.7.9-0.20111006012303 0
        100 /var/lib/dpkg/status
     2.0.7.9-0.20110928133209 0
        500 ftp://ftp.mondorescue.org/test/debian/ 6.0/contrib amd64 Packages
florian@serv1:~$ apt-cache policy mindi-busybox 
mindi-busybox:
  Installed: 1.18.3-3
  Candidate: 1.18.3-3
  Version table:
 *** 1.18.3-3 0
        500 ftp://ftp.mondorescue.org/test/debian/ 6.0/contrib amd64 Packages
        100 /var/lib/dpkg/status
     1.2.1-4 0
        500 http://ftp.at.debian.org/debian/ squeeze/main amd64 Packages

Output of mindi:

root@serv1:~# mindi --findkernel
TryToFindKernelPath found 

And logfile: http://apolloner.eu/~apollo13/mindi.log, Note that by now it's actually a completly different machine (but still with xen…)

comment:7 in reply to: ↑ 6 Changed 6 years ago by bruno

Replying to apollo13:

Ok, first of all I have Debian 6 by now -- I hope I got the correct package (I installed mindi manually from the 5.0 repo):

Ok, next time I'll make a deb 6 package then :-)

And logfile: http://apolloner.eu/~apollo13/mindi.log, Note that by now it's actually a completly different machine (but still with xen…)

What is strange is that it doesn't detect that you're running a Xen kernel. What is the result of

ls -al /proc/sys/xen

If this doesn't exist, then do you have another hint I could use to detect that you're running a Xen kernel ?

comment:8 Changed 6 years ago by apollo13

As far as I know /proc/sys/xen only exists on non pvops systems, the best check is probably:

cat /proc/xen/capabilities 
control_d

to determine if it's a dom0 (also compare with: http://wiki.xensource.com/xenwiki/XenCommonProblems#head-26434581604cc8357d9762aaaf040e8d87b37752).

EDIT:// and to answer your question, /proc/sys/xen does indeed not exist here

Last edited 6 years ago by apollo13 (previous) (diff)

comment:9 Changed 6 years ago by bruno

Fixed in rev [2889]. Packages are on their way for debian 6 at ftp://ftp.mondorescue.org/test/debian/6.0

Please test and report again.

comment:10 Changed 6 years ago by apollo13

Okay, I patched the line myself for now and now I get:

root@serv1:~# mindi --findkernel
TryToFindKernelPath found 

and http://apolloner.eu/~apollo13/mindi.log.2 -- So it actually finds out that I am running xen, but calling mindi without any further args to generate the bootdisk still asks for a kernel path. But we are one step further :)

comment:11 Changed 6 years ago by apollo13

So now it finds my Xen kernel correctly, but fails to find the kernel used for booting:

        multiboot       /boot/xen-4.0-amd64.gz placeholder dom0_mem=512M dom0_max_vcpus=1 dom0_vcpus_pin
        module  /boot/vmlinuz-2.6.32-5-xen-amd64 placeholder root=/dev/mapper/system-xen--root ro  quiet
        echo    'Loading initial ramdisk ...'
        module  /boot/initrd.img-2.6.32-5-xen-amd64

Using:

mindi
Mindi Linux mini-distro generator v2.0.7.9-r2881
Latest Mindi is available from http://www.mondorescue.org
BusyBox sources are available from http://www.busybox.net
------------------------------------------------------------------------------
Mindi-BusyBox v1.18.5-r2888 (2011-10-12 05:41:52 CEST) multi-call binary.
Do you want to use your own kernel to build the boot disk ([y]/n) ?
TryToFindKernelPath found 
Please enter kernel path : /boot/xen-4.0-amd64.gz

it at least builds an image, let's see if that's useable :)

comment:12 Changed 6 years ago by apollo13

actually it failed again:

Call GetInitrdFilesystemToUse() with parameter /boot/xen-4.0-amd64.gz to get filesystem to use for initrd.
  GetInitrdFilesystemToUse(): called with parameter: /boot/xen-4.0-amd64.gz
  GetInitrdFilesystemToUse(): Filesytem to use for initial ram disk is UNSUPPORTED.\n
FATAL ERROR. Filesystem UNSUPPORTED not supported for initrd image. Terminating.
}}} :/

comment:13 Changed 6 years ago by bruno

Please use the latest mindi available at ftp://ftp.mondorescue.org/test/debian/6.0

Then run sh -x mindi --findkernel 2>&1 > /tmp/mindi.res

And attach the /tmp/mindi.res here.

If your Xen kernel is found it should pass into line 2310 and set KERNEL_IS_XEN="yes", which in turn should give us line 2934 a valid test and some more printing than what you get.

comment:14 Changed 6 years ago by apollo13

first of all the packages are broken:

Unpacking mindi-busybox (from .../mindi-busybox_1.18.3-3_amd64.deb) ...
Unpacking mindi (from .../mindi_2.0.7.9-0.20110928133209_amd64.deb) ...
dpkg: error processing /var/cache/apt/archives/mindi_2.0.7.9-0.20110928133209_amd64.deb (--unpack):
 trying to overwrite '/usr/lib/mindi/rootfs/sbin/init', which is also in package mindi-busybox 1.18.3-3
configured to not write apport reports
                                      Processing triggers for man-db ...
Errors were encountered while processing:
 /var/cache/apt/archives/mindi_2.0.7.9-0.20110928133209_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

After some dpkg magic:

sudo mindi --version
Mindi v2.0.7.9-r2872

But that one is from 09/29/2011, did you forget to upload mindi?

Either way here is the log: http://apolloner.eu/~apollo13/mindi.log.3

comment:15 Changed 6 years ago by bruno

You should use: ftp://ftp.mondorescue.org/test/debian/6.0/mindi_2.1.0-0.20111113120008_amd64.deb or the newer one in process of generation.

comment:16 Changed 6 years ago by bruno

  • Milestone changed from 3.0.0 to 3.0.1

If not fixed with the upcoming 3.0.0, it will be in 3.0.1

comment:17 Changed 5 years ago by bruno

  • Milestone changed from 3.0.2 to 3.0.3

Please check that the latest 3.0.2 fixes this issue

comment:18 Changed 5 years ago by bruno

Latest mindi on RHEL5 doesn't fix the issue as reported by a user

comment:19 Changed 4 years ago by bruno

  • Resolution set to fixed
  • Status changed from assigned to closed
Note: See TracTickets for help on using tickets.