s.n.g.cmd_group_add(Command) : class documentation

Part of samba.netcmd.group View In Hierarchy

Creates a new AD group

This command creates a new Active Directory group. The groupname specified on the command is a unique sAMAccountName.

An Active Directory group may contain user and computer accounts as well as other groups. An administrator creates a group and adds members to that group so they can be managed as a single entity. This helps to simplify security and system administration.

Groups may also be used to establish email distribution lists, using --group-type=Distribution.

Groups are located in domains in organizational units (OUs). The group's scope is a characteristic of the group that designates the extent to which the group is applied within the domain tree or forest.

The group location (OU), type (security or distribution) and scope may all be specified on the samba-tool command when the group is created.

The command may be run from the root userid or another authorized userid. The -H or --URL= option can be used to execute the command on a remote server.

Example1: samba-tool group add Group1 -H ldap://samba.samdom.example.com --description='Simple group'

Example1 adds a new group with the name Group1 added to the Users container on a remote LDAP server. The -U parameter is used to pass the userid and password of a user that exists on the remote server and is authorized to issue the command on that server. It defaults to the security type and global scope.

Example2: sudo samba-tool group add Group2 --group-type=Distribution

Example2 adds a new distribution group to the local server. The command is run under root using the sudo command.

Method run Run the command. This should be overriden by all subclasses.

Inherited from Command:

Method __init__ Undocumented
Method usage Undocumented
Method show_command_error display a command error
Method message Undocumented
Method get_logger Get a logger object.
Method _get_short_description Undocumented
Method _get_full_description Undocumented
Method _get_name Undocumented
Method _create_parser Undocumented
Method _run Undocumented
def run(self, groupname, credopts=None, sambaopts=None, versionopts=None, H=None, groupou=None, group_scope=None, group_type=None, description=None, mail_address=None, notes=None):
Run the command. This should be overriden by all subclasses.
API Documentation for Samba, generated by pydoctor at 2011-12-08 20:23:28.