whio  whio_epfs_mkfs

ACHTUNG: AS OF 20110523, THIS PAGE IS NOW MAINTAINED IN THE NEW WIKI: http://whiki.wanderinghorse.net/wikis/whio/?page=whio_epfs_mkfs

See also: whio_epfs_tools


whio-epfs-mkfs is a tool for creating whio_epfs container files. Aside from the common tools arguments, it accepts these parameters:

  • (REQUIRED) -i### or --inode-count=###
    Set the number of inodes in the EPFS. The EFS can contain, at most, this many entries. The highest legal value is the maximum value of a whio_epfs_id_t.
  • -c### or --block-count=###
    Set the maximum number of blocks in the EPFS. A value of 0 (the default) means to add blocks dynamically, up to the maximum value of whio_epfs_id_t.
  • -b### or --block-size=###
    sets the size of the data blocks, in bytes. Default value is "usable but unspecified."
  • -f or --fill-blocks
    If --block-count is not 0 then pre-allocate and zero-fill all blocks. If --block-count is 0 then this argument is ignored.
  • --label=string or -l[=]string sets the EFS label. The label is an arbitrary client-set string. It has a length limit of some compile-time-configurable size (64 is the default).
  • --force
    Causes mkfs to overwrite target file if it exists (default is to abort). This does not cause mkfs to override a file lock which another EPFS tool might have on the EFS.
  • --namer=string
    Installs the given EPFS namer implementation in the EFS.

If --force is used but mkfs determines that the EFS file is locked by another process, it will abort immediately unless --no-locking is used, in which case it will destroy the contents of the (opened) EFS (causing Grief in the application which locked it).


# Create an EFS for up to 200 entries, with a block size of 16000 bytes:
~> whio-epfs-mkfs -i200 -b16000 my.epfs

# Create an EFS for up to 10 entries and no more than 100
#   data blocks of 4kb each. The -f argument is optional, for
#   pre-filling all blocks with zeros.
~> whio-epfs-mkfs -i10 -c100 -f -b4096 my.epfs

# And here's a really big one with a fixed block count, all blocks
# pre-filled with zeroes:
~> ./whio-epfs-mkfs x.fs -i20000 -b$((1024 * 32)) -c20000 -f --namer=ht -v
./whio-epfs-mkfs [x.fs]: VERBOSE: Verbose mode activated.
./whio-epfs-mkfs [x.fs]: VERBOSE: EFS OPTIONS: inodeCount=20000, blockSize=32768, maxBlocks=20000
./whio-epfs-mkfs [x.fs]: VERBOSE: Filling out blocks table with 20000 blocks...
./whio-epfs-mkfs [x.fs]: EFS container created (656200244 bytes).

# (the same EPFS without pre-filled blocks is under 1MB)


  • Add -n/--dry-run argument.
  • Add more informative output, e.g. like whefs-mkfs