Changes

Jump to: navigation, search

Kernel build

1,500 bytes added, 10:53, 1 June 2006
no edit summary
== Rebuilding kernel from sources ==
FIXME=== Download ===To compile OpenVZ linux kernel one need to download the original linux kernel sources and OpenVZ patches for it. Linux kernel can be found at http://www.kernel.org/, e.g. 2.6.16 kernel can be downloaded from http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.16.tar.bz2 . Appropriate OpenVZ patches for this kernel version can be found at http://openvz.org/download/, e.g. at the moment there is a patch [http://download.openvz.org/beta/kernel/026test012.1/patches/patch-026test012-combined.gz patch-026test012-combined.gz] available.Kernel configs are also avaialble at OpenVZ download site. Most usually SMP config is used, so lets download [http://download.openvz.org/beta/kernel/026test012.1/configs/kernel-2.6.16-026test012-i686-smp.config.ovz kernel-2.6.16-026test012-i686-smp.config.ovz]for this example. === Building ===First, extract the kernel sources from archive:<pre># tar vjxf linux-2.6.16.tar.bz2# cd linux-2.6.16</pre> Apply OpenVZ patches to the kernel:<pre># gzip -d patch-026test012-combined.gz# patch -p1 < patch-026test012-combined</pre> Now we need to place the config and build the kernel:<pre># cp kernel-2.6.16-026test012-i686-smp.config.ovz .config# make oldconfig# make</pre> === Installation ===After successfull build of kernel it can be installed on the machine with the following commands run under '''root''' user:<pre># make install</pre> Also you need to edit your GRUB or LILO config to make your kernel available for boot.
[[Category:HOWTO]]
Anonymous user

Navigation menu