What's the correct way to install OpenVZ via kickstart [message #51477] |
Tue, 24 June 2014 16:13 |
PeterSteele
Messages: 5 Registered: February 2014 Location: United States
|
Junior Member |
|
|
I have a streamlined CentOS install that's automated through the kickstart facility. I want my custom image to use the OpenVZ kernel instead of the default CentOS kernel. I'm not sure what the correct way is to do this.
My current kickstart script does not explicitly reference which kernel files are installed. This is handled automatically by the @core entry in the %packages section:
%packages --nobase
@core
I know I can add code in %post to install the kickstart kernel as one of the final stages of the kickstart install process. Is this the best way?
|
|
|
|
|
Re: What's the correct way to install OpenVZ via kickstart [message #51492 is a reply to message #51477] |
Thu, 26 June 2014 00:15 |
Ales
Messages: 330 Registered: May 2009
|
Senior Member |
|
|
I add OpenVZ repos to the kickstart for the purpose of compiling the .iso. The result being an .iso with a single vzkernel, no stock kernels. When the .iso is used, network isn't needed.
I think whether this is done to create a minimal install .iso or custom live .iso, or whether it's burned on DVD or written to USB, shouldn't really matter..? Or is the minimal install process that different form the live usb/dvd one..? It's late over here, I might be missing something...
Relevant repo parts from my kickstart:
repo --name=openvz-kernel-rhel6 --baseurl=http://...
repo --name=openvz-utils --baseurl=http://...
and:
repo --name=sl6-base --excludepkgs=kernel,kernel-debug,kernel-debug-devel,kernel-devel,kernel-doc,kernel-firmware,kernel-headers,perf --baseurl=http://...
repo --name=sl6-security --excludepkgs=kernel,kernel-debug,kernel-debug-devel,kernel-devel,kernel-doc,kernel-firmware,kernel-headers,perf --baseurl=http://..
|
|
|
|
Re: What's the correct way to install OpenVZ via kickstart [message #51494 is a reply to message #51477] |
Thu, 26 June 2014 15:06 |
Ales
Messages: 330 Registered: May 2009
|
Senior Member |
|
|
Yea, our usage model is a bit different. My kickstart->iso stage is the equivalent of your createrepo/mkisofs stage... So you're right, once you incorporate the vzkernel instead of the stock kernel in that stage, you should be all set.
The vzkernel rpm package provides the "kernel", it should be a drop in replacement (together with other related packages, such as vzkernel-firmware, etc.). I think your .iso -> HN install process should select the vzkernel without any further tweaks.
Btw, for anyone else reading or searching for such information - I use a custom kickstart (with OpenVZ, EPEL, etc. packages added) -> livecd-creator -> .iso -> live-cd-iso-to-disk to create a live usb, which can all be done on the command line. This SL6/OpenVZ live media was then used for demonstration purposes.
|
|
|
Re: What's the correct way to install OpenVZ via kickstart [message #52815 is a reply to message #51477] |
Tue, 25 April 2017 22:24 |
azilber
Messages: 15 Registered: May 2015 Location: Malaysia
|
Junior Member |
|
|
PeterSteele wrote on Tue, 24 June 2014 16:13I have a streamlined CentOS install that's automated through the kickstart facility. I want my custom image to use the OpenVZ kernel instead of the default CentOS kernel. I'm not sure what the correct way is to do this.
My current kickstart script does not explicitly reference which kernel files are installed. This is handled automatically by the @core entry in the %packages section:
%packages --nobase
@core
I know I can add code in %post to install the kickstart kernel as one of the final stages of the kickstart install process. Is this the best way?
I'm going to un-necro this thread.. if you install OpenVZ manually, you can look into /root/anaconda-ks.cfg.
I've tested kickstarts of OpenVZ via Koan/Cobbler. Here's my package list for OpenVZ 7:
%packages
@^cloudserver
@base
@core
@ps
@qemu
@templates
@vz
chrony
kexec-tools
%end
|
|
|