xref: /linux/Documentation/filesystems/gfs2/index.rst (revision cc4adab164b772a34b3340d644b7c4728498581e)
1.. SPDX-License-Identifier: GPL-2.0
2
3====================
4Global File System 2
5====================
6
7Overview
8========
9
10GFS2 is a cluster file system. It allows a cluster of computers to
11simultaneously use a block device that is shared between them (with FC,
12iSCSI, NBD, etc).  GFS2 reads and writes to the block device like a local
13file system, but also uses a lock module to allow the computers coordinate
14their I/O so file system consistency is maintained.  One of the nifty
15features of GFS2 is perfect consistency -- changes made to the file system
16on one machine show up immediately on all other machines in the cluster.
17
18GFS2 uses interchangeable inter-node locking mechanisms, the currently
19supported mechanisms are:
20
21  lock_nolock
22    - allows GFS2 to be used as a local file system
23
24  lock_dlm
25    - uses the distributed lock manager (dlm) for inter-node locking.
26      The dlm is found at linux/fs/dlm/
27
28lock_dlm depends on user space cluster management systems found
29at the URL above.
30
31To use GFS2 as a local file system, no external clustering systems are
32needed, simply::
33
34  $ mkfs -t gfs2 -p lock_nolock -j 1 /dev/block_device
35  $ mount -t gfs2 /dev/block_device /dir
36
37The gfs2-utils package is required on all cluster nodes and, for lock_dlm, you
38will also need the dlm and corosync user space utilities configured as per the
39documentation.
40
41gfs2-utils can be found at https://pagure.io/gfs2-utils
42
43GFS2 is not on-disk compatible with previous versions of GFS, but it
44is pretty close.
45
46The following man pages are available from gfs2-utils:
47
48  ============		=============================================
49  fsck.gfs2		to repair a filesystem
50  gfs2_grow		to expand a filesystem online
51  gfs2_jadd		to add journals to a filesystem online
52  tunegfs2		to manipulate, examine and tune a filesystem
53  gfs2_convert		to convert a gfs filesystem to GFS2 in-place
54  mkfs.gfs2		to make a filesystem
55  ============		=============================================
56
57Implementation Notes
58====================
59
60.. toctree::
61   :maxdepth: 1
62
63   glocks
64   uevents
65