#1  
Old 2nd November 2006, 17:58
todgerme todgerme is offline
Member
 
Join Date: Dec 2005
Location: Belfast, Northern Ireland
Posts: 54
Thanks: 0
Thanked 1 Time in 1 Post
Default Kernel Blues

I hate trying to get Kernel modules working.

Anyway I am trying to follow the NFS DRBD guide and I can't get past the following when I try to make the DRBD module:

/usr/src/modules/drbd/drbd# make
grep: /lib/modules/2.6.8-2-686-smp/build/Makefile: No such file or directory
grep: /lib/modules/2.6.8-2-686-smp/build/Makefile: No such file or directory

Calling toplevel makefile of kernel source tree, which I believe is in
KDIR=/lib/modules/2.6.8-2-686-smp/build

trying to make dep ...
make[1]: Makefile: No such file or directory
make[1]: *** No rule to make target `Makefile'. Stop.
I'll ignore this error, but this can cause inconsistencies!
test -f ../scripts/adjust_drbd_config_h.sh && \
KDIR=/lib/modules/2.6.8-2-686-smp/build /bin/sh ../scripts/adjust_drbd_config_h.sh
ls: /lib/modules/2.6.8-2-686-smp/build/include/asm/bitops.h: No such file or directory
Sorry, automagic adjustment of drdb_config.h failed.
For well known 2.6. kernels, no adjustment to the shipped drbd_config is necessary.
You need to verify it yourself.
make: [kbuild] Error 1 (ignored)
make -C /lib/modules/2.6.8-2-686-smp/build SUBDIRS=/usr/src/modules/drbd/drbd modules
make[1]: Entering directory `/usr/src/kernel-headers-2.6.8-2-686-smp'
make[1]: Makefile: No such file or directory
make[1]: *** No rule to make target `Makefile'. Stop.
make[1]: Leaving directory `/usr/src/kernel-headers-2.6.8-2-686-smp'
make: *** [kbuild] Error 2
==========


Looking at /lib/modules/2.6.8-2-686-smp/build where it complains about Makefile not existing everything is symlinked up a directory and then downwards again but this directory doesn't exist so I am very confused!

lrwxrwxrwx 1 root root 34 2006-11-02 15:27 Makefile -> ../kernel-headers-2.6.8-2/Makefile
lrwxrwxrwx 1 root root 29 2006-11-02 15:27 lib -> ../kernel-headers-2.6.8-2/lib
lrwxrwxrwx 1 root root 32 2006-11-02 15:27 kernel -> ../kernel-headers-2.6.8-2/kernel
lrwxrwxrwx 1 root root 29 2006-11-02 15:27 ipc -> ../kernel-headers-2.6.8-2/ipc
lrwxrwxrwx 1 root root 30 2006-11-02 15:27 init -> ../kernel-headers-2.6.8-2/init
drwxr-xr-x 4 root root 4096 2006-11-02 15:27 include
lrwxrwxrwx 1 root root 28 2006-11-02 15:27 fs -> ../kernel-headers-2.6.8-2/fs
lrwxrwxrwx 1 root root 33 2006-11-02 15:27 drivers -> ../kernel-headers-2.6.8-2/drivers
lrwxrwxrwx 1 root root 32 2006-11-02 15:27 crypto -> ../kernel-headers-2.6.8-2/crypto
lrwxrwxrwx 1 root root 30 2006-11-02 15:27 arch -> ../kernel-headers-2.6.8-2/arch
lrwxrwxrwx 1 root root 29 2006-11-02 15:27 usr -> ../kernel-headers-2.6.8-2/usr
lrwxrwxrwx 1 root root 31 2006-11-02 15:27 sound -> ../kernel-headers-2.6.8-2/sound
lrwxrwxrwx 1 root root 34 2006-11-02 15:27 security -> ../kernel-headers-2.6.8-2/security
lrwxrwxrwx 1 root root 33 2006-11-02 15:27 scripts -> ../kernel-headers-2.6.8-2/scripts
lrwxrwxrwx 1 root root 29 2006-11-02 15:27 net -> ../kernel-headers-2.6.8-2/net
lrwxrwxrwx 1 root root 28 2006-11-02 15:27 mm -> ../kernel-headers-2.6.8-2/mm



Anyone ideas? Debian Sarge.

If no-one has ideas can someone post me a smp 686 enable kernel + headers with all the drdb stuff already enabled?
Reply With Quote
Sponsored Links
  #2  
Old 3rd November 2006, 15:39
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

Quote:
Originally Posted by todgerme
I hate trying to get Kernel modules working.

Anyway I am trying to follow the NFS DRBD guide and I can't get past the following when I try to make the DRBD module:

/usr/src/modules/drbd/drbd# make
grep: /lib/modules/2.6.8-2-686-smp/build/Makefile: No such file or directory
grep: /lib/modules/2.6.8-2-686-smp/build/Makefile: No such file or directory
Do you have the kernel-headers for kernel 2.6.8-2 installed?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 3rd November 2006, 17:52
todgerme todgerme is offline
Member
 
Join Date: Dec 2005
Location: Belfast, Northern Ireland
Posts: 54
Thanks: 0
Thanked 1 Time in 1 Post
Default

I did, but I have since given up on Debian and went for Ubuntu 6.06 server instead. It only compiles under gcc 4 under Ubuntu but it did compile. Haven't completely followed the guide so I could be back for more tech support shortly
Reply With Quote
  #4  
Old 4th November 2006, 01:00
todgerme todgerme is offline
Member
 
Join Date: Dec 2005
Location: Belfast, Northern Ireland
Posts: 54
Thanks: 0
Thanked 1 Time in 1 Post
Default

Back to Debian for another system, an Opteron system using an AMD64-K8 kernal, compiling the DRBD module I get the following error:


Calling toplevel makefile of kernel source tree, which I believe is in
KDIR=/lib/modules/2.6.8-12-amd64-k8-smp/build

test -f ../scripts/adjust_drbd_config_h.sh && \
KDIR=/lib/modules/2.6.8-12-amd64-k8-smp/build /bin/sh ../scripts/adjust_drbd_config_h.sh

Using unmodified drbd_config.h

make -C /lib/modules/2.6.8-12-amd64-k8-smp/build SUBDIRS=/usr/src/modules/drbd/drbd modules
make[1]: Entering directory `/usr/src/kernel-headers-2.6.8-12-amd64-k8-smp'
CC [M] /usr/src/modules/drbd/drbd/drbd_sizeof_sanity_check.o
cc1: error: code model `kernel' not supported in the 32 bit mode
make[2]: *** [/usr/src/modules/drbd/drbd/drbd_sizeof_sanity_check.o] Error 1
make[1]: *** [_module_/usr/src/modules/drbd/drbd] Error 2
make[1]: Leaving directory `/usr/src/kernel-headers-2.6.8-12-amd64-k8-smp'
make: *** [kbuild] Error 2


Can anyone offer any advice on how to get around this? The module compiles when using a 686-smp kernel, but the system tends to randomly lockup unless you use the proper K8 kernel so I really need to get this working!?
Reply With Quote
  #5  
Old 4th November 2006, 16:47
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,741 Times in 2,575 Posts
Default

Quote:
Originally Posted by todgerme
cc1: error: code model `kernel' not supported in the 32 bit mode
Are you trying to compile a 64bit kernel on a 32bit system?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #6  
Old 5th November 2006, 21:08
todgerme todgerme is offline
Member
 
Join Date: Dec 2005
Location: Belfast, Northern Ireland
Posts: 54
Thanks: 0
Thanked 1 Time in 1 Post
 
Default

It is am AMD64 using a x86 Debian with an AMD-K8 kernel if that makes any sense. I guess most of the OS would be 32bit but didn't want to go for any of the unofficial AMD64 versions of Debian. I am going to try the AMD64 version of Ubuntu to see what happens.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
High Availability Samba cluster - DRBD + Heartbeat djalex Server Operation 58 25th May 2007 19:38
Memory leak? oom-killer problem yikes! Stokesy Server Operation 7 29th July 2006 12:48
xen not booting qiu HOWTO-Related Questions 11 2nd May 2006 10:20
sargeDebian GNU/Linux, kernel 2.6.8-3-686 and Debian kernel 2.6.8 386- qiu Kernel Questions 23 25th April 2006 15:53
Questions about ubuntu ISP-Server Setup badgerbox76 HOWTO-Related Questions 15 5th March 2006 14:41


All times are GMT +2. The time now is 16:30.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.