coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 6/6] tests: avoid spurious parallel failure due to temporary


From: Jim Meyering
Subject: Re: [PATCH 6/6] tests: avoid spurious parallel failure due to temporary disk full
Date: Mon, 04 Apr 2011 11:08:06 +0200

Pádraig Brady wrote:
> On 04/04/11 06:13, Jim Meyering wrote:
>> From: Jim Meyering <address@hidden>
>>
>> Running the new fiemap-empty test uses 600MB of disk space via
>> fallocate, and in so doing caused failure in unrelated tests that
>> were running in parallel on a small file system.  Rather than
>> simply running fallocate (which allocates the space, inducing
>> disk full when it fails), skip the test if there is less than
>> 800MB of free space, as computed via stat and awk.

Thanks for looking.

> Oops sorry.
> Maybe worth noting is that stat works at a lower level,

Not sure what you mean?  Both use statfs.

> and doesn't honor quotas etc, whereas df would be more

Hmm... I hadn't thought about quotas.
I never use them, so at least for me, it won't be an issue.

> accurate, and would do the multiplication internally.
>
> df -B1 -P . | tail -n1 | tr -s ' ' | cut -d ' ' -f4

I don't see how using df like that can be more accurate.  I chose not to
use df that way, because multiplying to get the free space size in bytes
would overflow when using my cloud FS with 20EiB free.  64 bits can count
bytes up to "only" 16EiB-1, so I opted to compare native block counts.
That gives a little more breathing room, even if it's only theoretical
for now.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]