Exporting Non-LFS Partitions

This section describes the steps involved in exporting a non-LFS partition; after it is exported, a non-LFS partition can be referred to as a non-LFS aggregate. Before exporting a non-LFS partition to the DCE namespace, the prerequisites described in Preparing for Exporting must be met: the necessary CDS, Security Service, RPC, and DFS server processes must be running; an RPC binding must exist for the DCE path name of the machine; a DFS server principal and account must exist for the machine; a server entry must exist for the machine; and a keytab file and a key must exist on the machine. You must also have created and locally mounted the partition (using the newfs and mount commands or their equivalents), and you must have listed the partition's name in the local fstab file (or its equivalent).

Before exporting a non-LFS partition, make sure that no users have files open on the partition. DFS cannot effectively synchronize file access between users who opened files from a non-LFS partition before the partition was exported and users who open files from the partition after the partition is exported because only the latter have tokens.

To export a non-LFS partition, do the following:

1. Verify that you have the necessary privileges. You must be included in the admin.fl file on each Fileset Database machine or own the server entry for the machine from which the partition is to be exported. If necessary, issue the bos lsadmin command to verify the members of an administrative list.

2. Verify that you have the w (write), x (execute), and i (insert) ACL permissions for the directory in which the mount point for the fileset is to be created. If necessary, issue the dcecp acl show command to check the ACL permissions for the directory. Note that you need to have the w and x permissions if the directory is in a non-LFS fileset.

3. Provide a name for the fileset (non-LFS file system) on the partition to be exported and register the fileset in the FLDB with the fts crfldbentry command. The number specified with the -aggrid option is also used as the partition's aggregate ID in the dfstab file; it must not already be in use in the dfstab file.

The FL Server allocates a unique fileset ID number for the partition's lone non-LFS fileset. The fts crfldbentry command returns this ID number, along with two additional ID numbers allocated for read-only and backup versions of the fileset, even though a non-LFS fileset cannot have these versions. Use the read/write ID number returned by the command as the fileset ID in the dfstab file.

$ fts crfldbentry -ftname name -server machine -aggrid ID

The -ftname name option is the complete name to be associated with the fileset being registered. The name can contain no more than 102 characters, and it must contain at least one alphabetic character or an _ (underscore). (See Fileset Names for more information on fileset naming conventions.)

The -aggrid ID option is a positive integer to serve as the aggregate ID for the partition to be exported. The number must not already be in use in the dfstab file on the machine where the partition resides.

4. Log in as root on the machine from which the partition is to be exported.

5. Use a text editor to edit the dfstab file to include an entry for the non-LFS partition to be exported. The following fields appear for each entry in the file, in the order listed. Each field must be separated by a minimum of one space or tab; each entry must be on a separate line. Note that because a non-LFS partition can contain only a single fileset, you include the fileset ID number with the partition's entry in the dfstab file.

· Device Name: The block device name of the partition; for example, /dev/lv02.

· Aggregate Name: The name to be associated with the exported partition. The aggregate name of a non-LFS partition must match the name of its local mount point (for example, /usr). An aggregate name can contain any characters, but it can be no longer than 31 characters, and it must be different from any other aggregate name in the file. Aggregate names cannot be abbreviated, so you should choose a short, explicit name.

· File System Type: The identifier for the file system type of the partition. For non-LFS file systems, this must be ufs. It must be in lowercase letters.

· Aggregate ID: A positive integer to serve as the aggregate ID of the exported partition. The integer must match the aggregate ID specified with the -aggrid option of the fts crfldbentry command, and it must be different from any other aggregate ID in the dfstab file. (If the ID is changed, fileset operations on the partition's fileset will fail.)

· Fileset ID: The unique fileset ID number returned by the fts crfldbentry command for the fileset on the partition (for example, 0,,18756). Use the read/write ID number, not the read-only or backup ID number, returned by the command as the value for this field.

The following entry from a dfstab file is for a non-LFS partition:

/dev/lv02 /usr ufs 1 0,,18756

6. Issue the dfsexport command to export the partition to the DCE namespace. Before exporting, this command reads the dfstab file to determine which aggregates and partitions are available to be exported. Omit all of the command's options to list the aggregates and partitions currently exported from the local disk to the DCE namespace.

# dfsexport [{-all | -aggregate name}] [-type name]

The -all option specifies that all aggregates and partitions listed in the dfstab file are to be exported. Use the -all option with the -type option to export only DCE LFS aggregates or only non-LFS partitions. Use this option or use the -aggregate option.

The -aggregate name option specifies the device name or aggregate name of a specific aggregate or partition. These names are specified in the first and second fields of the entry for the aggregate or partition in the dfstab file. Use the -aggregate option or use the -all option.

The -type name option is the file system type to be exported. Specify lfs to export only DCE LFS aggregates; specify ufs to export only non-LFS partitions. Use the -type option only with the -all option (it is ignored if it is used without -all); omit -type and use -all to export all aggregates and partitions.

7. Log out as root from the machine to return to your authenticated DCE identity.

8. Enter the fts crmount command to create a mount point in the file system for the new non-LFS fileset. This makes the contents of the fileset visible to other users.

$ fts crmount -dir directory_name -fileset {name | ID}

The -dir directory_name option is the location for the root directory of the fileset; the specified location must not already exist. However, the parent directory of the mount point must exist in the DCE namespace. Include a complete path name unless you want to mount the fileset in the working directory.