Using gbnd with global file system in rhel 4.6 (26 pages)
Summary of Contents for Red Hat GLOBAL FILE SYSTEM 4.6
Page 1
Global File System Red Hat Global File System ISBN: N/A Publication date:...
Page 2
Global File System This book provides information about installing, configuring, and maintaining Red Hat GFS (Red Hat Global File System).
Page 3
All other trademarks referenced herein are the property of their respective owners. The GPG fingerprint of the security@redhat.com key is: CA 20 86 86 2B D6 9D FC 65 F6 EC C4 21 91 80 CD DB 42 A6 0E...
Introduction ......................vii 1. Audience ...................... vii 2. Related Documentation ................. vii 3. Document Conventions ................viii 4. Feedback .......................x 5. Recommended References ................x 1. GFS Overview ....................... 1 1. Performance, Scalability, and Economy ............1 1.1. Superior Performance and Scalability ........... 2 1.2.
Page 6
Global File System 10. Suspending Activity on a File System ............37 11. Displaying Extended GFS Information and Statistics ........38 12. Repairing a File System ................39 13. Context-Dependent Path Names ..............41 A. Upgrading GFS ....................45 Index ........................49...
Configuring and Managing a Red Hat Cluster. HTML and PDF versions of all the official Red Hat Enterprise Linux manuals and release notes are available online at http://www.redhat.com/docs/. 1. Audience This book is intended primarily for Linux system administrators who are familiar with the following activities: •...
Red Hat Cluster Suite documentation and other Red Hat documents are available in HTML and PDF versions online at the following location: http://www.redhat.com/docs 3. Document Conventions Certain words in this manual are represented in different fonts, styles, and weights. This highlighting indicates that the word is part of a specific category.
Page 9
Feedback italic Courier font Italic Courier font represents a variable, such as an installation directory: install_dir/bin/ bold font Bold font represents application programs and text found on a graphical interface. When shown like this: OK , it indicates a button on a graphical application interface. Additionally, the manual uses different strategies to draw your attention to pieces of information.
Introduction 4. Feedback If you spot a typo, or if you have thought of a way to make this manual better, we would love to hear from you. Please submit a report in Bugzilla (http://bugzilla.redhat.com/bugzilla/) against the component rh-cs Be sure to mention the manual's identifier: rh-gfs(EN)-4.6 (2007-11-12T15:10)
Chapter 1. GFS Overview Red Hat GFS is a cluster file system that is available with Red Hat Cluster Suite. Red Hat GFS nodes are configured and managed with Red Hat Cluster Suite configuration and management tools. Red Hat GFS provides data sharing among GFS nodes in a Red Hat cluster. GFS provides a single, consistent view of the file-system name space across the GFS nodes in a Red Hat cluster.
Chapter 1. GFS Overview might require a combination of configurations shown in the examples. 1.1. Superior Performance and Scalability You can obtain the highest shared-file performance when applications access storage directly. The GFS SAN configuration in Figure 1.1, “GFS with a SAN” provides superior file performance for shared files and file systems.
Economy and Performance Note Clients implementing ext2 and ext3 file systems can be configured to access their own dedicated slice of SAN storage. Figure 1.2. GFS and GNBD with a SAN 1.3. Economy and Performance Figure 1.3, “GFS and GNBD with Directly Connected Storage” shows how Linux client applications can take advantage of an existing Ethernet topology to gain shared access to all block storage devices.
Chapter 1. GFS Overview Figure 1.3. GFS and GNBD with Directly Connected Storage 2. GFS Functions GFS is a native file system that interfaces directly with the VFS layer of the Linux kernel file-system interface. GFS is a cluster file system that employs distributed metadata and multiple journals for optimal operation in a cluster.
GFS Software Subsystems • Making a File System • Mounting a File System • Unmounting a File System • GFS Quota Management • Growing a File System • Adding Journals to a File System • Direct I/O • Data Journaling •...
Chapter 1. GFS Overview Software Subsystem Components Description file system. Implements a pluggable lock module lock_harness.ko interface for GFS that allows for a variety of locking mechanisms to be used (for example, the DLM lock module, lock_dlm.ko A lock module that implements DLM lock_dlm.ko locking for GFS.
Page 19
Before Setting Up GFS GFS nodes Determine which nodes in the Red Hat Cluster Suite will mount the GFS file systems. GNBD server nodes If you are using GNBD, determine how many GNBD server nodes are needed. Note the hostname and IP address of each GNBD server node for setting up GNBD clients later. For information on using GNBD with GFS, see the Using GNBD with Global File System document.
Chapter 2. System Requirements This chapter describes the system requirements for Red Hat GFS with Red Hat Enterprise Linux 5 and consists of the following sections: • Section 1, “Platform Requirements” • Section 2, “Red Hat Cluster Suite” • Section 3, “Fencing” •...
Chapter 2. System Requirements You must configure each GFS node in your Red Hat cluster for at least one form of fencing. Fencing is configured and managed in Red Hat Cluster Suite. For more information about fencing options, refer to Configuring and Managing a Red Hat Cluster. 4.
Network Power Switches Requirement Description When determining the size of your file system, you should consider your recovery needs. Running the fsck command on the file system can take a long time and consume a large amount of memory. Additionally, in the event of a disk or disk-subsytem failure, recovery time is limited by the speed of your backup media.
Chapter 3. Getting Started This chapter describes procedures for initial setup of GFS and contains the following sections: • Section 1, “Prerequisite Tasks” • Section 2, “Initial Setup Tasks” 1. Prerequisite Tasks Before setting up Red Hat GFS, make sure that you have noted the key characteristics of the GFS nodes (refer to Section 4, “Before Setting Up GFS”) and have loaded the GFS modules...
Page 26
Chapter 3. Getting Started Note You can use scripts included with Red Hat Cluster Suite to automate init.d activating and deactivating logical volumes. For more information about init.d scripts, refer to Configuring and Managing a Red Hat Cluster. 2. Create GFS file systems on logical volumes created in Step 1. Choose a unique name for each file system.
Chapter 4. Managing GFS This chapter describes the tasks and commands for managing GFS and consists of the following sections: • Section 1, “Making a File System” • Section 2, “Mounting a File System” • Section 3, “Unmounting a File System” •...
Page 28
Chapter 4. Managing GFS Warning Make sure that you are very familiar with using the LockProtoName parameters. Improper use of the LockTableName LockProtoName parameters may cause file system or lock space corruption. LockTableName LockProtoName Specifies the name of the locking protocol (for example, ) to use.
Page 29
Complete Options Complete Options Table 4.1, “Command Options: ” describes the command options (flags and gfs_mkfs gfs_mkfs parameters). Flag Parameter Description Sets the file-system block size to BlockSize BlockSize Default block size is 4096 bytes. Enables debugging output. Help. Displays available options. Specifies the size of the journal in megabytes.
Chapter 4. Managing GFS Flag Parameter Description management GUI. , the file-system name, can be 1 to 16 FSName characters in length, and the name must be unique among all file systems in the cluster. Displays command version information. Table 4.1. Command Options: gfs_mkfs 2.
Complete Usage In this example, the GFS file system on is mounted on the directory. /dev/vg01/lvol0 /gfs1 mount -t gfs /dev/vg01/lvol0 /gfs1 Complete Usage mount -t gfs BlockDevice MountPoint -o option argument consists of GFS-specific options (refer to Table 4.2, “GFS-Specific -o option Mount Options”) or acceptable standard Linux...
Chapter 4. Managing GFS Option Description GFS can then turn on selected optimization localcaching capabilities that are not available when running in Caution: This option should not be used cluster mode. The flag is localcaching when GFS file systems are shared. automatically turned on by lock_nolock Tells GFS to let the VFS (virtual file system) layer...
Usage Note command is a Linux system command. Information about this umount command can be found in the Linux command man pages. umount Usage umount MountPoint MountPoint Specifies the directory where the GFS file system should be mounted. 4. GFS Quota Management File-system quotas are used to limit the amount of file-system space a user or group can use.
Page 34
Chapter 4. Managing GFS Usage Setting Quotas, Hard Limit gfs_quota limit -u User -l Size -f MountPoint gfs_quota limit -g Group -l Size -f MountPoint Setting Quotas, Warn Limit gfs_quota warn -u User -l Size -f MountPoint gfs_quota warn -g Group -l Size -f MountPoint User A user ID to limit or warn.
Displaying Quota Limits and Usage gfs_quota warn -g 21 -l 50 -k -f /gfs 4.2. Displaying Quota Limits and Usage Quota limits and current usage can be displayed for a specific user or group using the command. The entire contents of the quota file can also be displayed using the gfs_quota get command, in which case all IDs with a non-zero hard limit, warn limit, or value gfs_quota list...
Chapter 4. Managing GFS group Group: limit:LimitSize warn:WarnSize value:Value , and numbers (values) are in units of megabytes by default. LimitSize WarnSize Value Adding the , or flags to the command line change the units to kilobytes, sectors, or file-system blocks, respectively. User A user name or ID to which the data is associated.
Page 37
Synchronizing Quotas This is necessary to avoid contention among nodes writing to the quota file, which would cause a slowdown in performance. As a user or group approaches their quota limit, GFS dynamically reduces the time between its quota-file updates to prevent the limit from being exceeded. The normal time period between quota synchronizations is a tunable parameter, , and can be changed using the quota_quantum...
Chapter 4. Managing GFS (3600 seconds) for file system on a single node. /gfs gfs_tool settune /gfs quota_quantum 3600 4.4. Disabling/Enabling Quota Enforcement Enforcement of quotas can be disabled for a file system without clearing the limits set for all users and groups.
Disabling/Enabling Quota Accounting 4.5. Disabling/Enabling Quota Accounting By default, quota accounting is enabled; therefore, GFS keeps track of disk usage for every user and group even when no quota limits have been set. Quota accounting incurs unnecessary overhead if quotas are not used. You can disable quota accounting completely by setting the tunable parameter to 0.
Chapter 4. Managing GFS This example enables quota accounting on file system on a single node and initializes the /gfs quota file. # gfs_tool settune /gfs quota_account 1 # gfs_quota init -f /gfs 5. Growing a File System command is used to expand a GFS file system after the device where the file gfs_grow system resides has been expanded.
Examples After running the command, run a command to check that the new space is now gfs_grow available in the file system. Examples In this example, the file system on the directory is expanded. /gfs1 gfs_grow /gfs1 In this example, the state of the mounted file system is checked. gfs_grow -Tv /gfs1 Complete Usage gfs_grow [Options] {MountPoint | Device} [MountPoint | Device]...
Page 42
Chapter 4. Managing GFS command is used to add journals to a GFS file system after the device where the gfs_jadd file system resides has been expanded. Running a command on a GFS file system gfs_jadd uses space between the current end of the file system and the end of the device where the file system resides.
Page 43
Complete Usage In this example, two journals are added to the file system on the directory. /gfs1 gfs_jadd -j2 /gfs1 In this example, the current state of the file system on the directory is checked for the /gfs1 new journals. gfs_jadd -Tv /gfs1 Complete Usage gfs_jadd [Options] {MountPoint | Device} [MountPoint | Device]...
Chapter 4. Managing GFS Flag Parameter Description verbosity level to display more information. Quiet. Turns down the verbosity level. Displays command version information. Turns up the verbosity of messages. Table 4.4. GFS-specific Options Available When Adding Journals 7. Direct I/O Direct I/O is a feature of the file system whereby file reads and writes go directly from the applications to the storage device, bypassing the operating system read and write caches.
GFS Directory Attribute Setting the Flag directio gfs_tool setflag directio File Clearing the Flag directio gfs_tool clearflag directio File File Specifies the file where the flag is assigned. directio Example In this example, the command sets the flag on the file named in directory directio datafile...
Chapter 4. Managing GFS Directory Specifies the directory where the flag is set. inherit_directio Example In this example, the command sets the flag on the directory named inherit_directio /gfs1/data/ gfs_tool setflag inherit_directio /gfs1/data/ 8. Data Journaling Ordinarily, GFS writes only metadata to its journal. File contents are subsequently written to disk by the kernel's periodic sync that flushes file-system buffers.
Examples Directory Specifies the directory where the flag is set or cleared. File Specifies the zero-length file where the flag is set or cleared. Examples This example shows setting the flag on a directory. All files created in the inherit_jdata directory or any of its subdirectories will have the flag assigned automatically.
Chapter 4. Managing GFS 9.1. Mount with noatime A standard Linux mount option, , can be specified when the file system is mounted, noatime which disables updates on that file system. atime Usage mount -t gfs BlockDevice MountPoint -o noatime BlockDevice Specifies the block device where the GFS file system resides.
Suspending Activity on a File System gfs_tool gettune MountPoint MountPoint Specifies the directory where the GFS file system is mounted. Changing the Parameter Value atime_quantum gfs_tool settune MountPoint atime_quantum Seconds MountPoint Specifies the directory where the GFS file system is mounted. Seconds Specifies the update period in seconds.
Chapter 4. Managing GFS gfs_tool freeze MountPoint End Suspension gfs_tool unfreeze MountPoint MountPoint Specifies the file system. Examples This example suspends writes to file system /gfs gfs_tool freeze /gfs This example ends suspension of writes to file system /gfs gfs_tool unfreeze /gfs 11.
Examples flag displays a space-usage summary of a given file system. The information is more detailed than a standard Displaying Extended Status gfs_tool stat File flag displays extended status information about a file. stat MountPoint Specifies the file system to which the action applies. File Specifies the file from which to get information.
Page 52
Chapter 4. Managing GFS command has changed from previous releases of Red Hat GFS in gfs_fsck the following ways: • You can no longer set the interactive mode with Ctrl-C. Pressing Ctrl-C now cancels the command. Do not press Ctrl-C unless you want to gfs_fsck cancel the command.
Usage 13. Context-Dependent Path Names Context-Dependent Path Names (CDPNs) allow symbolic links to be created that point to variable destination files or 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.
Page 54
Chapter 4. Managing GFS Variable Description This variable resolves to a real file or directory name with the @mach machine-type string produced by the output of the following command: echo `uname -m` 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`...
Appendix A. Upgrading GFS To upgrade a node to Red Hat GFS 6.1 from earlier versions of Red Hat GFS, you must convert the GFS cluster configuration archive (CCA) to a Red Hat Cluster Suite cluster configuration system (CCS) configuration file ( ) and convert GFS volumes /etc/cluster/cluster.conf...
Page 58
Appendix A. Upgrading GFS # service pool stop e. Uninstall Red Hat GFS RPMs. 2. Install new software: a. Install Red Hat Enterprise Linux version 4 software (or verify that it is installed). b. Install Red Hat Cluster Suite and Red Hat GFS RPMs. 3.
Page 59
GFS 6.1 nodes are pool using LVM2 for other purposes (root file system) there may be problems activating the volumes under GFS 6.1. That is because of static minor pool conflicts. Refer to the following Bugzilla report for more information: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=146035...
data journaling, 34 Index direct I/O, 32 directory attribute, 33 file attribute, 32 O_DIRECT, 32 growing, 28 adding journals to a file system, 29 making, 15 atime, configuring updates, 35 mounting, 18 mounting with noatime, 36 quota management, 21 tuning atime quantum, 36 disabling/enabling quota accounting, 27 audience, vii disabling/enabling quota enforcement,...
Page 62
Index growing a file system, 28 recommended references table, x Red Hat Cluster Suite system requirements, 9 references, recommended, x initial tasks repairing a file system, 39 setup, initial, 13 introduction, vii audience, vii references, x setup, initial initial tasks, 13 suspending activity on a file system, 37 system requirements, 9 making a file system, 15...
Need help?
Do you have a question about the GLOBAL FILE SYSTEM 4.6 and is the answer not in the manual?
Questions and answers