The cfset(1M) command can be used to set certain tunable parameters in the CF driver. The values are stored in /etc/default/cluster.config. The cfset(1M) command can be used to retrieve and display the values from the kernel or the file as follows:
A new file under /etc/default called cluster.config is created.
The values defined in /etc/default/cluster.config can be set or changed using the GUI (for cfcp and cfsh during initial cluster configuration) or by using a text editor.
The file consists of the following tupple entries, Name and Value:
Name:
This is the name of a CF configuration parameter. It must be the first token in a line.
Maximum length for Name is 31 bytes. The name must be unique.
Duplicate names will be detected and reported as an error when the entries are applied by cfconfig -l and by the cfset(1M) command (cfset -r and -f option). This will log invalid and duplicate entries to /var/log/messages.
cfset(1M) can change the Value for the Name in the kernel if the driver is already loaded and running.
Value:
This represents the value to be assigned to the CF parameter. It is a string, enclosed in double quotes or single quotes. Maximum length for Value is 4 kilobytes (4K) characters.
New lines are not allowed inside the quotes.
A new line or white space marks the close of a token.
However, if double quotes or single quotes start the beginning of the line, cfset treats the line as a continuation value from the previous value.
The maximum number of Name/Value pair entries is 100.
The hash sign (#) is used for the comment characters. It must be the first character in the line, and it causes the entries on that line to be ignored.
Single quotes can be enclosed in double quotes or vice versa.
cfset(1M) options are as follows:
cfset [ -r | -f | -a | -o name | -g name | -h ]
Note
Refer to the Chapter "Chapter 9 Manual pages" and to the cfset(1M) manual page for more details on options.
The tuneables are as follows:
CLUSTER_TIMEOUT (refer to "Example 1 Use cfset(1M) to tune timeout as follows:" that follows)
CFSH (refer to the following Section "1.1.3 CF security")
CFCP (refer to the following Section "1.1.3 CF security")
CLUSTER_IP_TTL (refer to "Example 2 To set tuneables to non-default values:" that follows)
This parameter becomes enabled when using CF over IP.
Tunable Description: This is the value of the TTL field in the IP-header for all CF packets.
Default value: 64
Valid values: 1-255
CLUSTER_IP_CTRL_TOS (refer to "Example 2 To set tuneables to non-default values:" that follows)
This parameter becomes enabled when using CF over IP.
Tunable Description: This is the value of the TOS 8-bit field in the IP-header for all CF control packets. This includes cluster heartbeat packets. The default value shown below is a best-fit default which sets the 6-bit DSCP field to binary 100010. This is a DSCP forwarding 4F AF class (compatible with older IP precedence) and specifies the lowest AF drop precedence (least likely to be dropped when congestion is encountered).
Default value: 0x88 (136)
Valid values: 0-255
CLUSTER_IP_DATA_TOS (refer to "Example 2 To set tuneables to non-default values:" that follows)
This parameter becomes enabled when using CF over IP.
Tunable Description: This is the value of the TOS 8-bit field in the IP-header for all CF data packets (non-control packets). The default value shown below is a best-fit default which sets the 6-bit DSCP field to binary 001010. This is a DSCP forwarding 1F AF class (compatible with older IP precedence) and specifies the lowest AF drop precedence (least likely to be dropped when congestion is encountered).
Default value: 0x28 (40)
Valid values: 0-255
After any change to cluster.config, run the cfset(1M) command as follows:
# cfset -r
Example
CLUSTER_TIMEOUT "30"
This changes the default 10-second timeout to 30 seconds. The minimum value is 1 second. There is no maximum. It is strongly recommended that you use the same value on all cluster nodes.
CLUSTER_TIMEOUT represents the number of seconds that one cluster node waits for a heartbeat response from another cluster node. Once CLUSTER_TIMEOUT seconds has passed, the non-responding node is declared to be in the LEFTCLUSTER state. The default value for CLUSTER_TIMEOUT is 10, which experience indicates is reasonable for most PRIMECLUSTER installations. We allow this value to be tuned for exceptional situations, such as networks which may experience long switching delays.
Edit the /etc/default/cluster.config file and add entries for each tunable:
CLUSTER_IP_TTL "64" CLUSTER_IP_CTRL_TOS "0x88" CLUSTER_IP_DATA_TOS "0x28"
Run cfset -f to verify settings in file.
Run cfset -r to load new values to CF.
Run cfset -a to verify values in kernel.