1FALLOCATE(1)                General Commands Manual               FALLOCATE(1)
2
3
4

NAME

6       fallocate - preallocate space to a file.
7

SYNOPSIS

9       fallocate [-n] [-o offset] -l length filename
10

DESCRIPTION

12       fallocate  is  used  to  preallocate blocks to a file.  For filesystems
13       which support the fallocate system call, this is done quickly by  allo‐
14       cating blocks and marking them as uninitialized, requiring no IO to the
15       data blocks.  This is much faster than creating a file  by  filling  it
16       with zeros.
17
18       As  of the Linux Kernel v2.6.31, the fallocate system call is supported
19       by the btrfs, ext4, ocfs2, and xfs filesystems.
20
21       The exit code returned by fallocate is 0 on success and 1 on failure.
22

OPTIONS

24       The length and offset arguments may be followed by  binary  (2^N)  suf‐
25       fixes  KiB,  MiB, GiB, TiB, PiB and EiB (the "iB" is optional, e.g. "K"
26       has the same meaning as "KiB") or decimal (10^N) suffixes KB,  MB,  GB,
27       PB and EB.
28
29       -h, --help
30              Print help and exit.
31
32       -n, --keep-size
33              Do  not  modify the apparent length of the file. This may effec‐
34              tively allocate blocks past EOF, which can  be  removed  with  a
35              truncate.
36
37       -o, --offset offset
38              Specifies the beginning offset of the allocation, in bytes.
39
40       -l, --length length
41              Specifies the length of the allocation, in bytes.
42

AUTHORS

44       Eric Sandeen <sandeen@redhat.com>
45       Karel Zak <kzak@redhat.com>
46

SEE ALSO

48       fallocate(2), posix_fallocate(3), truncate(1)
49

AVAILABILITY

51       The  fallocate  command  is  part  of  the util-linux-ng package and is
52       available from ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng/.
53
54
55
56
57Version 1.0                        Jul 2009                       FALLOCATE(1)
Impressum