Driver Compilation

The /lib/modules/`uname -r`/build symbolic link in SuSE systems does not point to kernel sources that can be used for building external modules. That means a couple of extra steps are needed for installing an aoe driver from the sources distributed here.

The following instructions are based on those found in the /usr/share/doc/packages/kernel-source/README.SUSE file from the kernel-source package.

  1. Install gcc if you don't have it already.

  2. Install kernel-source.$ARCH.rpm for your architecture.

  3. Configure the kernel with make cloneconfig or make oldconfig.

    Unless the configuration in the kernel sources already matches your running kernel, you can overwrite the existing .config configuration file with the one SuSE has in /boot: /boot/config-`uname -r`. Back .config up first if you have made modifications.

  4. Prepare the kernel sources for building external modules with the make modules_prepare command.

    If that command fails (as it will for older versions of SuSE), the easiest thing to do is build the kernel itself with the command, make. It will take a while to finish.

  5. Go to the aoe driver source directory and specify the directory where the kernel sources are as follows. (You would use the current aoe driver in place of 18.)

      ecashin@stuart ~$ wget -q www.coraid.com/support/linux/aoe6-18.tar.gz
      ecashin@stuart ~$ tar xfz aoe6-18.tar.gz 
      ecashin@stuart ~$ cd aoe6-18/
      ecashin@stuart aoe6-18$ make KDIR=/usr/src/linux
    ...
      ecashin@stuart aoe6-18$ su -
      root@stuart ~# cd ~ecashin/aoe6-18/
      root@stuart aoe6-18# make KDIR=/usr/src/linux install
    

www.coraid.com