Messages in this thread |  | | | From | Maciek Nowacki <> | | Date | Wed, 23 May 2001 15:48:44 -0600 | | Subject | Busy on BLKFLSBUF w/initrd |
| |
Hi,
I have continuing problems with getting the initrd ramdisk out of memory once bootup is complete.
This is with recent -ac kernels which have the fix-up posted a few months ago applied.
The sequence is roughly:
- boot via pxelinux, loads up bzImage <1MB and root.romfs.gz ~7MB, expands to about 30. - mount -n -t tmpfs none tmp - cp root -> /tmp - pivot_root -> /tmp - umount old_root/dev (devfs kernel) - umount old_root
Then another pivot_root a bit later on before /sbin/init is invoked. The point is to move the initrd to a tmpfs which will reclaim memory in the event that the filesystem cannot be unmounted, due to having mountpoints for loopback host filesystems in this case.
It seems to work fine, and the initrd _does_ unmount with no problems (unmounting old_root/dev does complain about mtab, but works, ls old_root/dev shows empty). However, blockdev --flushbufs /dev/rd/0 fails with busy on BLKFLSBUF once the system is running.
About the only odd thing besides the message about mtab from umount is the kernel notice right before entering /bin/sh on the romfs initrd - it prints out two messages about mounting the ramdisk:
May 22 09:14:30 wintermute kernel: Linux version 2.4.4-ac12 (maciek@wintermute) (gcc version 2.95.4 20010506 (Debian prerelease)) #1 Mon May 21 20:08:36 MDT 2001 [...] May 22 09:14:31 wintermute kernel: RAMDISK: romfs filesystem found at block 0 May 22 09:14:31 wintermute kernel: RAMDISK: Loading 28216 blocks [1 disk] into ram disk... done. May 22 09:14:31 wintermute kernel: Freeing initrd memory: 28216k freed May 22 09:14:31 wintermute kernel: VFS: Mounted root (romfs filesystem) readonly. May 22 09:14:31 wintermute kernel: Mounted devfs on /dev May 22 09:14:31 wintermute kernel: VFS: Mounted root (romfs filesystem) readonly. May 22 09:14:31 wintermute kernel: change_root: old root has d_count=7 May 22 09:14:31 wintermute kernel: Mounted devfs on /dev May 22 09:14:31 wintermute kernel: Trying to unmount old root ... okay
Perhaps they're bumping up the reference count so that it is impossible to free the ramdisk later?
Thanks very much for any help!
Maciek - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
|  |