On 03/11/2014 06:10 PM, quwen...@cn.fujitsu.com wrote:
On Tue, 11 Mar 2014 09:37:00 -0700, Zach Brown wrote:
There seems to be an issue if we try to build a btrfs based FS that
is less than 70M, we get the following assertion failure:

mkfs.btrfs: extent-tree.c:2682: btrfs_reserve_extent: Assertion
`!(ret)' failed.
mkfs.btrfs -b 104857600 -r rootfs rootfs.btrfs
Honestly, the path of least resistance is probably to avoid the -r
option all together.  As you've found, it's not reliable.

I'd take the time to roll the infrastrcture to populate the image by
writing to a mounted image with the kernel code.

- z
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

I although agree with the mount + cp(kernel) way to populate the filesystem.
Also I think the implement of "-r" should be somewhat like mount+cp
other than the current way,
since the userland implement is noticeably slow than kernel way.

Cc:Donggeun Kim
I also wonder why "-r" option is needed, since IMO the "-r" options is
only needed
if the filesystem is full readonly and must be populated on
initialization like squashfs.
And since btrfs is a filesystem that can be read and write,
the "-r" option is not somewhat needed.

So I prefer to remove the "-r" option.

Please dont remove the -r option, as you point out above it's used from userland. The Yocto Project / OE-Core uses this option to build a put a rootfs into a filesystem image in userland without requiring root permissions, we use something call pseudo (it a smarter version of fakeroot) to lay down a root filesytem.

The patch from Gui worked well for our purposes, we are no longer failing to build the filesystem image.

Thanks

Sau!


Thanks
Qu

--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to