Novell Home

Building the ZENworks Imaging Kernel

Novell Cool Solutions: Feature
By Martin Buckley

Digg This - Slashdot This

Posted: 13 Jun 2001
 

Current Version: ZENworks for Desktops 3

We've had a number of questions about how to build a linux kernel to let you compile the drivers. Evil ZENworks Scientist Martin Buckley stepped up and supplied these instructions. Enjoy! (And beware what you ask for...)

ZENworks for Desktop Imaging kernel

This article outlines the steps required to patch the 2.2.14 kernel source code to make it work in ZENworks Imaging environment.

  1. Install linux on a workstation. Linux distribution could either be downloaded from the web, or could be obtained in the stores. To find out more about linux visit www.linuxdoc.org and read the Installation HOWTO.
  2. Download linux 2.2.14 source code from http://www.kernel.org. The source code is present as linux-2.2.14.tar.gz at http://www.kernel.org/pub/linux/kernel/v2.2.
  3. Copy Zfd3krnlpatch.tgz to some directory on linux workstation, say /tmp.
  4. Untar the patch and change to the directory by typing the following command:

    tar zxvf zfd3krnlpatch.tgz
    cd zfd3krnlpatch

  5. Install the linux kernel source code. There is a script installkrnlsrc.s to install the code in the right place. To use it run

    ./installkrnlsrc.s <linux src code file with complete path>

    Example: ./installkrnlsrc.s linux-2.2.14.tar.gz

  6. The script installs the source code in /usr/src directory. If a /usr/src directory already exists it renames it to /usr/src.orig.

  7. To apply the ZENworks kernel patch, run the zfd3krnlpatch.s script as follows:
    ./zfd3krnlpatch.s

    This patch installs the ZENworks patch, Compaq patch to make the kernel work on Compaq machines with on-board NIC's, and the ZENworks configuration file to build the kernel. There are two configuration files:

    • The common network drivers are configured to be built into the kernel.
    • Only a few isa network drivers, precisely NE2000, SMC9194, 3c501/503/505, AMD Lance are built into the kernel. The rest of the drivers are built as modules.

  8. You could configure the kernel further, and rebuild the kernel according to your environment. Following are steps to build the kernel and modules:
    1. make xconfig -- Configures the kernel.
    2. make dep -- Resolves the dependencies.
    3. make bzImage -- Builds the kernel, the kernel is present in /usr/src/linux/arch/i386/boot/bzImage.
    4. make modules -- Builds all the modules. The modules are present in /usr/src/linux/modules.

    Note: Even if you are not changing the kernel configuration, after applying the patch, run make xconfig and save the configuration file. This is essential as it generates autoconf.h file which is required for the next step, make dep.

    Further details on how to build the kernel could be found at the linuxdoc.org site.

  9. If you want to build an updated driver, download the source code for the driver and copy it to the appropriate source code directory. The drivers source code are present in /usr/src/linux/drivers path. "make modules" would build the driver. The built driver could be found in /usr/src/linux/modules directory.

    If the driver to be built is not configured to be built as a module, then you would have to edit the configuration file (make xconfig).

    If a downloaded driver files has an associated makefile, then running make should build the driver for you. The accompanying README file would have the details on how to build the driver.

About the Author

By night Martin Buckley is the Evil ZENworks Scientist -- cooking up ZENworks solutions and hatching dastardly integrations. By day he is the ZENworks for Desktops Product Manager. Based in Provo, Utah and Nottingham, England.

You can contact Martin at martin_buckley@novell.com or at ezs@myrealbox.com


Novell Cool Solutions (corporate web communities) are produced by WebWise Solutions. www.webwiseone.com

© 2014 Novell