All of lore.kernel.org
 help / color / mirror / Atom feed
From: Maciek Nowacki <maciek@Voyager.powersurfr.com>
To: linux-kernel@vger.kernel.org
Subject: Busy on BLKFLSBUF w/initrd
Date: Wed, 23 May 2001 15:48:44 -0600	[thread overview]
Message-ID: <20010523154843.A32583@Voyager.powersurfr.com> (raw)

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

             reply	other threads:[~2001-05-23 21:49 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-05-23 21:48 Maciek Nowacki [this message]
2001-05-23 22:05 ` Busy on BLKFLSBUF w/initrd Alexander Viro
2001-05-23 22:11   ` Maciek Nowacki
2001-05-23 22:21     ` Alexander Viro
2001-05-23 23:23       ` Maciek Nowacki
2001-05-23 23:28         ` Alexander Viro
2001-05-23 23:45           ` Maciek Nowacki
2001-05-24  5:32   ` Mike Galbraith
2001-05-24 10:42     ` Alexander Viro
2001-05-24 10:56       ` Mike Galbraith
2001-05-24 11:24         ` Alexander Viro
2001-05-24 11:57           ` Herbert Xu
2001-05-24 13:27           ` Mike Galbraith
2001-05-24 13:33             ` Alexander Viro
2001-05-24 18:39 ` Maciek Nowacki
2001-05-25  5:20   ` Scott Murray
2001-05-25 15:42     ` Maciek Nowacki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20010523154843.A32583@Voyager.powersurfr.com \
    --to=maciek@voyager.powersurfr.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.