NILFS(8) - Linux man page online | Administration and privileged commands
The new implementation of a log-structured file system.
NILFS(8) System Manager's Manual NILFS(8)
nilfs-utils version 2.2 Apr 2014 NILFS(8)
NAMENILFS - the new implementation of a log-structured file system
SYNOPSISOverview of the NILFS file system and the related tools.
DESCRIPTIONNILFS is a log-structured file system developed for Linux. NILFS provides versioning capability of an entire file system and continuous snapshotting that allows users to restore files mistakenly overwritten or destroyed a while ago. The current major version of NILFS is version 2, which is referred to as NILFS2. NILFS2 is equipped with an online garbage collector (also called cleaner) that reclaims disk space in the background with keeping multiple snapshots. When data is written or any change is made to a NILFS2 file system, it automatically cre‐ ates a checkpoint. A checkpoint represents a consistent state of the NILFS2 file system of a certain instant. It becomes mountable after being changed into a snapshot. A snap‐ shot is the checkpoint marked not to be deleted by the cleaner. NILFS2 creates a number of checkpoints at regular intervals (unless there is no change) or with synchronous writ‐ ings. There is no practical limit on the number of checkpoints and snapshots. The following tools are available to manage the checkpoint and the snapshot: lscp lists checkpoints or snapshots mkcp makes a checkpoint or a snapshot chcp changes an existing checkpoint to a snapshot or vice versa rmcp invalidates specified checkpoint(s) These tools give the versioning capability to NILFS2; a user can select significant ver‐ sions among continuously created checkpoints and can change them to snapshots to be pre‐ served for long periods. Every checkpoint except for the snapshot will become unprotected from the cleaner after a given period of time. This period is controlled by the protection_period parameter defined in the /etc/nilfs_cleanerd.conf(5) file.
MOUNT OPTIONSRefer to the mount.nilfs2(8).
EXAMPLESmkfs -t nilfs2 /dev/sdb1 creates a NILFS2 file system on a block device `/dev/sdb1'. mount -t nilfs2 /dev/sdb1 /nilfs mounts the NILFS2 file system on a mount point `/nilfs' like an ordinary POSIX file system. This will invoke a cleaner process nilfs_cleanerd(8) through an external mount program (i.e. mount.nilfs2(8)). lscp lists checkpoints created in the file system as follows: CNO DATE TIME MODE FLG BLKCNT ICNT 1 2014-01-18 20:49:54 cp - 4 2 2 2014-01-18 20:51:45 cp - 3990 11 3 2014-01-18 20:51:45 cp - 6058 3 4 2014-01-18 20:51:49 cp - 4807 6 5 2014-01-18 20:51:49 cp - 262 3 ... chcp ss 2 changes the checkpoint whose checkpoint-number is two to a snapshot. Then the checkpoint list will become as follows: CNO DATE TIME MODE FLG BLKCNT ICNT 1 2014-01-18 20:49:54 cp - 4 2 2 2014-01-18 20:51:45 ss - 3990 11 3 2014-01-18 20:51:45 cp - 6058 3 4 2014-01-18 20:51:49 cp - 4807 6 5 2014-01-18 20:51:49 cp - 262 3 ... mount -t nilfs2 -r -o cp=2 /dev/sdb1 /snapshot mounts the snapshot on another directory `/snapshot' as a read-only file system. Here the snapshot mount requires at least two options, a read-only option (-r or -o ro) and the cp option (-o cp=checkpoint-number). Note that a read/write mount and one or more snapshots are mountable independently, so the online backup is possible through the snapshot mounts. # mount -t nilfs2 /dev/sdb1 on /nilfs type nilfs2 (rw,gcpid=13296) /dev/sdb1 on /snapshot type nilfs2 (ro,cp=2) umount /nilfs unmounts the NILFS2 file system mounted on `/nilfs' and will shutdown the nilfs_cleanerd(8) through an external umount program (umount.nilfs2(8)) for the read/write mount.
AUTHORSNILFS2 was developed by NILFS development team.
SEE ALSOmkfs.nilfs2(8), mount.nilfs2(8), umount.nilfs2(8), nilfs_cleanerd(8), nilfs_clean‐ erd.conf(5), nilfs-tune(8), nilfs-clean(8), nilfs-resize(8), lscp(1), mkcp(8), chcp(8), rmcp(8), lssu(1), dumpseg(8) http://nilfs.sourceforge.net/
|This manual||Reference||Other manuals|
|nilfs(8)||referred by||chcp(8) | dumpseg(8) | lscp(1) | lssu(1) | mkcp(8) | mkfs.nilfs2(8) | mount.nilfs2(8) | nilfs-clean(8) | nilfs-resize(8) | nilfs-tune(8) | nilfs_cleanerd(8) | rmcp(8) | umount.nilfs2(8)|
|refer to||chcp(8) | dumpseg(8) | lscp(1) | lssu(1) | mkcp(8) | mkfs.nilfs2(8) | mount.nilfs2(8) | nilfs-clean(8) | nilfs-resize(8) | nilfs-tune(8) | nilfs_cleanerd(8) | nilfs_cleanerd.conf(5) | rmcp(8) | umount.nilfs2(8)|