Error on boot after exporting VM from XenServer 6.5 in Ova format and importing on VirtualBox/VmWarePlayer

193 views Asked by At

After exporting .Ova file, containing .ovf and .vhd resources, I'am facing errors during boot of the VM in VirtualBox/VmwarePlayer. Output ad follow ''' root (hd0,0) Filesystem type is ext2fs, partition type 0x83 kernel /vmlinuz-2.6.18-419.el5xen ro root=/dev/VolGroup00/LogVo100 console=xvc0

Error 13: Invalid or unsupported executable format '''

1

There are 1 answers

0
TheIannaman On

I found the problem. It is related to the custom Xen kernel. A fix can be found by installing a new kernel, disabling console on /etc/inittab and enabling tty.

  1. Current kernel installed packages

    <code># rpm -qa | grep ‘kernel’'</code>
    
  2. Download the latest RPM

    In my case I had to find it because the CentOs is very old

  3. Checking the RPM signature

    <code>#rpm -K *rpm</code>
    
  4. Install/Update non-kernel RPMs (optional in my case)

    <code> rpm -Uvh mkinitrd.rpm SysVinit.rpm initscripts.rpm </code>
    

    (optional, for kernel developers)

    <code>#rpm -Uvh kernel-headers.rpm kernel-source.rpm</code>
    

    Install Kernel

    <code>#rpm -ivh kernel-2.6.18-420.el5.x86_64.rpm</code>
    

    *Note: Use ivh option "install" because Uvh option "Update" will delete previous installed kernel, which may need in case of any unsuccessful update.

  5. Creating Initial RAM disk (optional, only if system has SCSI controllers/SCSI hard drive)

    <code>#ls -l /boot/initrd-* </code>
    

    If you can find an image for the currently running kernel, you need to proceed with this command for creating new initrd image for the new kernel:

    <code>#mkinitrd /boot/initrd-2.2.17-14.img 2.2.17-14</code>
    
  6. Verify the grub configuration "/etc/grub.conf" Grub will be automatically configured with the new kernel upon RPM installation

    Anyway if multiple kernels are avaible, you could specify on boot which one you want to use.

    In grub.conf, the value “0” to “default” indicates that it will boot from the first kernel mentioned.

  7. Edit /etc/inittab , This file defines three important items for the init process:

    • The system's default run level

    • What processes to start, monitor, and restart if they terminate

    • What actions to be taken when the system enters a new run level

    • Initializes console and identifies the terminal type

    We are going to comment console line and uncomment text-only terminals as follows

    ##comment this##co:2345:respawn:/sbin/agetty xvc0 9600 vt100-nav
    1:2345:respawn:/sbin/mingetty tty1
    2:2345:respawn:/sbin/mingetty tty2
    3:2345:respawn:/sbin/mingetty tty3
    4:2345:respawn:/sbin/mingetty tty4
    5:2345:respawn:/sbin/mingetty tty5
    6:2345:respawn:/sbin/mingetty tty6
    
  8. Reboot the Macchine

    In my case, after this operations I've been able to export and start the Vm on VirtualBox avoiding the previous error mentioned.