From: Robert Yang <liezhi.yang@windriver.com>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: <linux-ext4@vger.kernel.org>, "Theodore Ts'o" <tytso@mit.edu>,
Darren Hart <dvhart@linux.intel.com>
Subject: e2fsprogs/debugfs/write: Input/output error when file size is zero
Date: Wed, 24 Jul 2013 16:59:10 +0800 [thread overview]
Message-ID: <51EF975E.2090700@windriver.com> (raw)
Hello experts,
I met a "Input/output error" problem when used debugfs' command "write"
to copy a zero size file to ext4 fs, here are the steps to reproduce the
problem:
$ dd if=/dev/zero of=test.img count=1M bs=1k
$ mkfs.ext4 -F test.img
$ touch emptyfile
$ debugfs -R "write emptyfile emptyfile" -w test.img
$ mkdir mnt
$ mount test.img mnt/
$ ls mnt/emptyfile
ls: cannot access mnt/emptyfile: Input/output error
The degbufs is from the up-to-date git repo, the ext2 and ext3 work well,
I think that it is caused by the EXT4_EXTENTS_FL, it works well if we
turn off the EXT4_EXTENTS_FL when the file size is zero, but this is not
a correct fix, would you please give me some instructions so that I can
fix it?
--
Thanks
Robert
next reply other threads:[~2013-07-24 8:59 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-24 8:59 Robert Yang [this message]
2013-07-24 15:00 ` e2fsprogs/debugfs/write: Input/output error when file size is zero Eric Sandeen
2013-07-24 15:11 ` [PATCH] debugfs: properly set up extent header in do_write Eric Sandeen
2013-07-25 6:18 ` Robert Yang
2013-07-29 2:33 ` Theodore Ts'o
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=51EF975E.2090700@windriver.com \
--to=liezhi.yang@windriver.com \
--cc=darrick.wong@oracle.com \
--cc=dvhart@linux.intel.com \
--cc=linux-ext4@vger.kernel.org \
--cc=tytso@mit.edu \
/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.