Scaling Namespaces and Optimizing Data Storage
Also available as:
PDF
loading table of contents...

Export ViewFs mounts using the NFS Gateway

For every ViewFs mount entry to export using the NFS Gateway, you must specify an NFS export point and mount it to a corresponding directory path on the NFS Gateway.

The file with the ViewFs mount table entries must already be created.

You can export only those ViewFs mounts that have HDFS as the underlying file system.

  1. Configure the proxy user for the NFS Gateway and the various Gateway settings.
  2. Start the following daemons to run the NFS services on the Gateway: rpcbind (or portmap), mountd, and nfsd.
  3. In the NFS Gateway node, specify an export point corresponding to each ViewFs mount that you want to export.
    Consider the following example of a ViewFs mount table entry:
      
     <property>
       <name>fs.viewfs.mounttable.ClusterX.link./home</name>
       <value>hdfs://nn1-clusterx.example.com:8020/home</value>
     </property>
     
    You can specify a corresponding NFS export point as follows:
    
    <property>
      <name>nfs.export.point</name>
      <value>/home</value>
    </property>
  4. Verify if the exported namespace can be mounted.
    showmount -e $nfs_server_ip
    Note
    Note
    The IP address of the NFS Gateway need not be the same as that of the NameNode.
  5. Mount the exported namespace to a corresponding path on the NFS Gateway.
    For the export point example in step 3, you can create a mount as follows:
    mount -t nfs -o vers=3,proto=tcp,nolock,noacl,sync nfs_server_ip:/home /mount_dir