mewais
mewais

Reputation: 1347

Linux kernel can't mount /dev file system

I'm building a custom linux image, using a non-manipulated Linux kernel 2.6.32.65.

the kernel boots just fine until it reaches this:

EXT2-fs warning: mounting unchecked fs, running e2fsck is recommended
VFS: Mounted root (ext2 filesystem) on device 3:1.
Freeing unused kernel memory: 304k freed
init: Unable to mount /dev filesystem: No such device
init: ureadahead main process (983) terminated with status 5
init: console-setup main process (1052) terminated with status 1

I tried the solutions mentioned here although the error is not exactly the same, but no luck. I tried multiple "reference" .config files. I have been googling for a bit but I can't find anything with the same problem.

I'm running this custom image on gem5 simulator, with file system from ubuntu-core and a clean kernel. earlier in the output the kernel shows this:

hda: max request size: 128KiB
hda: 16514064 sectors (8455 MB), CHS=16383/16/63
 hda: hda1

So the kernel is able to see partitions just fine. I don't think this is caused by something in the file system. maybe initrd? or the kernel itself? how can I fix it?

Upvotes: 1

Views: 1445

Answers (2)

Dmitry Ponyatov
Dmitry Ponyatov

Reputation: 346

I have the same problem with custom built embedded Linux. Check you have enabled devfs in kernel .config

# core filesystems
CONFIG_PROC_FS=y
CONFIG_SYSFS=y
## devfs
CONFIG_DEVTMPFS=y
CONFIG_DEVTMPFS_MOUNT=y

Upvotes: 1

Alex Hoppus
Alex Hoppus

Reputation: 3935

1.) The problem is not in devfs, it seems issue is console setup. 2.) This is init issue not a linux kernel issue. 3.) Try to pass /bin/sh instead of init to kernel cmd line

Upvotes: 3

Related Questions