Stupid kernel build question

Steffen Grunewald steffen.grunewald at aei.mpg.de
Wed Aug 18 15:32:08 CEST 2004


Hi, some updates:

Since I found that - starting at 2.4.22 - the standard kernel comes with
Debian cramfs initrd support, there's no need to use romfs anymore.
So I reverted some of my modifications, and the log reads as follows:

On Wed, Aug 18, 2004 at 10:46:50AM +0000, Steffen Grunewald wrote:
> Hi,
> 
> I'd like to customize my own kernel for the FAI-installed nodes.
> So basically I got the kernel sources, the necessary patches, and a
> .config file of a previous version to get a head start.
> Unfortunately I get stuck when rebooting. Here's the snippet from my
> work log: (I will publish the full one as soon as I got through)
> 
> ...
> OK; so I now also want to use my own kernel, since i2c and lm-sensors
> that come with Debian kernels are quite outdated. 
> I didn't succeed to compile the 2.4.26 kernel with the patches, so I 
> decided to use a pristine 2.4.27 instead and make my own kernel:
> 	cd /usr/src
> 	# get kernel
> 	wget -r -l1 -nd www.kernel.org/pub/linux/kernel/v2.4/linux-2.4.27.tar.bz2
> 	# unpack kernel
> 	tar jxf linux-2.4.27.tar.bz2
> 	# rename to debian standard
> 	mv linux-2.4.27 kernel-source-2.4.27
> 	# get patches (for 2.4.26, doesn't matter)
> 	apt-get install kernel-patch-2.4-i2c kernel-patch-2.4-lm-sensors
> 	# unpack for patch
> 	gunzip kernel-patches/diffs/*/kernel-2.4.26-*.patch.gz	
> 	# get config file for subarchitecture (mine is k7-smp, Athlon MP)
> 	apt-get source kernel-image-2.4-k7-smp
> 	cp -p kernel-image-2.4.26-i386-*/config/k7-smp kernel-source-2.4.27
> 	# patch kernel
> 	cd kernel-source-2.4.27
> 	patch -p1 <../kernel-patches/diffs/i2c/kernel-2.4.26-*
> 	patch -p1 <../kernel-patches/diffs/lm-sensors/kernel-2.4.26-*
> 	# fill in new config file entries (answer "M" where possible, "Y" else)
> 	make oldconfig
> 	# set own identity
> 	vi /etc/kernel-pkg.conf
> 	make-kpkg \
> 		--revision 20040818 \
> 		--subarch k7-smp \
> 		--initrd --bzimage \
> 		binary modules
> 	cd ..
> 	mv kernel-*.deb $FAI_CONFIGDIR/files/packages
> 	cd $FAI_CONFIGDIR/files
> 	./mkPkg				# create packages/Packages.gz
> 	cd ../scripts/DEFAULT
>
> If you now restart your installation, you might even succeed when rebooting...
> For me, it does not, I get 
> 	VFS: Mounted root (cramfs filesystem) readonly.
> 	...
> 	.../ide-core.o: insmod ide-detect failed
> 	.../ide-core.o: insmod ide-disk failed
> 	Journalled Block Device driver loaded
> 	pivot_root: No such file or directory
> 	/sbin/init: ... cannot open dev/console: No such file
> 	Kernel panic: Attempted to kill init!
> 
> (If I use the prebuilt kernel from Debian Sarge, everything is fine.)
 
Any suggestions how to get the thing working is still welcome.

Steffen
-- 
Steffen Grunewald * * * Merlin cluster admin (http://pandora.aei.mpg.de)
Albert-Einstein-Institut (MPI Gravitationsphysik, http://www.aei.mpg.de)
       Science Park Golm, Am Mühlenberg 1, 14476 Potsdam, Germany
e-mail: steffen.grunewald(*)aei.mpg.de * +49-331-567-{fon:7233,fax:7298}



More information about the linux-fai mailing list