Exporting to subnets

About exporting to subnets

You can export a directory to clients on a subnet rather than to individual clients.

Valid export options for subnets

The valid export options in the /etc/exports file for exporting to subnets are as follows:

-ro=subnet_address[:subnet_address]...
-rw=subnet_address[:subnet_address]...
-root=subnet_address[:subnet_address]...

Format for IP subnet addresses

The subnet address is a dotted IP subnet address and a mask written in the following format:

dotted_ip/num_bits 

dotted_ip can be

or

The size of the subnet is specified by the number of leading bits of the netmask, num_bits.

Export to a subnet as you do to a client

You export a directory to a subnet as you do to an individual client, except that you specify a subnet address rather than a full IP address in an export option.

Example 1: root access

To export /vol/vol0/home on the filer for root access to a client named tooting and all addresses of the form 123.45.67.x with a netmask 255.255.255.0 (24 leading bits), place the following entry in the /etc/exports file:

/vol/vol0/home -root=tooting:123.45.67.0/24
Example 2: read/write access

To export /vol/vol0/home for read and write access to all addresses of the form 123.45.x.y with a 16-bit netmask (255.255.0.0), place the following entry in the /etc/exports file:

/vol/vol0/home -rw=123.45.0.0/16
Example 3: equivalent methods for exporting

The following entries in the /etc/exports file are equivalent. They export /vol/vol0/home to a client named host1, the specified subnet, and a client named host2.

/vol/vol0/home -rw=host1:123.45.67.8/24:host2
/vol/vol0/home -rw=host1:123.45.67/24:host2 

Copyright © 1999, Network Appliance, Inc. All rights reserved.

Part No. 210-02334
File: nfs8.htm
Last updated: 04/26/99 08:11:30