I have an embedded Linux (vanilla, 3.3.8, i486, Vortex86dx) system that boots from an initramfs image.
I have an IDE Flash disk with two partitions at /dev/hda1 and /dev/hda2.
It has a static /dev directory.
When I boot up, the /dev/hda1 entry is no longer present. /dev/hda1 appears to have been deleted by the kernel(?).
I do not have this same problem if I boot my target from an NFS root filing system.
I use Buildroot to create the /dev directory via the device_table_dev.txt file. e.g.
# IDE Devices
/dev/hda b 640 0 0 3 0 0 0 -
/dev/hda b 640 0 0 3 1 1 1 4
I inspected the rootfs.tar.gz from Buildroot output/images. The /dev directory contains /dev/hda1:
brw-r----- 1 root root 3, 0 Jul 2 13:44 hda
brw-r----- 1 root root 3, 1 Jul 2 13:44 hda1
brw-r----- 1 root root 3, 2 Jul 2 13:44 hda2
brw-r----- 1 root root 3, 3 Jul 2 13:44 hda3
brw-r----- 1 root root 3, 4 Jul 2 13:44 hda4
My post-boot directory listing (done from within rcS) on the target looks like this:
brw-r----- 1 root root 3, 0 Jul 2 12:44 hda
brw-r----- 1 root root 3, 2 Jul 2 12:44 hda2
brw-r----- 1 root root 3, 3 Jul 2 12:44 hda3
brw-r----- 1 root root 3, 4 Jul 2 12:44 hda4
/dev/hda1 is missing.
If I run the Busybox utility "mdev -s", it restores/dev/hda1 on the target and it works normally. e.g. I can mount it
Has anyone ever seen this behaviour before?
Does the kernel delete entries from /dev?