From: Andreas Heinlein <aheinlein@gmx.com>
To: linux-kernel@vger.kernel.org
Subject: Problem (possible bug) with the loopback block device
Date: Fri, 04 Feb 2011 16:31:07 +0100 [thread overview]
Message-ID: <4D4C1BBB.409@gmx.com> (raw)
Hello,
I have observed the following behaviour and hope you can help me find
the source of it:
1. Create a (sparse) file of < 100MB on a removable drive, e.g. USB
drive (dd if=/dev/zero of=/media/Testdrive/testfile bs=1 count=1
seek=100000000)
2. Set up a loopback device with it (losetup -f /media/Testdrive/testfile)
3. Create a filesystem (mkfs.ext3 /dev/loopX) and mount it (mount
/dev/loopX /mnt)
5. Write some files there
6. Unplug the drive without unmounting anything
7. Attempt to write some more data to the loopback-mounted filesystem
Expected result: Write attempt gives an error
Actual result: Write succeeds, even 'sync' returns without error.
Written files can be read, as well as data written in step 5. Works as
long as data fits into the page cache (therefore the small file size).
Seen first on Ubuntu 10.04 with Linux 2.6.32, tested and verified also
with Fedora 14 (Linux 2.6.35), GRML 2010.04 (Linux 2.6.35). Ubuntu 11.04
alpha with Linux 2.6.37 immediately gave a kernel panic in step #7,
which is not much better. Same with Ubuntu 10.04 with Linux 2.6.37. Only
acceptable behaviour I saw was with OpenSuSE 11.3 (Linux 2.6.34) which
returned I/O error immediately and remounted the loopback'ed filesystem
read-only.
Thanks in advance,
Andreas
reply other threads:[~2011-02-04 15:31 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=4D4C1BBB.409@gmx.com \
--to=aheinlein@gmx.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox