-a Takes the list of path names to be exported or unexported from the /etc/exports file. If you specify pathname in the command when using the -a option, the command ignores pathname.
-i Ignores the options in the /etc/exports file. Without the -i option, the exportfs command uses the options associated with the pathname specified in /etc/exports.
-u Unexports the specified path name. If you also include the -a option, the command unexports the path names in the /etc/exports file and ignores pathname.
-v Prints each path name as it is exported or unexported.
-o option
Specifies a list of comma-separated options that describe how a file
or directory is exported. You can specify the option in one of the
following formats:
access=hostname[:hostname]...
Give mount access to each host listed. Alternatively, you can
specify a netgroup instead of a host in the list. The netgroup must
be defined in the /etc/netgroup file. Whether the hosts can mount
pathname with root access, read-and-write access, or read-only
access depends on how you use the root, rw, and ro options, as
described below.
anon=uid
If a request comes from user ID of 0 (root user ID on the client),
use uid as the effective user ID unless the client host is included
in the root option. The default value of uid is 65534. To disable
root access, set uid to 65535. To grant root access to all clients,
set uid to 0.
ro
Export the pathname read-only. If you do not specify this option,
the pathname is exported read-write.
rw=hostname[:hostname]...
Export the pathname read-only to all hosts not specified in the list
and read-write to the hosts in the list. Netgroup names are not
allowed in the list.
root=hostname[:hostname]...
Give root access only to the specified hosts. By default, no hosts
are granted root access. Netgroup names are not allowed in the
list.
When you export a file or directory using the ro, rw, or root option, you can specify that the file or directory be exported to a subnet instead of individual hosts. You cannot export to a subnet when using the access option.
Instead of specifying a host name or netgroup name in the exportfs command, specify the subnet in one of the following formats:
dotted_IP/num_bits The dotted_IP field is either an IP address or a subnet number. The num_bits field specifies the size of the subnet by the number of leading bits of the netmask.
``[ network ] subnet [ netmask ] netmask'' The subnet field is the subnet number. The netmask field is the netmask.
In UNIX, it is illegal to export a directory that has an exported ancestor in the same file system. Data ONTAP does not have this restriction. For example, you can export both the / directory and the /home directory. In determining permissions, the filer uses the longest matching prefix.
exportfs -o access=adminhost,root=adminhost /home exportfs /
The following examples show different forms of the exportfs command that export the /home directory to the 123.45.67.0 subnet with the 255.255.255.0 netmask:
exportfs -o rw=123.45.67.0/24 /home
exportfs -o rw=123.45.67/24 /home
exportfs -o rw=``network 123.45.67.0 netmask 255.255.255.0''
exportfs -o rw=``123.45.67.0 255.255.255.0''