The dsadd command is a Windows command line utility that allows users to add objects to Active Directory Domain Services (AD DS). This command is part of the Windows Server 2003 Resource Kit and is available for use in Windows Server 2008 and later versions. The dsadd command can be used to add users, groups, computers, and other objects to an AD DS domain.

Syntax of the dsadd Command

The syntax of the dsadd command is as follows:

  • dsadd

    The object parameter specifies the type of object to be added. The parameters parameter specifies the parameters to be used when creating the object. The parameters vary depending on the type of object being added.

    Options of the dsadd Command

    The dsadd command has the following options:

    • -u – Specifies the user name of the account to be added.
    • -p – Specifies the password of the account to be added.
    • -g – Specifies the group to which the account should be added.
    • -c – Specifies the computer to which the account should be added.
    • -q – Specifies the query to be used when adding the object.
    • -f – Specifies the file containing the parameters to be used when adding the object.

    Examples of the dsadd Command

    The following examples show how to use the dsadd command to add different objects to an AD DS domain.

    Example 1: Adding a User

    The following command adds a user to an AD DS domain:

    • dsadd user -u username -p password -g groupname

    In this example, the -u parameter specifies the user name of the account to be added, the -p parameter specifies the password of the account to be added, and the -g parameter specifies the group to which the account should be added.

    Example 2: Adding a Group

    The following command adds a group to an AD DS domain:

    • dsadd group -g groupname

    In this example, the -g parameter specifies the group to be added.

    Example 3: Adding a Computer

    The following command adds a computer to an AD DS domain:

    • dsadd computer -c computername

    In this example, the -c parameter specifies the computer to be added.

    Conclusion

    The dsadd command is a Windows command line utility that allows users to add objects to Active Directory Domain Services (AD DS). This command is part of the Windows Server 2003 Resource Kit and is available for use in Windows Server 2008 and later versions. The dsadd command can be used to add users, groups, computers, and other objects to an AD DS domain. The syntax of the dsadd command is as follows: dsadd . The dsadd command has several options that can be used to specify the parameters to be used when creating the object. The examples provided in this article demonstrate how to use the dsadd command to add different objects to an AD DS domain.

    Leave a Reply