Microsoft KB Archive/891762

= How to change the domain of a migrated user or group in Windows Services for UNIX 3.5 =

Article ID: 891762

Article Last Modified on 2/2/2005

-

APPLIES TO


 * Microsoft Windows Services for UNIX 3.5

-





INTRODUCTION
This article describes how to change the domain of a migrated user or group in Microsoft Windows Services for UNIX 3.5 by using command-line commands.



MORE INFORMATION
To modify the domain of a user or a group, you must follow these steps:
 * 1) Save the user data.
 * 2) Remove the user by using the nismap del command.
 * 3) Migrate the user to the new domain by using the nismap command or by using the nis2ad command.

To change the domain of a user or group, follow these steps:  Run the following ypmatch command to retrieve the data for the particular user or group:

ypmatch -d  -k

Note In this command, replace the placeholders as follows:  Replace  with the name of the original domain. Replace  with the name of the user or group that you want to move to the new domain. Replace  with passwd if you run this command against a user name or replace   with group if you run this command against a group name.  Save this information in a temporary file that is named passwd or group, depending on whether you run this command against a user name or a group name. Remove the user or group by using the following nismap del command:

nismap del -a  -k

</li> Add this user or group to the new domain by using the following nis2ad command:

nis2ad -a  -y   -m -d

Note In this command, replace the placeholders as follows:  Replace  with the name of the new domain.</li> Replace  with the path of the directory where you saved the temporary file in step 2.</li> Replace  with the passwd if you run this command against a user name or replace   with group if you run this command against a group name.</li></ul>

Note You can also add this user to the new domain by using the nismap add command.</li></ol>

Additional information for multiple users or groups
If you have to change the domain for multiple users or groups, follow these steps:
 * 1) Run the ypcat command to obtain a list of all the users or groups. Use the -k option to display the map keys. In this scenario, the key is the user name or the group name, depending on whether you are dealing with a passwd map or a group map.

Note The key is required for the nismap del command that you run in step 3.
 * 1) Save the keys and the data for all the users or groups.
 * 2) Run the nismap del command for each key that you saved in step 2.
 * 3) Run the nis2ad command or run multiple nismap add commands to add the users or groups to the new domain.

For additional information about the options for the ypcat command, type man ypcat, and then press ENTER in a UNIX shell. For additional information about the nismap command, type man nismap, and then press ENTER in a UNIX shell.

For additional information about the Windows command-line tools for Windows Services for Unix 3.5, see Windows Services for Unix 3.5 Help.

Additional query words: SFU Interix Yellow

Keywords: kbhowto kbinfo KB891762

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.