bug-coreutils
[Top][All Lists]
Advanced

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

Re: mkfile -- create large files efficiently


From: Pádraig Brady
Subject: Re: mkfile -- create large files efficiently
Date: Mon, 9 Feb 2009 01:17:36 +0000
User-agent: Thunderbird 2.0.0.6 (X11/20071008)

Matej Cepl wrote:
> On 2009-02-08, 00:01 GMT, Pádraig Brady wrote:
>> It wasn't called after the system call. It was called after the
>> function it was providing. mkfile isn't the best name either BTW.
>> Also the existing `truncate` command in freebsd which
>> swayed the choice of name.
> 
> OK, so what do you suggest to do? Should I patch truncate with 
> posix_fallocate, or there is at least some hope for mkfile (I 
> still like the name)?

I would suggest patching a --allocate option into truncate.
Then mkfile can be implemented as a script something like:

(truncate --allocate || dd if=/dev/zero ) && chmod u+t

This is just one opinion though.
I'd get other opinions before doing anything.

cheers,
Pádraig.




reply via email to

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