You are not logged in.

#1 2009-10-20 17:16:56

nilesh
Member
From: Pune, Maharashtra, India
Registered: 2009-10-07
Posts: 36
Website

What am I missing in my kernel configuration ?

Hi, I want to make a minimal kernel which will have nfsroot. It has to be used on diskless system. RAM is a severe limitation here, so I have to compile the kernel removing all unecessary things.

In configuration of the kernel (menuconfig) -> File Systems -> Network File Systems, I enabled NFS Client v3 and v4 (not 4.1) (directly compiled into the kernel). Also checked the nfs root option. But still I can't get my kernel working on VirtualBox (I am using VirtualBox with bridged adapter for testing). Arch's Kernel boots successfully.

Is it that I am missing the Network driver in the kernel ? (tried both PC-NET III and II).

Some trace I can collect from the kernel:

(Producted using scrot, gimp, gocr, and modification).

:: Loading Initramfs
:: Running Hook [udev]
:: Loading udev.  [    1.253365] path_id used greatest stack depth: 2956 bytes left
[    1.336662] udevd used greatest stack depth: 2768 bytes left
[    1.395335] udevd used greatest stack depth: 2464 bytes left
Done.
::  Initramfs Completed - control passing to Kinit
IP-Config: no devices to configure
waiting 0s before mounting root device.
connect: Network is unreachable
connect: Network is unreachable
NFS over TCP not available from 192.168.1.254
kinit:  init not found!
[    2.357505] Kernel panic - not syncing: Attempted to Kill init!
[    2.358991] Pid: 1, comm: Kinit Not tainted 2.6.31.4 #3
[    2.359346] Call Trace:
[    2.362476]  [<c1267542>] ? printk+0xf/0x11
[    2.365138]  [<c12674a6>] panic+0x39/0xc6
[    2.366154]  [<c101e9ac>] do_exit+0x54/0x546
[    2.366946]  [<c101ef31>] complete_and_exit+0x0/0x17
[    2.367461]  [<c1002805>] syscall_call+0x7/0xb
[    2.873395] atkbd.c: Spurious ACK on isa0060/serio0. Some program might be trying access hardware directly.

Offline

#2 2009-10-20 17:22:42

Dheart
Member
From: Sofia, Bulgaria
Registered: 2006-10-26
Posts: 956

Re: What am I missing in my kernel configuration ?

NFS over TCP not available from 192.168.1.254

Is probably what's causing the error, but I have no idea how to fix this, I don't know how connecting to the internet while booting kernel works. Most probably you'll need some hooks added to /etc/mkinitcpio.conf


My victim you are meant to be
No, you cannot hide nor flee
You know what I'm looking for
Pleasure your torture, I will endure...

Offline

#3 2009-10-21 04:28:35

nilesh
Member
From: Pune, Maharashtra, India
Registered: 2009-10-07
Posts: 36
Website

Re: What am I missing in my kernel configuration ?

Dheart wrote:
NFS over TCP not available from 192.168.1.254

Is probably what's causing the error, but I have no idea how to fix this, I don't know how connecting to the internet while booting kernel works. Most probably you'll need some hooks added to /etc/mkinitcpio.conf

I followed all the instructions on diskless boot on arch wiki, the thing is very funny. Arch's kernel works, but self compiled one doesn't.

I have base, net, udev hooks enabled, I generated kernel26.img with nfs module in the MODULES array.

I compiled the kernel with inbuilt nfs support, so nfs module doesn't need to be loaded separately. (now Trying to recompile kernel with nfs as a module).

Offline

#4 2009-10-21 05:34:56

nilesh
Member
From: Pune, Maharashtra, India
Registered: 2009-10-07
Posts: 36
Website

Re: What am I missing in my kernel configuration ?

hurray ! it worked ! I was missing the AMD PCNEt 32 PCI driver !

==edit==

another trouble now. udev hangs at boot.

since i am booting from nfs, no root device is required. i removed udev from mkinitcpio.conf, but udev doesn't get disabled. any way to disable udev ?

Last edited by nilesh (2009-10-21 06:43:03)

Offline

#5 2009-10-21 07:27:49

gog
Member
Registered: 2009-10-13
Posts: 103

Re: What am I missing in my kernel configuration ?

rc.sysinit wrote:

if [ -x /sbin/udevadm ]; then
  stat_busy "Starting UDev Daemon"
  /sbin/udevd --daemon
  stat_done
else

Offline

#6 2009-10-21 11:09:17

nilesh
Member
From: Pune, Maharashtra, India
Registered: 2009-10-07
Posts: 36
Website

Re: What am I missing in my kernel configuration ?

gog wrote:
rc.sysinit wrote:

if [ -x /sbin/udevadm ]; then
  stat_busy "Starting UDev Daemon"
  /sbin/udevd --daemon
  stat_done
else

okay, but now the system just stops after starting syslog-ng (disabled all other services).

the reason is proabably the absence of tty0-9 files in /dev. how do i manage them without udev ?

Offline

#7 2009-10-21 11:28:30

gog
Member
Registered: 2009-10-13
Posts: 103

Re: What am I missing in my kernel configuration ?

you werent supposed to comment that, yet

make nodes with mknod (man mknod), after you do, add them to that file

google "static boot linux" and search the forums for fast boot. also look at quick-init in the aur. its not a fully static boot but it shows you how a sysinit full of mknod is supposed to look like. do not install quick-init, its not going to work without udev, just look at it

also, boot with a live cd (arch's install img will do just fine) to get an idea of how that system's dev is supposed to look like

and why are you using mkinitcpio for embedded/thin client? recompile a kernel that can boot by itself, mkinitcpio isnt much use without udev

e: make the system leaner: "recompile" initscripts, remove udev as dep. comment the section about crypt (this should be handled by a var like lvm2 by default, instead of it looking at crypttab, anyway...). uninstall udev. if you decide to install x just keep in mind that hal wont work, either recompile it without hal or get the oldschool x from the aur (not recomended, kinda crappy)

Last edited by gog (2009-10-21 11:50:09)

Offline

#8 2009-10-21 17:00:01

nilesh
Member
From: Pune, Maharashtra, India
Registered: 2009-10-07
Posts: 36
Website

Re: What am I missing in my kernel configuration ?

gog wrote:

you werent supposed to comment that, yet

make nodes with mknod (man mknod), after you do, add them to that file

google "static boot linux" and search the forums for fast boot. also look at quick-init in the aur. its not a fully static boot but it shows you how a sysinit full of mknod is supposed to look like. do not install quick-init, its not going to work without udev, just look at it

also, boot with a live cd (arch's install img will do just fine) to get an idea of how that system's dev is supposed to look like

and why are you using mkinitcpio for embedded/thin client? recompile a kernel that can boot by itself, mkinitcpio isnt much use without udev

e: make the system leaner: "recompile" initscripts, remove udev as dep. comment the section about crypt (this should be handled by a var like lvm2 by default, instead of it looking at crypttab, anyway...). uninstall udev. if you decide to install x just keep in mind that hal wont work, either recompile it without hal or get the oldschool x from the aur (not recomended, kinda crappy)

i recompiled the kernel to boot by itself, also took a look at quick init, and implemented some part of it, disabled udev.

the cause I am doing this is I have one very old Pentium Laptop with 24 megs of ram n I want a GUI on it (I tested the GUI with 24m ram on Vbox - it works!).

Now how do I get the mouse working on Xorg ?

Offline

#9 2009-10-21 20:51:56

gog
Member
Registered: 2009-10-13
Posts: 103

Re: What am I missing in my kernel configuration ?

look at the xorg wiki

static xorg, no hal, no evdev, you have to set the driver manually...

unless you already did that.. i had a few problems some weeks ago compiling a custom kernel like this one, i couldnt get the mouse working, not even with gpm in a vc. test if gpm works first to isolate the problem... if it doesnt, that means you left something crucial out, like a weird serial driver or something.

e: if youre using vm as a base to make the nodes: its not going to work, the tty nodes will, some of them wont... like the hdd nodes

Last edited by gog (2009-10-21 22:39:05)

Offline

#10 2009-10-22 08:08:51

nilesh
Member
From: Pune, Maharashtra, India
Registered: 2009-10-07
Posts: 36
Website

Re: What am I missing in my kernel configuration ?

gog wrote:

look at the xorg wiki

static xorg, no hal, no evdev, you have to set the driver manually...

unless you already did that.. i had a few problems some weeks ago compiling a custom kernel like this one, i couldnt get the mouse working, not even with gpm in a vc. test if gpm works first to isolate the problem... if it doesnt, that means you left something crucial out, like a weird serial driver or something.

e: if youre using vm as a base to make the nodes: its not going to work, the tty nodes will, some of them wont... like the hdd nodes

Yeah gpm works in non-daemon mode. I am able to use gpm in debug mode. Any clue why gpm doesn't become a daemon ?

Offline

Board footer

Powered by FluxBB