background image

Global File System

Red Hat Global File

System

5.2

Global_File_System

ISBN: N/A

Publication date: May 2008

Summary of Contents for GLOBAL FILE SYSTEM 5.2

Page 1: ...Global File System Red Hat Global File System 5 2 Global_File_System ISBN N A Publication date May 2008...

Page 2: ...This book provides information about installing configuring and maintaining Red Hat GFS Red Hat Global File System for Red Hat Enterprise Linux 5 2 Global File System...

Page 3: ...copyright holder Distribution of the work or derivative of the work in any standard paper book form for commercial purposes is prohibited unless prior permission is obtained from the copyright holder...

Page 4: ...Global File System...

Page 5: ...Management 18 5 1 Setting Quotas 18 5 2 Displaying Quota Limits and Usage 19 5 3 Synchronizing Quotas 21 5 4 Disabling Enabling Quota Enforcement 22 5 5 Disabling Enabling Quota Accounting 23 6 Growin...

Page 6: ...vi...

Page 7: ...Related Documentation For more information about using Red Hat Enterprise Linux refer to the following resources Red Hat Enterprise Linux Installation Guide Provides information regarding installatio...

Page 8: ...fferent fonts styles and weights This highlighting indicates that the word is part of a specific category The categories include the following Courier font Courier font represents commands file names...

Page 9: ...y but possibly unexpected such as a configuration change that will not persist after a reboot Caution A caution indicates an act that would violate your support agreement such as recompiling the kerne...

Page 10: ...oning this manual s identifier we know exactly which version of the guide you have If you have a suggestion for improving the documentation try to be as specific as possible If you have found an error...

Page 11: ...of your backup media When configured in a Red Hat Cluster Suite Red Hat GFS nodes can be configured and managed with Red Hat Cluster Suite configuration and management tools Red Hat GFS then provides...

Page 12: ...and reorganized For information on the available documents see Section 2 Related Documentation 2 Performance Scalability and Economy You can deploy GFS in a variety of configurations to suit your nee...

Page 13: ...ent applications on a LAN can share the same SAN based data as shown in Figure 1 2 GFS and GNBD with a SAN SAN block storage is presented to network clients as block storage devices by GNBD servers Fr...

Page 14: ...w Linux client applications can take advantage of an existing Ethernet topology to gain shared access to all block storage devices Client data files and file systems can be shared with GFS on each cli...

Page 15: ...system and is loaded on GFS cluster nodes lock_dlm ko A lock module that implements DLM locking for GFS It plugs into the lock harness lock_harness ko and communicates with the DLM lock manager in Re...

Page 16: ...ntative When determining the size of your file system you should consider your recovery needs Running the fsck command on a very large file system can take a long time and consume a large amount of me...

Page 17: ...distribution Note The system clocks in GFS nodes must be within a few minutes of each other to prevent unnecessary inode time stamp updating Unnecessary inode time stamp updating severely impacts clu...

Page 18: ...NumberJournals BlockDevice For more information on creating a GFS file system see Section 1 Creating a File System 3 At each node mount the GFS file systems For more information about mounting a GFS f...

Page 19: ...ou can create a GFS file system with the gfs_mkfs command A file system is created on an activated LVM volume The following information is required to execute the gfs_mkfs command Lock protocol module...

Page 20: ...ockTableName parameters may cause file system or lock space corruption LockProtoName Specifies the name of the locking protocol to use The lock protocol for a cluster is lock_dlm The lock protocol whe...

Page 21: ...vg01 lvol0 Are you sure you want to proceed y n y Device dev vg01 lvol0 Blocksize 4096 Filesystem Size 136380192 Journals 8 Resource Groups 2082 Locking Protocol lock_dlm Lock Table alpha mydata1 Sync...

Page 22: ...by the gfs_mkfs command One journal is required for each node that mounts the file system Note More journals than are needed can be specified at creation time to allow for future expansion p LockProto...

Page 23: ...s_mkfs 2 Mounting a File System Before you can mount a GFS file system the file system must exist refer to Section 1 Creating a File System the volume where the file system exists must be activated an...

Page 24: ...tion of both Multiple option parameters are separated by a comma and no spaces Note The mount command is a Linux system command In addition to using GFS specific options described in this section you...

Page 25: ...ystem If LockModuleName is not specified the locking protocol name is read from the file system superblock locktable LockTableName For a clustered file system allows the user to specify which locking...

Page 26: ...tune command Some of these parameters are used to administer GFS quotas quota_quantum quota_enforce quota_account and atime_quantum These parameters are described in Section 5 GFS Quota Management alo...

Page 27: ...24 jindex_refresh_secs 60 depend_secs 60 scand_secs 5 recoverd_secs 60 logd_secs 1 quotad_secs 5 inoded_secs 15 glock_purge 0 quota_simul_sync 64 quota_warn_period 10 atime_quantum 3600 quota_quantum...

Page 28: ...s Other Linux quota facilities cannot be used with GFS 5 1 Setting Quotas Two quota settings are available for each user ID UID or group ID GID a hard limit and a warn limit A hard limit is the amount...

Page 29: ...m to which the actions apply Examples This example sets the hard limit for user Bert to 1024 megabytes 1 gigabyte on file system gfs gfs_quota limit u Bert l 1024 f gfs This example sets the warn limi...

Page 30: ...mber MountPoint Specifies the GFS file system to which the actions apply Command Output GFS quota information from the gfs_quota command is displayed as follows user User limit LimitSize warn WarnSize...

Page 31: ...sers on file system gfs root ask 07 gfs_quota get g users f gfs s group users limit 0 warn 96 value 0 5 3 Synchronizing Quotas GFS stores all quota information in its own internal file on disk A GFS n...

Page 32: ...time period between regular quota file synchronizations by GFS Smaller values may increase contention and slow down performance Examples This example synchronizes the quota information from the node...

Page 33: ...disables enforcement Enforcement can be enabled by running the command with a value of 1 instead of 0 as the final command line parameter Even when GFS is not enforcing quotas it still keeps track of...

Page 34: ...on a file system the quota_account parameter must be set back to 1 Afterward the GFS quota file must be initialized to account for all current disk usage for users and groups on the file system The q...

Page 35: ...the expansion has occurred and automatically start using the new space To verify that the changes were successful use the gfs_grow command with the T test and v verbose flags Running the command with...

Page 36: ...341168 DEV Size 9175040 Preparing to write new FS information Done Complete Usage gfs_grow Options MountPoint Device MountPoint Device MountPoint Specifies the directory where the GFS file system is m...

Page 37: ...mand with those flags displays the current state of the mounted GFS file system Usage gfs_jadd j Number MountPoint Number Specifies the number of new journals to be added MountPoint Specifies the dire...

Page 38: ...is mounted at the mnt gfs directory The underlying logical volume for this filesystem is extended before the journal can be added root tng3 1 lvextend L35G dev gfsvg gfslv Extending logical volume gfs...

Page 39: ..._jadd command must be run for each size journal The size specified is rounded down so that it is a multiple of the journal segment size that was specified when the file system was created j Number Spe...

Page 40: ...s can be used to enable direct I O on a file O_DIRECT GFS file attribute GFS directory attribute 8 1 O_DIRECT If an application uses the O_DIRECT flag on an open system call direct I O is used for the...

Page 41: ...directio 8 3 GFS Directory Attribute The gfs_tool command can be used to assign set a direct I O attribute flag inherit_directio to a GFS directory Enabling the inherit_directio flag on a directory ca...

Page 42: ...n result in a reduced fsync time especially for small files because the file data is written to the journal in addition to the metadata An fsync returns as soon as the data is written to the journal w...

Page 43: ...example also shows the gfs_tool stat command you can use to verify what flags are set for a directory the output has been elided to show only the relevant information root tng3 1 gfs_tool setflag inhe...

Page 44: ...That traffic can degrade performance therefore it may be preferable to turn off atime updates Two methods of reducing the effects of atime updating are available Mount with noatime Tune GFS atime qua...

Page 45: ...isplaying GFS Tunable Parameters The default value for atime_quantum is 3600 seconds The gfs_tool settune command is used to change the atime_quantum parameter value It must be set on each node and ea...

Page 46: ...ommand to gather a variety of details about GFS This section describes typical use of the gfs_tool command for displaying space usage statistics and extended status The gfs_tool command provides addit...

Page 47: ...first 1 Journal number 0 Lock module flags 0 Local flocks FALSE Local caching FALSE Oopses OK FALSE Type Total Used Free use inodes 5 5 0 100 metadata 78 15 63 19 data 41924125 0 41924125 0 12 2 Disp...

Page 48: ...a period that is tunable This number is the list length It is related to the number of gfs_unlinked structures currently in gfs quota IDs The number of gfs_quota_data structures that currently exist i...

Page 49: ...call operations readpage writepage directIO prepare_write and commit_write dentry operations The number of times a seek operation has been performed on the vfs dentry structure export operations The n...

Page 50: ...locks on reclaim list 0 log wraps 0 outstanding LM calls 0 outstanding BIO calls 0 fh2dentry misses 0 glocks reclaimed 345 glock nq calls 11632 glock dq calls 11596 glock prefetch calls 84 lm_lock cal...

Page 51: ...file gfs datafile root tng3 1 gfs gfs_tool stat gfs datafile mh_magic 0x01161970 mh_type 4 mh_generation 3 mh_format 400 mh_incarn 1 no_formal_ino 66 no_addr 66 di_mode 0600 di_uid 0 di_gid 0 di_nlink...

Page 52: ...run only on a file system that is unmounted from all nodes Note The gfs_fsck command has changed from previous releases of Red Hat GFS in the following ways You can no longer set the interactive mode...

Page 53: ...the sample output is extensive and repetitive lines have been elided root tng3 1 gfs_fsck v y dev gfsvg gfslv Initializing fsck Initializing lists Initializing special inodes Validating Resource Group...

Page 54: ...r directories The variables are resolved to real files or directories each time an application follows the link The resolved value of the link depends on the node or user following the link CDPN varia...

Page 55: ...o uname m os This variable resolves to a real file or directory named with the operating system name string produced by the output of the following command echo uname s sys This variable resolves to a...

Page 56: ...og hostname drwxr xr x 2 root root 3864 Apr 25 14 05 n01 drwxr xr x 2 root root 3864 Apr 25 14 06 n02 drwxr xr x 2 root root 3864 Apr 25 14 06 n03 n01 touch gfs log fileA n02 touch gfs log fileB n03 t...

Page 57: ...IRECT 30 growing 25 mounting 13 quota management 18 disabling enabling quota accounting 23 disabling enabling quota enforcement 22 displaying quota limits 19 setting quotas 18 synchronizing quotas 21...

Page 58: ...requisite tasks configuration initial 7 Q quota management 18 disabling enabling quota accounting 23 disabling enabling quota enforcement 22 displaying quota limits 19 setting quotas 18 synchronizing...

Reviews: