logo

Manual Pages


Table of Contents

NAME

na_fpolicy - configure file policies

SYNOPSIS

fpolicy

fpolicy help [ <cmd> ]

fpolicy create <PolicyName> <PolicyType>

fpolicy destroy <PolicyName>

fpolicy disable <PolicyName>

fpolicy enable <PolicyName> [-f]

fpolicy extensions { include | exclude } { reset <Policy_Name> | set <PolicyName> <ext-list> | add <PolicyName> <ext-list> | remove <PolicyName> <ext-list> | show <Poli_cyName> }

fpolicy mon[itor] { add | remove | set } <PolicyName> [-p { cifs | nfs | cifs,nfs } ] [-f] <op-spec>

fpolicy options <PolicyName> [required [ on | off ] | secondary_servers [ <server-list> ]]

fpolicy servers [stop <PolicyName> <server-IP-address> show <PolicyName> ]

fpolicy show <PolicyName>

fpolicy vol[ume] { inc[lude] | exc[lude] } { add <Policy_Name> <vol-spec> | remove <PolicyName> <vol-spec> | set <PolicyName> <vol-spec> | reset <PolicyName> | show <Poli_cyName> | eval <PolicyName> }

DESCRIPTION

The fpolicy command enables control and configuration of file policies.

USAGE

fpolicy
Displays FPolicy settings and provides summary information about policies.

fpolicy help [ <cmd> ]
Displays information about specific commands available in the FPolicy subsystem of the filer. A list of commands, or syntax for a specific command, can be obtained.

fpolicy create <PolicyName> <PolicyType> Creates a new policy. Policy names must be unique. The only file policy type supported is "screen" (file screening).

fpolicy destroy <PolicyName>
Destroys an existing policy.

fpolicy disable <PolicyName>
Disables a policy.

fpolicy enable <PolicyName> [-f]
Enables a policy. The -f force flag forces the policy to be enabled even if there are no servers available to enforce the policy.

fpolicy extensions { include | exclude } { reset <Policy_Name> | set <PolicyName> <ext-list> | add <PolicyName> <ext-list> | remove <PolicyName> <ext-list> | show <Poli_cyName> }
<ext-list> is a comma-separated list of three-letter file extensions. The include list determines if a given file should be screened. The exclude list determines if a given file should not be screened. If an extension is listed on both the exclude and the include list, files with that extension are not screened. If an extension is not listed on either the include list or the exclude list, files with that extension are not screened. The character ? is a wild card. It matches any single character or no character. For example, putting C?? into the extension list would cause the filer to screen the files ABC.C, ABC.CPP, ABC.C++ and so on.

fpolicy extensions { include | exclude } show <PolicyName> Displays the current file extension list.

fpolicy extensions { include | exclude } reset <Policy_Name> Restores the file extension list to a default list.

fpolicy extensions { include | exclude } set <PolicyName> <ext-list>
Specifies a new extension list which replaces the current list.

fpolicy extensions { include | exclude } add <PolicyName> <ext-list>
Adds new entries to the current file extension list.

fpolicy extensions { include | exclude } remove <Policy_Name> <ext-list>
Removes entries from the current file extension list.

fpolicy mon[itor] { add | remove | set } <PolicyName> [-p { cifs | nfs | cifs,nfs } ] [-f] <op-spec> Typically the list of operations monitored by a file policy is set by an FPolicy server for the policy. However, the list of operations can be configured with the fpolicy monitor command. Note that if an FPolicy server sets the list after this command is entered, the FPolicy server will override the effect of this command. Operations may be added or removed from an existing list of operations, or the existing list may be discarded and set to a new list. Note that some FPolicy servers may not function correctly if their set of designated operations is changed. For example, an FPolicy server may wish to match file opens with file closes and malfunction if it stops receiving notifications of files that are closed. By default all protocols are selected. A subset of protocols can be chosen by providing a comma-separated list following the -p flag. The -f force flag causes the command to be executed even if there are no servers available to enforce the policy. <op-spec> is a comma-separated list of operations for which the policy will receive notifications. Supported values are all, none, close, create, cre_ate_dir, delete, delete_dir, getattr, link, lookup, open, read, rename, rename_dir, setattr, symlink, write. Note: Selecting read or write is rarely desirable. Notification for operations which occur frequently have a detrimental effect on performance.

fpolicy options <PolicyName>
Displays the current values of the file policy options.

fpolicy options <PolicyName> required [ on | off ] Displays the current setting for the required option. If set to "on", user requests are denied if a file policy server is not available to implement the policy. If set to "off", user requests are allowed when it is not possible to apply the policy to the file because no file policy server is available.

fpolicy options <PolicyName> secondary_servers [ <server_list> ]
Displays the current setting for the secondary_servers option. If a comma-separated list of IP addresses is provided, the current list is replaced by the new list. The filer avoids the use of secondary servers to enforce file policies unless there are no primary servers available.

fpolicy servers [ show <PolicyName> | stop <PolicyName> <server-IP-address>
Displays a list of FPolicy servers which have offered to apply file policies for the filer, or terminates the connection to a specified server.

fpolicy show <PolicyName>
Displays status for <PolicyName>

fpolicy vol[ume] { inc[lude] | exc[lude] } { add <Policy_Name> <vol-spec> | remove <PolicyName> <vol-spec> | set <PolicyName> <vol-spec> | reset <PolicyName> | show <Poli_cyName> | eval <PolicyName> }
<vol-spec> is a comma-separated list of filer volumes. Regular expressions including wildcard characters ? and * are also supported. The include volume list specifies which volumes the policy applies to. The exclude volume list specifies which volumes are not controlled by the policy. When an exclude list is specified any volumes not excluded are controlled by the policy. If both lists are specified for a policy the exclude list takes precedence and the include list is ignored. If neither volume list is set, the policy is applied to all volumes.

fpolicy vol[ume] { inc[lude] | exc[lude] } add <Policy_Name> <vol-spec>
Adds new entries to the current volume list.

fpolicy vol[ume] { inc[lude] | exc[lude] } remove <Policy_Name> <vol-spec>
Removes entries from the current volume list.

fpolicy vol[ume] { inc[lude] | exc[lude] } set <Policy_Name> <vol-spec>
Specifies a new volume list which replaces the current list.

fpolicy vol[ume] { inc[lude] | exc[lude] } reset <Policy_Name> Resets the volume list to an empty list.

fpolicy vol[ume] { inc[lude] | exc[lude] } show <Policy_Name> Displays the current volume list.

fpolicy vol[ume] { inc[lude] | exc[lude] } eval <Policy_Name> Prints the list of volumes that this policy applies to.

VFILER CONSIDERATIONS

When run from a vFiler context, (e.g. via the vfiler run command), fpolicy operates on the affected vFiler.

SEE ALSO

na_vfiler(1)


Table of Contents