HP Serviceguard Toolkit for NFS version A.03.03.
© Copyright 2012 Hewlett-Packard Development Company, L.P. Confidential computer software. Valid license from HP required for possession, use or copying. Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license. The information contained herein is subject to change without notice.
Contents 1 Overview..................................................................................................4 Advantages.............................................................................................................................4 Dependencies..........................................................................................................................4 Prerequisites...........................................................................................................
1 Overview The HP Serviceguard Toolkit for NFS on Linux allows you to start, stop, and monitor a Network File System in a Serviceguard cluster environment. This toolkit consists of a set of shell scripts used by the package control script to start, stop, and monitor NFS daemons. The toolkit simplifies making NFS exports highly available by integrating NFS with Serviceguard for Linux (SG/LX).
Storage considerations Unless otherwise stated, the HP Serviceguard Toolkit for NFS on Linux runs on all hardware supported by Serviceguard A.11.20.00 on Linux.
2 Supported configuration This section explains the following supported configurations for NFS toolkit packages: • Failover from an active NFS server node to an idle NFS server node. • Configuring two NFS toolkit packages using NFSv4 protocol. • Coexistence of NFS toolkit package configured to use NFSv3 protocol and NFS package configured to use NFSv4 protocol on the same node.
Configuring two NFS toolkit packages using NFSv4 protocol Figure 2 Configuring two NFSv4 toolkit packages Figure 2 (page 7) shows a scenario where two NFS toolkit packages are using NFSv4 protocol. This configuration supports two NFSv4 packages. In this configuration, Node_A is the primary node for NFS server packages, Pkg1_v4 and NFS server package Pkg2_v4, which is configured to use NFSv4 protocol.
Coexistence of NFS toolkit packages configured to use NFSv3 and NFSv4 protocols on the same node Figure 3 Coexistence of NFS package configured to use NFSv3 and NFSv4 protocols on the same node Figure 3 (page 8) illustrates a co-existence scenario where NFS toolkit packages are configured to use NFSv3 and NFSv4 protocols on the same node.
3 Installing and uninstalling HP Serviceguard toolkit for NFS To install the RPM of HP Serviceguard toolkit for NFS: On Red Hat, run the following command: # rpm -ivh serviceguard-nfs-toolkit-.redhat.noarch.
Table 2 Files for creating modular packages File Name Description Available in Directory nfs.1 The attribute definition file, used to ${SGCONF}/modules/tkit/nfs generate the package ASCII template in modular style of packaging. tkit_module.sh The module script that is called by the ${SGCONF}/scripts/tkit/nfs master control script and acts as an interface between the master control script and the toolkit interface script (toolkit.sh).
4 Using HP Serviceguard toolkit for NFS After installing the HP Serviceguard Toolkit for NFS on Linux, you can use this toolkit to: • Deploy NFS as the package in a Serviceguard environment on Linux • Manage the NFS toolkit packages Deploying NFS toolkit packages You can deploy NFS toolkit packages using either legacy or modular style of packaging. NOTE: HP recommends that you configure HP Serviceguard toolkit for NFS as modular packages.
d. Attribute Example HALT_SCRIPT ${SGCONF}/NFS/pkg.cntl HALT_SCRIPT_TIMEOUT NO_TIMEOUT To run the NFS monitor script, set the SERVICE_NAME variable in the pkg.conf file. For example: SERVICE_NAME nfs1.monitor Each package must have a unique service name. In the legacy style of packaging the SERVICE_NAME variable in the package configuration file must be same as the SERVICE_NAME variable in the NFS control script.
cmmodpkg -d -n ‘hostname‘ pkg02 & } This package control function can prevent an adoptive node from becoming overloaded when multiple packages fail over. If an adoptive node becomes overloaded, it can fail. In this example, if a host is an adoptive node for both pkg01 and pkg02, the cmmodpkg -d command, in the control script for pkg01, prevents the host that is running pkg01 from adopting pkg02. If pkg02 fails, it fails over to another adoptive node (if configured) where pkg01 is not running.
# cmapplyconf -v -C ${SGCONF}/cluster.conf \ -P ${SGCONF}/NFS/pkg.conf b. Use your prefered copy utility (for example, scp) to copy the package control, NFS toolkit package, and monitor scripts to the same path names on all the nodes in the cluster.
Attributes Description vg The volume group to be used by the NFS. fs_name The logical volume on which the file system is created. For example: /dev/vgdata/lvol1 fs_directory The mount point location for exported NFS directories. For example: fs_directory /ha_ext3 fs_type A type of the filesystem. For example: ext3 ip_address and ip_subnet Attributes to be assigned when the package is configured to failover to another node.
Attributes Description to /export/v4recovery, where /export/sm or /export/v4recovery is a directory residing in a disk volume associated with this NFS package. NOTE: The status monitor directory is applicable for NFSv3 and /var/lib/nfs/v4recovery is applicable for NFSv4 protocol. 5. NFS_FLM_MONITOR This variable indicates whether the file lock migration script, nfs.flm must be monitored by the monitoring script.
To start the package, use either of the following commands: • # cmrunpkg • # cmrunpkg -n Stopping the package The Serviceguard package manager invokes the NFS toolkit script with stop as an input paramenter. This in turn does the following: • Unexports directory on the file system. • Stops NFS server daemons, if lock migration is enabled. • Stops NFS service processes (including nfs.mon). • Stops NFS file lock migration process.
Rolling Upgrade For rolling upgrade of HP Serviceguard Toolkit for NFS on Linux from older version to the toolkit version A.03.03.00, lock_migration.sh script must be available in the newly upgraded node. Before you start the older version of HP Serviceguard Toolkit for NFS on Linux package on the newly upgraded node, you must copy the lock_migration.sh script from non upgraded node to all the other packaged nodes where new version of toolkit is installed. For example, to copy the lock_migration.
5 File lock migration HP Serviceguard Toolkit for NFS on Linux provides file lock migration feature for the NFS directories that are exported to the client. You must provide a unique holding directory as part of the NFS package located on a shared file system. This implies that an empty directory is created on a shared filesystem that moves between servers as part of the package failover. The NFS_FLM_HOLDING_DIR parameter in the hanfs.
6 Troubleshooting This section explains some of the problem scenarios that you might encounter while working with the HP Serviceguard Toolkit for NFS on Linux in a Serviceguard cluster. Problem scenario Possible cause Recommended action The package log contains the following message: The parameter LOCK_MIGRATION is not set. NFS client locks will not be migrated. Lock migration feature is not enabled for the NFS package.
7 Support and other resources Information to collect before contacting HP Ensure that the following information is available before you contact HP: • Software product name • Hardware product model number • Operating system type and version • Applicable error message • Third-party hardware or software • Technical support registration number (if applicable) How to contact HP Use the following methods to contact HP technical support: • In the United States, see the Customer Service / Contact HP Un
Ctrl+x or Ctrl-x A key sequence that indicates you must hold down the keyboard key labeled Ctrl while you press the letter x. ENVIRONMENT VARIABLE The name of an environment variable, for example, PATH. Key The name of a keyboard key. Return and Enter both refer to the same key. Term A term or phrase that is defined in the body text of the document, not in a glossary. User input Indicates commands and text that you type exactly as shown.
A Sample configuration file for legacy style of packaging Sample package configuration file: pkg.conf PACKAGE_NAME PACKAGE_TYPE NODE_NAME NODE_NAME AUTO_RUN NODE_FAIL_FAST_ENABLED RUN_SCRIPT HALT_SCRIPT RUN_SCRIPT_TIMEOUT HALT_SCRIPT_TIMEOUT SUCCESSOR_HALT_TIMEOUT SCRIPT_LOG_FILE FAILOVER_POLICY FAILBACK_POLICY PRIORITY MONITORED_SUBNET MONITORED_SUBNET_ACCESS SERVICE_NAME SERVICE_FAIL_FAST_ENABLED SERVICE_HALT_TIMEOUT nfs_legacy FAILOVER mgr-kit1 mgr-kit2 YES NO ${SGCONF}/nfs_legacy/pkg.
B Sample configuration file for modular style of packaging package_name package_description package_type node_name auto_run node_fail_fast_enabled run_script_timeout halt_script_timeout successor_halt_timeout script_log_file failover_policy failback_policy tkit/nfs/nfs/TKIT_DIR tkit/nfs/nfs/XFS tkit/nfs/nfs/QUOTA_MON tkit/nfs/nfs/LOCK_MIGRATION tkit/nfs/nfs/NFS_FLM_HOLDING_DIR tkit/nfs/nfs/PROPAGATE_INTERVAL tkit/nfs/nfs/NFS_FLM_MONITOR tkit/nfs/nfs/NFS_FLM_RESTART tkit/nfs/nfs/MAINTENANCE_FLAG tkit/nfs/nfs
Glossary ${SGCONF} /usr/local/cmcluster/conf for RHEL ADF Attribute definition file ASCII American Standard Code for Information Interchange NFS Network File System NFSv4 way of exporting The directory on the file system is bounded with the virtual route directory and it will be exported.
Index D Deploying NFS toolkit packages, 11 Configuring a legacy NFS package, 11 Configuring a modular NFS package, 14 F File lock migration, 19 I Installation uninstallation, 9 M Managing the NFS toolkit package, 16 Deleting the package, 17 Maintaining the package, 17 Mounting NFS shares at client node, 17 Rolling Upgrade, 18 Starting the package, 16 Stopping the package, 17 N NFS Toolkit Advantages, 4 Dependecies, 4 Overview, 4 Prerequisites, 4 NFS toolkit troubleshooting, 20 NFS toolkit after Installa