* fallocate overhead
@ 2009-08-13 14:07 Markus Trippelsdorf
2009-08-13 14:45 ` Chris Mason
0 siblings, 1 reply; 2+ messages in thread
From: Markus Trippelsdorf @ 2009-08-13 14:07 UTC (permalink / raw)
To: linux-btrfs; +Cc: lkml
I was playing with the new hdparm wiper script (
http://sourceforge.net/projects/hdparm/files/) on my Vertex SSD and
it appears that btrfs needs a huge space overhead when dealing with
fallocate system calls. Basically what the wiper script does is to
fallocate one huge file using all free space minus a safety margin.
And this margin has to be about 30% on btrfs, e.g.:
# df -T /
Filesystem Type 1K-blocks Used Available Use% Mounted on
/dev/root btrfs 31266648 10464096 20802552 34% /
# hdparm --fallocate 20002552 test_temp
test_temp: No space left on device
# hdparm --fallocate 16002552 test_temp
test_temp: No space left on device
# hdparm --fallocate 15002552 test_temp
#
and from dmesg:
no space left, need 20482613248, 4096 delalloc bytes, 9786335232 bytes_used, 0 bytes_reserved, 0 bytes_pinned, 0 bytes_readonly, 0 may use 25545211904 total
no space left, need 16386613248, 4096 delalloc bytes, 9786335232 bytes_used, 0 bytes_reserved, 0 bytes_pinned, 0 bytes_readonly, 0 may use 25545211904 total
My question is if 30% isn't a bit too much overhead?
--
Markus
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: fallocate overhead
2009-08-13 14:07 fallocate overhead Markus Trippelsdorf
@ 2009-08-13 14:45 ` Chris Mason
0 siblings, 0 replies; 2+ messages in thread
From: Chris Mason @ 2009-08-13 14:45 UTC (permalink / raw)
To: Markus Trippelsdorf; +Cc: linux-btrfs, lkml
On Thu, Aug 13, 2009 at 04:07:32PM +0200, Markus Trippelsdorf wrote:
> I was playing with the new hdparm wiper script (
> http://sourceforge.net/projects/hdparm/files/) on my Vertex SSD and
> it appears that btrfs needs a huge space overhead when dealing with
> fallocate system calls. Basically what the wiper script does is to
> fallocate one huge file using all free space minus a safety margin.
> And this margin has to be about 30% on btrfs, e.g.:
We're actively fixing this ;) The margin is just a hard coded limit to
try and avoid enospc oopsen. It should improve in 2.6.32.
-chris
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-08-13 14:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-13 14:07 fallocate overhead Markus Trippelsdorf
2009-08-13 14:45 ` Chris Mason
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox