Index Index for
Section 4
Index Alphabetical
listing for C
Bottom of page Bottom of
page

cfsd.conf(4)

NAME

cfsd.conf - cfsd daemon configuration file

DESCRIPTION

The /etc/cfsd.conf configuration file specifies operational attributes for the cfsd daemon and defines sets of file system placement policies. In a cluster, each file system has a placement policy associated with it. This policy determines how cfsd manages the file system. If you modify this file, keep the following points in mind: · All file systems in the cluster have a placement policy associated with them. If you do not explicitly assign a file system to a policy, it is assigned to the default policy. · There is no limit on the number of policies you can create. /etc/cfsd.conf uses the stanza file format described in stanza(4). cfsd Stanza This stanza contains attributes that control the overall behavior of the cfsd daemon. These attributes affect all file systems and members. There can be only one cfsd entry in the configuration file. The following attributes and values are recognized for the cfsd entry: active = [1|0] The active attribute specifies whether or not cfsd is active. If you specify 0, cfsd is dormant: it does not monitor the cluster, collect statistics, analyze statistics, or relocate file systems. cfsd remains dormant until you set the active attribute to 1 and you send cfsd a SIGHUP signal, which causes it to reread the /etc/cfsd.conf file. (If you send SIGHUP to any cfsd daemon process in the cluster, all cfsd daemons reread the file.) When active is set to 1, cfsd is active to the extent specified in its configuration file. The default value is 0, not active. analyze_interval = {hours:mins}[:{secs}] The analyze_interval attribute specifies how often cfsd analyzes the data that it has collected and subsequently writes the /var/cluster/cfs/analysis.log file. If analyze_interval is set to 0, cfsd does not perform analyses. The default value for analyze_interval is 02:00:00; statistics are analyzed and subsequently logged every two hours. analyze_samplesize = {hours:mins}[:{secs}] The analyze_samplesize attribute specifies the maximum amount of data that cfsd should use in each analysis, if available. If the amount of data indicated by analyze_samplesize is not available, cfsd uses what is available. For each analysis, cfsd considers the last hours, minutes, and, optionally, seconds worth of data. The default value for analyze_samplesize is 24:00, which means that up to the last 24 hours worth of data is used if available. reloc_on_memory_warning = 0|1 The reloc_on_memory_warning attribute instructs cfsd how to react to a CFS high memory usage warning on a member. If reloc_on_memory_warning is set to 0, cfsd ignores the warning. If set to 1, cfsd attempts to reduce CFS memory usage on the member by moving some of the file systems that it serves to other members in the cluster. The default value for reloc_on_memory_warning is 0. reloc_stagger = {mins}[:{secs}] The reloc_stagger attribute specifies how far apart to stagger automatic relocations. To prevent an unreasonable disruption in cluster activity during automatic relocations, cfsd spaces the relocations out by the number of minutes and seconds that you specify. The default value for reloc_stagger is 0, which indicates that automatic relocations are not staggered. defaultpolicy Stanza The default policy entry contains attributes that specify default analysis and relocation attributes for any file system that is not listed in another policy stanza. In addition, if a policy does not specifically define an attribute that is defined in the default policy, the other policy inherits the value set by the default policy stanza. parameters. Do not assign a name to the default policy. There can only be one defaultpolicy stanza in the configuration file. The following attributes and values are recognized for the default policy stanza: polling_schedule = 0 | {s_days}, {s_hours}, {i_hours}:{i_mins} [:{i_secs}] polling_schedule specifies how often the cfsd daemon collects information for file systems and subsequently writes the /var/cluster/cfs/stats.member file. For each intance of polling_schedule, on scheduled days (s_days) during scheduled hours (s_hours), cfsd collects statistics every interval hours (i_hours), interval minutes (i_mins), and, optionally, interval seconds (i_secs). There can be as many polling_schedule attributes per policy as necessary. For example, you might want a different polling schedule for weekends. Specify days using 0 to 6 for Sunday to Saturday. Separate values with a dash (-) to indicate an inclusive range. To specify individual days, separate the days with a comma and enclose the entire days specification in quotes, as shown in the following example: polling_schedule = "0,6", 0-23, 01:00:00 Specify hours using 0 to 24. Separate values with a dash (-) to indicate an inclusive range. To specify individual hours, separate the hours with a comma and enclose the entire hours specification in quotes, as shown in the following example: polling_schedule = 0-6, "0,23", 01:00:00 If you specify 0, statistics collection is not performed for the file systems. The default value for polling_schedule is 0-6, 0-23, 00:15:00, which equates to any day, any hour, every 15 minutes. placement = favored The placement attribute controls how cfsd selects members to serve the file systems in the policy when none of the members specified in hosting_members attributes is available. The only supported value is favored: if none of the members specified in hosting_members is available, cfsd selects another member. hosting_members = * | {member1}[, {member2}[, ...]] The hosting_members attribute lists each cluster member that can be the CFS server for the file systems in this policy. When relocating a file system or recommending relocations, cfsd assigns a file system to one of these members. hosting_members is a restrictive list, not a preferred list; the placement attribute controls how the file systems are placed when none of the members specified by hosting_members attributes is available. The cfsd daemon treats all cluster members identified in a single hosting_members entry equally; no ordering preference is assumed by position in the list. To specify an ordering of member preference, use multiple hosting_members entries: hosting_members = member_name hosting_members = member_name hosting_members = member_name hosting_members = member_name Within a policy, cfsd gives preference to the members listed in the first hosting_members entry, followed by the members in the next hosting_members entry, and so on. If you specify an asterisk (*) as the value of a hosting_members attribute, any member of the cluster can be the CFS server for the file systems. Even though the asterisk refers to all cluster members, cfsd considers device connectivity when placing the file systems. The default value is *, all cluster members. active_placement = 0 | {reason}[, {reason}[, ...]] active_placement lists the events that cfsd monitors for automatic file system relocation. (The hosting_members option determines your preference of the members to which a file system is relocated.) If you specify 0 for the active_placement attribute, cfsd does not automatically relocate the file systems in this policy under any circumstances. The default value for active_placement is 0, which prohibits all automatic relocations. You can use any of the following reasons, alone or in combination: preference cfsd automatically relocates a file system if a more preferred member, as specified in the hosting_members entry, is available. For example, if a member joining a cluster is more preferred than is the current server, cfsd relocates the file system to the new member. The order in which preference and connectivity appear on the active_placement line is important. If preference is listed first, cfsd selects more-preferred and possibly less-connected members over more-connected, less-preferred nodes. If connectivity is listed first, cfsd selects more-connected and possibly less-preferred members over more-preferred, less-connected members. connectivity The cfsd daemon automatically relocates a file system to a member that has more direct connections to the devices that the file system uses. For example, if a member loses connectivity to the devices used by a file system that it serves, and if connectivity is included in the active_placement attribute, cfsd relocates that file system to a member that does have connectivity. The order in which preference and connectivit appear on the active_placement line is important. If preference is listed first, cfsd selects more-preferred and possibly less-connected members over more-connected, less-preferred nodes. If connectivity is listed first, cfsd selects more-connected and possibly less-preferred members over more-preferred, less-connected members. memory The cfsd daemon automatically relocates some of the file systems from a member that is approaching its CFS memory usage limit. CFS memory usage is limited by the svrcfstok_max_percent kernel attribute. (See the discussion of svrcfstok_max_percent in the Cluster Administration guide.) As a member approaches its CFS memory usage limit, the kernel posts an EVM event as a warning. When such an event is posted, cfsd can attempt to free memory on that member by relocating some of the file systems that it is serving. failover If the current CFS server fails, cfsd can relocate file systems to members identified by the hosting_members option. Ordinarily, a file system would be placed on any one of the members connected to the most devices for the file system. However, if failover is included in a policy's active_placement option, cfsd provides placement hints to the kernel. The kernel uses these hints to place the file systems if and when they are failed over. The Precious and Ignore Policies The precious and ignore policies provide useful functions but they are not required; you can remove them, change their names, modify their content, and so forth. The precious policy stanza is for file systems that you do not want cfsd to relocate. (This policy inherits the default polling_schedule.) We recommend that cfsd not be allowed to relocate the clusterwide root, /usr, or /var file systems. (The member boot partitions are never considered for relocation.) We also recommend that file systems whose placements are managed by other software, such as CAA, also be assigned to this policy. The ignore policy stanza is for file systems for which cfsd should not collect statistics or attempt to relocate. This policy contains all NFS and MFS file systems that are not explicitly listed in other policies. File Systems of these types tend to be temporary and collecting statistics for them is usually not beneficial. CFS does not relocate any NFS or MFS file systems. Additional Policy Stanzas Each policy stanza can contain member assignment and relocation policy attributes for a set of file systems. There can be as many policy stanzas as needed. Attributes that are not given values in a policy inherit the values of those attributes from the default policy. If an attribute is not specified in the default policy, it has the default value listed in this section. The following attributes and values are recognized for each policy stanza: name = {policyname} Assigns a name to this policy. It can be useful for tracking which policy a file system is assigned when it is mounted. cfsd logs such assignments to syslog and references the policy by this name. The first 20 characters are recognized, additional characters are ignored. The default value for this attribute is UNNAMED. filesystems = {fs1}[, {fs2}[,...]] Lists the file systems that are in this policy. You can list any number of file systems in a filesystems line. You can specify the file system in any of the following ways: · The directory on which the file system is mounted; for example /mytest/test1 · The mounted-from name; for example /dev/disk/dsk5a, host:/mytest/test2, or my_domain#fileset · The domain name; for example my_domain# (This syntax assigns all filesets in the domain to this policy.) · The file system type specified as %type; for example %advfs, %mfs, %ufs, %nfs, %cdfs, %dvdfs If a listed file system does not exist or is not mounted, it is ignored until it is mounted, at which time the policy is applied. By default, filesystems is blank. When matching known file systems to policies, cfsd uses the following order of precedence: 1. It first tries to match a file system with the directory on which it is mounted. 2. If the mount-point directory is not listed in any policy, cfsd tries to match its mount-from name, or the domain name in the case of a domain. 3. If its mount-point directory is not listed in any policy, cfsd tries to match its file system type. 4. If its type is not assigned to any policy, the file system is assigned to the default policy. For example, assume that the file system type %nfs is listed in policy A and that the mount directory /mnt is listed in policy B. cfsd parses this situation as follows: · If an NFS file system is mounted at /foo, it is assigned to policy A. If an NFS file system is mounted at /mnt, it is assigned to policy B. · If the same file system is listed in multiple policies, for example, /mytest is listed in two policies, the first instance encountered in /etc/cfsd.conf is used and the others are ignored. A message indicating this is logged to syslog: rye cfsd[1113713]: filesystem "/mytest" is listed in multiple policies For AdvFS filesets, the determining factor is the policy to which the domain is assigned; all filesets in the domain are assigned based on the domain's policy. A domain is assigned a policy in the following manner: · If a domain is not explicitly assigned to a policy, then it is assigned to a policy in which one of its filesets is listed; for example, filesystem = my_domain#fileset This assignment is usually based on the most-recently-mounted fileset from that domain that is explicitly listed in a policy. Note The cdfs daemon considers an AdvFS domain to be an indivisible entity. Relocating a file system of type AdvFS affects not only the selected fileset, but all filesets in the same domain. The entire domain is relocated. polling_schedule = 0 | {s_days}, {s_hours}, {i_hours}:{i_mins} [:{i_secs}] polling_schedule specifies how often the cfsd daemon collects information for file systems and subsequently writes the /var/cluster/cfs/stats.member file. For each intance of polling_schedule, on scheduled days (s_days) during scheduled hours (s_hours), cfsd collects statistics every interval hours (i_hours), interval minutes (i_mins), and, optionally, interval seconds (i_secs). There can be as many polling_schedule attributes per policy as necessary. For example, you might want a different polling schedule for weekends. Specify days using 0 to 6 for Sunday to Saturday. Separate values with a dash (-) to indicate an inclusive range. To specify individual days, separate the days with a comma and enclose the entire days specification in quotes, as shown in the following example: polling_schedule = "0,6", 0-23, 01:00:00 Specify hours using 0 to 24. Separate values with a dash (-) to indicate an inclusive range. To specify individual hours, separate the hours with a comma and enclose the entire hours specification in quotes, as shown in the following example: polling_schedule = 0-6, "0,23", 01:00:00 If you specify 0, statistics collection is not performed for the file systems. The default value for polling_schedule is 0-6, 0-23, 00:15:00, which equates to any day, any hour, every 15 minutes. placement = favored The placement attribute controls how cfsd selects members to serve the file systems in the policy when none of the members specified by hosting_members attributes is available. The only supported value is favored: if none of the members specified in hosting_members is available, cfsd selects another member. hosting_members = * | {member1}[, {member2}[, ...]] The hosting_members attribute lists each cluster member that can be the CFS server for the file systems in this policy. When relocating a file system or recommending relocations, cfsd assigns a file system to one of these members. hosting_members is a restrictive list, not a preferred list; the placement attribute controls how the file systems are placed when none of the members specified by hosting_members attributes is available. The cfsd daemon treats all cluster members identified in a single hosting_members entry equally; no ordering preference is assumed by position in the list. To specify an ordering of member preference, use multiple hosting_members entries: hosting_members = member_name hosting_members = member_name hosting_members = member_name hosting_members = member_name Within a policy, cfsd gives preference to the members listed in the first hosting_members entry, followed by the members in the next hosting_members entry, and so on. If you specify an asterisk (*) as the value of a hosting_members attribute, any member of the cluster can be the CFS server for the file systems. Even though the asterisk refers to all cluster members, cfsd considers device connectivity when placing the file systems. The default value is *, all cluster members. active_placement = 0 | {reason}[, {reason}[, ...]] active_placement lists the events that cfsd monitors for automatic file system relocation. (The hosting_members option determines your preference of the members to which a file system is relocated.) If you specify 0 for the active_placement attribute, cfsd does not automatically relocate the file systems in this policy under any circumstances. The default value for active_placement is 0, which prohibits all automatic relocations. You can use any of the following reasons, alone or in combination: preference cfsd automatically relocates a file system if a more preferred member, as specified in the hosting_members entry, is available. For example, if a member joining a cluster is more preferred than is the current server, cfsd relocates the file system to the new member. The order in which preference and connectivity appear on the active_placement line is important. If preference is listed first, cfsd selects more-preferred and possibly less-connected members over more-connected, less-preferred nodes. If connectivity is listed first, cfsd selects more-connected and possibly less-preferred members over more-preferred, less-connected members. connectivity The cfsd daemon automatically relocates a file system to a member that has more direct connections to the devices that the file system uses. For example, if a member loses connectivity to the devices used by a file system that it serves, and if connectivity is included in the active_placement attribute, cfsd relocates that file system to a member that does have connectivity. The order in which preference and connectivit appear on the active_placement line is important. If preference is listed first, cfsd selects more-preferred and possibly less-connected members over more-connected, less-preferred nodes. If connectivity is listed first, cfsd selects more-connected and possibly less-preferred members over more-preferred, less-connected members. memory The cfsd daemon automatically relocates some of the file systems from a member that is approaching its CFS memory usage limit. CFS memory usage is limited by the svrcfstok_max_percent kernel attribute. (See the discussion of svrcfstok_max_percent in the Cluster Administration guide.) As a member approaches its CFS memory usage limit, the kernel posts an EVM event as a warning. When such an event is posted, cfsd can attempt to free memory on that member by relocating some of the file systems that it is serving. failover If the current CFS server fails, cfsd can relocate file systems to members identified by the hosting_members option. Ordinarily, a file system would be placed on any one of the members connected to the most devices for the file system. However, if failover is included in a policy's active_placement option, cfsd provides placement hints to the kernel. The kernel uses these hints to place the file systems if and when they are failed over. Debugging the /etc/cfsd.conf File The cfsd daemon logs status and error information to the syslog daily log file, typically /var/adm/syslog.dated/current/daemon.log. The cfsd daemon logs status messages using the name assigned to a policy in the /etc/cfsd.conf file. The following example shows the reconfiguring log entries resulting from sending a SIGHUP signal to a cfsd daemon: # tail /var/adm/syslog.dated/current/daemon.log rye cfsd[1113713]: performing filesystem analysis... rye cfsd[1113713]: filesystem analysis complete rye cfsd[1113713]: logging analysis results to "/var/cluster/cfs/analysis.log" rye cfsd[1113713]: reconfiguring rye cfsd[1113713]: cfsd is active rye cfsd[1113713]: AdvFS file domain cluster_usr# has been assigned to policy DEFAULT rye cfsd[1113713]: AdvFS file domain cluster_var# has been assigned to policy DEFAULT rye cfsd[1113713]: AdvFS file domain root1_domain# has been assigned to policy DEFAULT rye cfsd[1113713]: AdvFS file domain root2_domain# has been assigned to policy DEFAULT rye cfsd[1113713]: AdvFS file domain cluster_root# has been assigned to policy POLICY01 If you edit the /etc/cfsd.conf file and introduce a syntax error, the log file entry identifes the line on which the error occurs. (If you edit /etc/cfsd.conf, remember to send the SIGHUP signal to cause cfsd to reread it.) # kill -HUP `/sbin/init.d/bin/getpid /usr/sbin/cfsd` rye cfsd[1113713]: reconfiguring rye cfsd[1113713]: error loading configuration file "/etc/cfsd.conf": invalid or unrecognized entry (line 42, col 1)

EXAMPLES

1. The following examples sends a SIGHUP signal to cfsd, which causes it to reread the /etc/cfsd.conf configuration file. # kill -HUP `cat /var/run/cfsd.pid` 2. The following example shows a sample policy stanza: policy: name = POLICY01 filesystems = /test, /test2 polling_schedule = 1-5, 0-23, 04:00:00 placement = favored hosting_members = rye, swiss active_placement = preference, connectivity, failover The policy controls two file systems: /test1 and /test2. The policy sets all policy attributes; no attributes are inherited from the default policy. Polling is performed Monday through Friday, any hour, at 4 hour intervals. Cluster members rye and swiss can serve the file systems, with no ordering specified. In the event that neither of these members is available, cfsd can choose any member to be the CFS server. Active placement is deteremined by preference (as identified by hosting_members), connectivity, and failover. 3. The following example shows a second version of a policy stanza: policy: name = POLICY02 filesystems = /mytest, /mytest2 polling_schedule = "0,6", 0-23, 04:00:00 placement = favored # hosting_members = active_placement = preference, connectivity, failover The policy controls two file systems: /mytest1 and /mytest2. The policy does not set the hosting_members attribute; this attribute is inherited from the default policy. Polling is performed only Sunday and Saturday, any hour, at 4 hour intervals. Cluster members rye and swiss can serve the file systems, with no ordering specified. In the event that neither of these members is available, cfsd can choose any member to be the CFS server. Active placement is deteremined by preference (as identified by hosting_members), connectivity, and failover.

FILES

/sbin/init.d/cfsd Starts an instance of the cfsd daemon on each cluster member. /var/cluster/cfs/analysis.log Data analysis file created by cfsd. /etc/cfsd.conf The cfsd daemon configuration file. /usr/sbin/cfsd The CFS load monitoring daemon. /var/cluster/cfs/stats.member Member-specific binary data file.

SEE ALSO

Commands: cfsd(8)

Index Index for
Section 4
Index Alphabetical
listing for C
Top of page Top of
page