[CentOS-virt] kernel-plus PXE virt-install with Xen?

PJ Welsh pjwelsh at gmail.com
Wed Oct 11 18:58:35 UTC 2017


On Tue, Oct 10, 2017 at 2:32 PM, Johnny Hughes <johnny at centos.org> wrote:

> On 10/10/2017 01:46 PM, PJ Welsh wrote:
> > I'm trying to figure out how to replace the vmlinuz and initrd.img from
> > CentOS 7.4 with "fixed" kernel-plus versions in order create CentOS 7.4
> > VM's. So far I'm stuck booting via 7.3 install, adding new kernel-plus
> > and upgrading to 7.4. I've not found any complete Google answers and was
> > looking for help making sure I choose the correct approach.
> >
> > I've tried to build an initrd.img from a kernel-plus booting system via
> > "mkinitrd -f -v /boot/initrd.img $(uname -r)", but the file size is less
> > than half the one from CentOS 7.4 (17MB -vs- 47MB). I'm not even sure I
> > can just replace those files yet either.
> >
> > Any help going the correct path?
>
> I have not had time to do this yet .. BUT .. you can edit the lorax
> template to to use kernel-plus instead of kernel (and new repodata)..
> then rerun lorax to get a bootable tree and boot.iso
>
> You would then need a tree with the new kernel-plus* packages instead of
> the kernel-* packages
>
> This bug kind of explains the process:
>
> https://bugs.centos.org/view.php?id=13763
>
> (look for lorax in the bug)
>
> I do want to create a process and tree somewhere for this (likely on
> buildlogs.centos.org).  Sometime soon after I finish the i386 distro
> release (hopefully that is this week .. next week for some kind of
> bootable x86_64 Xen PV solution).
>
> The good news is, the 7.5 RHEL kernel Source RPMs should have Kevin's
> patch in it and it should work as released on Xen PV.
>
>
>
>
> _______________________________________________
> CentOS-virt mailing list
> CentOS-virt at centos.org
> https://lists.centos.org/mailman/listinfo/centos-virt
>
>

I can report full success based on your information! Thank you!
For anyone interested, the general steps I choose for the test was:
* On a build system:
  yum install lorax #if not already there
  Edit /usr/share/lorax/runtime-install.tmpl and change the "installpkg
kernel" to "installpkg kernel-plus".
  DEFAULTKERNEL=kernel-plus lorax -p Centos-Minimal -v 7 -r 7.4 -s
http://mirrors.us.kernel.org/centos/7/os/x86_64/ -s
http://mirrors.us.kernel.org/centos/7/updates/x86_64/ -s
http://mirrors.us.kernel.org/centos/7/centosplus/x86_64/ ./results/
  rsync -a ~/results/ PXEINSTALL.SERVER:/YOUR/DIR/os/x86_64/ #location of
CentOS 7.4 original install was located
  rsync -a results/images/pxeboot/{vmlinuz,initrd.img}
PXEINSTALL.SERVER:/var/lib/tftpboot/linux-install/YOUR/DIR/
* Kickstart created with required package "kernel-plus" and "repo
--name=centosplus --baseurl=http://CHOOSE/A/MIRROR/7/centosplus/x86_64/" as
additions original kickstart
* On xen server you can now run virt-install with ks=
http://PXEINSTALL.SERVER/PATH/TO/kickstart.cfg"

Thanks
pjwelsh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.centos.org/pipermail/centos-virt/attachments/20171011/04c7fd40/attachment.html>


More information about the CentOS-virt mailing list