Difference between revisions of "Fallocate"
Jump to navigation
Jump to search
↑ https://github.com/openzfs/zfs/issues/326
Tags: Mobile web edit, Mobile edit |
|||
Line 13: | Line 13: | ||
fallocate -l 1G NEW_filename | fallocate -l 1G NEW_filename | ||
fallocate: fallocate failed: [[No space left on device]] | fallocate: fallocate failed: [[No space left on device]] | ||
+ | |||
+ | fallocate | ||
+ | fallocate: no filename specified | ||
== Options == | == Options == |
Revision as of 13:19, 11 April 2021
fallocate
preallocate or deallocate space to a file, it is not supported in ZFS[1], use dd
instead of.
https://man7.org/linux/man-pages/man1/fallocate.1.html
Examples
fallocate -l 1G NEW_filename fallocate -l 24M NEW_filename -l --length
fallocate -l 1G NEW_filename fallocate: fallocate failed: No space left on device
fallocate fallocate: no filename specified
Options
fallocate -h Usage: fallocate [options] <filename> Preallocate space to, or deallocate space from a file. Options: -c, --collapse-range remove a range from the file -d, --dig-holes detect zeroes and replace with holes -i, --insert-range insert a hole at range, shifting existing data -l, --length <num> length for range operations, in bytes -n, --keep-size maintain the apparent size of the file -o, --offset <num> offset for range operations, in bytes -p, --punch-hole replace a range with a hole (implies -n) -z, --zero-range zero and ensure allocation of a range -x, --posix use posix_fallocate(3) instead of fallocate(2) -v, --verbose verbose mode -h, --help display this help -V, --version display version For more details see fallocate(1).
Execution examples
fallocate fallocate: no filename specified
fallocate -v -l 10G NEW_10G_FILE (not output on success)
Related commands
See also
- file, File system, directory,
touch
,mkdir
,ls
,ln
truncate
,fallocate
,split
,stat
, inode, File descriptor, superblock, block size (blockdev
),fuser
,lsof
,scrub
,chattr
, ulimit (nofiles),cp
,mv
,file (command)
,mkfifo
,chmod
- Swap,
swapon
,swapoff
,mkswap
,swaplabel
,free
,sar -r
,sar -S
,sar -W
,vmstat
,vm.swappiness
,/proc/swaps
,/etc/fstab
, Add a swap disk,systemd.swap
du, du -hs
, Disk space usage,df
,ls
,tree
,find
,docker system df
,journalctl --disk-usage
, No space left on device, ENOSPC,sar -F
,growpart
,resize2fs
, ncdu, duf, dua-cli
Advertising: