3 ms·
Unless you want the space to be pre-allocated
by khc 12y ago
Unless you want the space to be pre-allocated
- stevekemp 12y agoYeah I've seen hosting companies in the past use sparse files for virtual machine storage - all is good unless, or until, they overcommit. At which point you have filesystem-soup..
- anon4 12y agoYes, the better way is by using the fallocate program which uses the posix_fallocate syscall, which makes a new file with a given size containing whatever happened to be on disk at the time. Basically malloc for filesystems.