About importing user or group mappings from a file or an NIS LDAP server

File Services Administration Guide for Hitachi NAS Platform

Version
14.7.x
14.6.x
Audience
anonymous
Part Number
MK-92HNAS006-29

You can specify user or group details by importing them from a file.

NFSv4 user and group names are distinct from the UNIX name associated with UNIX UIDs and GIDs. However, in many environments a user/group's NFSv4 name can be derived from their UNIX name by appending the NFSv4 domain. The storage server can perform this conversion automatically, based on the settings specified on the Domain Mappings page of NAS Manager or through the CLI command domain-mappings-add.

To display the Domain Mappings page, navigate to Home > File Services, select User Mapping or Group Mapping, and select the View Domain Mapping link. For more information on the domain-mappings-add command, refer to the Command Line Reference.

A UNIX /etc/passwd file can be imported, providing the server with a mapping of user name to UID. The /etc/groups file should also be imported to provide the server with a mapping of Group name to GID.

The server will ignore other fields from the passwd file, such as the encrypted password and the user's home directory. Users or Groups configured by importing from the /etc/passwd file will then appear in the appropriate list on the User Mappings page or the Group Mappings page.

Choose one of the three following formats and use it consistently throughout the file:
  • NFSv2/3 user/group data only. The source of the user data can be a UNIX password file, such as /etc/passwd.

    When using Network Information Service (NIS), use the following command to create the file:

    ypcat passwd > /tmp/x.pwd

    The resulting file has the following format:

    john:x:544:511:John Brown:/home/john:/bin/bash

    keith:x:545:517:Keith Black:/home/keith:/bin/bash

    miles:x:546:504:Miles Pink:/home/miles:/bin/bash

    carla:x:548:504:Carla Blue:/home/carla:/bin/bash

  • NFSv2/3-to-Windows user/group mappings only. Create a file with entries in the following format:

    UNIXuser="NT User", "NT Domain"

    with the following syntax rules:

    • NT domain is optional.
    • NFS user names cannot contain spaces.
    • NT names must be enclosed in quotation marks.
    • If the domain name is omitted, the server domain is assumed. If the empty domain name is required, it must be specified like this:

      users="Everyone", ""

      where the Everyone user is the only common account with an empty domain name.

  • Both NFSv2/3 user/group data and NFSv2/3-to-Windows user mappings. Create a file with entries in the following format:

    UNIXuser:UNIXid="NT User", "NT Domain"

    with the same rules for NFS and NT names as for the NFSv2/3-to-Windows user mapping.

    The resulting file has entries in the following format:

    john:544="john", "Domain1"

    keith:545="keith", "Domain1"

    miles:546="miles", "Domain1"

    carla:548="carla", "Domain1"