drbd module compiling error for Kernel


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users drbd module compiling error for Kernel
# 1  
Old 04-20-2012
drbd module compiling error for Kernel

Hi I am trying to install drbd8 via apt-get on ubuntu10

Code:
sudo apt-get install drbd8-source
[sudo] password for vishals:
Reading package lists... Done
Building dependency tree
Reading state information... Done
drbd8-source is already the newest version.
drbd8-source set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 13 not upgraded.
1 not fully installed or removed.
After this operation, 0B of additional disk space will be used.
Setting up drbd8-source (2:8.3.7-1ubuntu2.2) ...

Done.
Loading new drbd8-8.3.7 DKMS files...
First Installation: checking all kernels...
Building only for 2.6.32-343-ec2
Building for architecture x86_64
Building initial module for 2.6.32-343-ec2

Error! Bad return status for module build on kernel: 2.6.32-343-ec2 (x86_64)
Consult the make.log in the build directory
/var/lib/dkms/drbd8/8.3.7/build/ for more information.
dpkg: error processing drbd8-source (--configure):
 subprocess installed post-installation script returned error exit status 10
Errors were encountered while processing:
 drbd8-source
E: Sub-process /usr/bin/dpkg returned an error code (1)

when i look at the make.log it says.

Code:
DKMS make.log for drbd8-8.3.7 for kernel 2.6.32-343-ec2 (x86_64)
Fri Apr 20 06:41:59 UTC 2012
make: Entering directory `/var/lib/dkms/drbd8/8.3.7/build/drbd'

    Calling toplevel makefile of kernel source tree, which I believe is in
    KDIR=/lib/modules/2.6.32-343-ec2/build

test -f ../scripts/adjust_drbd_config_h.sh && \
         KDIR=/lib/modules/2.6.32-343-ec2/build O= /bin/bash ../scripts/adjust_drbd_config_h.sh
make: [kbuild] Error 1 (ignored)
make -C /lib/modules/2.6.32-343-ec2/build   SUBDIRS=/var/lib/dkms/drbd8/8.3.7/build/drbd  modules
make[1]: Entering directory `/usr/src/linux-headers-2.6.32-343-ec2'
  Updating /var/lib/dkms/drbd8/8.3.7/build/drbd/Makefile.xen
  CC [M]  /var/lib/dkms/drbd8/8.3.7/build/drbd/drbd_buildtag.o
In file included from /usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/asm/unistd.h:5,
                 from include/linux/unistd.h:7,
                 from /usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/asm/seccomp_64.h:4,
                 from /usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/asm/seccomp.h:4,
                 from include/linux/seccomp.h:8,
                 from include/linux/sched.h:80,
                 from /usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/mach-xen/asm/pgtable_64.h:16,
                 from /usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/mach-xen/asm/pgtable.h:304,
                 from include/linux/mm.h:39,
                 from include/linux/scatterlist.h:6,
                 from include/linux/dma-mapping.h:7,
                 from include/linux/dmaengine.h:26,
                 from include/linux/skbuff.h:30,
                 from include/linux/if_ether.h:124,
                 from include/linux/netdevice.h:29,
                 from include/net/sock.h:50,
                 from include/linux/connector.h:80,
                 from /var/lib/dkms/drbd8/8.3.7/build/drbd/linux/drbd.h:29,
                 from /var/lib/dkms/drbd8/8.3.7/build/drbd/drbd_buildtag.c:2:
/usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/asm/unistd_64.h:693:29: error: asm/asm-offsets.h: No such file or directory
make[2]: *** [/var/lib/dkms/drbd8/8.3.7/build/drbd/drbd_buildtag.o] Error 1
make[1]: *** [_module_/var/lib/dkms/drbd8/8.3.7/build/drbd] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-2.6.32-343-ec2'
make: *** [kbuild] Error 2
make: Leaving directory `/var/lib/dkms/drbd8/8.3.7/build/drbd'

This mean that something is missing during source compilation against kernel.

Any help appreciated.

Thanks,
Vishal

---------- Post updated at 12:39 PM ---------- Previous update was at 12:15 PM ----------

Never mind, i was able to figure out the actual problem and solution.

Here is the solution for everyone.

main error is

Code:
/usr/src/linux-headers-2.6.32-343-ec2/arch/x86/include/asm/unistd_64.h:693:29: error: asm/asm-offsets.h: No such file or directory

where unistd_64.h was trying to find asm-offsets.h. since its 64 bit that is why this should point to 64 bit files.
When i look at the directory structure asm directory was a sym link to 64 bit directory like
Code:
lrwxrwxrwx   1 root root    10 2012-04-13 05:54 asm -> asm-x86_64

But this was broken because the correct directory name was "asm-x86" instead of "asm-x86_64". I make a new sym link

Code:
lrwxrwxrwx   1 root root     7 2012-04-20 06:54 asm -> asm-x86

and now it worked.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Issue Enabling DAQ's NFQ Module while Compiling

Hello All, OS: OpenSuSE 12.3 x86_64 A little while back I installed Snort 2.9.6 and was trying to use the NFQ module along with it for packet acquisition but got errors that the module is not present. If I run: # snort --daq-list Available DAQ modules: pcap(v3): readback live multi... (0 Replies)
Discussion started by: mrm5102
0 Replies

2. Linux

Unload kernel module at boot time (Debian Wheezy 7.2, 3.2.0-4-686-pae kernel)

Hi everyone, I am trying to prevent the ehci_hcd kernel module to load at boot time. Here's what I've tried so far: 1) Add the following line to /etc/modprobe.d/blacklist.conf (as suggested here): 2) Blacklisted the module by adding the following string to 3) Tried to blacklist the module... (0 Replies)
Discussion started by: gacanepa
0 Replies

3. UNIX for Dummies Questions & Answers

Error while compiling the kernel 3.3.1.

Hi I m using redhat 6 with kernel release 2.6.32-71.el6.i686 I have downloaded latest kernel 3.3.1 from kernel.org . when i run make module_install i get below error. # make modules_install /usr/src/kernels/linux-3.3.1/scripts/depmod.sh: line 37: 11314 Killed ... (0 Replies)
Discussion started by: pinga123
0 Replies

4. Linux

kernel compiling

Hello, I have several questions to get awnsered about the newer linux kernels (2.6.25) and above. 1st question: Ive read that the newer kernels you can compile the marvell sd8686 driver from the source. can anyone confrim this? only binaries i see for that driver are for 2.6.24 and im already... (0 Replies)
Discussion started by: old noob
0 Replies

5. UNIX for Dummies Questions & Answers

Compiling Mach 3.0 Kernel

Hi, I am very new to this. I would like to compile the Mach 3.0 kernel. Can someone explain, step-by-step, how to turn all the Mach 3.0 kernel code into a single binary file that will run directly on an x86 computer? Also, once (and if) I get it working, what software works on it? My goal is... (2 Replies)
Discussion started by: dublinus
2 Replies

6. Linux

How to convert Linux Kernel built-in module into a loadable module

Hi all, I am working on USB data monitoring on Fedora Core 9. Kernel 2.6.25 has a built-in module (the one that isn't loadable, but compiles and links statically with the kernel during compilation) to snoop USB data. It is in <kernel_source_code>/drivers/usb/mon/. I need to know if I can... (0 Replies)
Discussion started by: anitemp
0 Replies

7. Red Hat

Compiling 2.6 Kernel. :confused:

Dear Linux Masters, I need ur help in the following: 1. Compiling 2.6 kernel. 2. my Redhat system is 2.4 kernel how to add 2.6 kernel. 3. I need minimum feature in 2.6 ( most probably related to networking) Please let me know if any sites to download 2.6 kernel. Can u all please help me... (2 Replies)
Discussion started by: ashokmeti
2 Replies

8. HP-UX

errors while compiling c++ module

hello everyone, here i attempting to compile a c++ module . I am using the following command make -d dummyCHARGP. i am using the gcc compiler .my os is HP-UX 11.11. here i am getting the following errors. errors: ======= /swtemp/usbs/cc/unix-ce/root/subsys/include/main.h:146:... (1 Reply)
Discussion started by: mannam srinivas
1 Replies

9. SuSE

max number of slabs per kernel module (kernel 2.6.17, suse)

Hi All, Is there a max number of slabs that can be used per kernel module? I'm having a tough time finding out that kind of information, but the array 'node_zonelists' (mmzone.h) has a size of 5. I just want to avoid buffer overruns and other bad stuff. Cheers, Brendan (4 Replies)
Discussion started by: Brendan Kennedy
4 Replies

10. UNIX for Dummies Questions & Answers

get error while compiling apache with php module

hi, i'm compiling apache with php module after i finish compile mysql-4.0.0-alpha. i do it as the follow steps after untar'ed them in the same directory, 1) cd apache_1.3.22 ./configure 2) cd php-4.0.6 ./configure --with-mysql=/usr/local/mysql \ --with-apache=../apache_1.3.22 \... (2 Replies)
Discussion started by: jApHEth
2 Replies
Login or Register to Ask a Question