Difference between revisions of "AppSuite:Group management"
(Created page with "<div class="sect1" lang="en-EN"><div class="titlepage"><div><div><h2 class="title" style="clear: both">creategroup</h2></div></div></div><p><strong class="userinput"><code>cre...") |
|||
(2 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
+ | == creategroup == | ||
+ | |||
+ | '''<code>creategroup</code>''' is the tool to create a new group in a given context. Groups are created with no group members when no userid(s) are supplied with the parameter -a. | ||
+ | |||
+ | === Parameters === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -h, --help | ||
+ | |Prints a help text | ||
+ | |- | ||
+ | | --environment | ||
+ | |Show info about commandline environment | ||
+ | |- | ||
+ | | --nonl | ||
+ | |Remove all newlines (\n) from output | ||
+ | |- | ||
+ | | --responsetimeout <integer> | ||
+ | |response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0''' | ||
+ | |- | ||
+ | | -c, --contextid <integer> | ||
+ | |The id of the contex | ||
+ | |- | ||
+ | | -n, --name <string> | ||
+ | |The group name | ||
+ | |- | ||
+ | | -d, --displayname <stringe> | ||
+ | |The displayname for the group | ||
+ | |- | ||
+ | | -a, --addmembers <userid(s)> | ||
+ | |List of members to add to the group separated by ", " | ||
+ | |} | ||
+ | |||
+ | === Extra parameters when authentication is enabled === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -A, --adminuser <string> | ||
+ | |Context Admin user name | ||
+ | |- | ||
+ | | -P, --adminpass <string> | ||
+ | |Context Admin password | ||
+ | |} | ||
+ | |||
+ | === Return value === | ||
+ | |||
+ | <code>0</code> on success | ||
+ | |||
+ | <code>>0</code> on failure | ||
+ | |||
+ | === Mandatory parameters === | ||
+ | |||
+ | '''<code>contextid {adminuser adminpass} name displayname</code>''' | ||
+ | |||
+ | === Command output === | ||
+ | |||
+ | On success: | ||
+ | |||
+ | <code>group <groupid> in context <contextid> created</code> | ||
+ | |||
+ | On failure: | ||
+ | |||
+ | <code>group in context <contextid> could not be created: <reason from server></code> | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | <code>root@oxhe~# </code>'''<code>/opt/open-xchange/sbin/creategroup -c 123 -n "sales" -d "Sales Department"</code>''' | ||
+ | |||
+ | <code>group 4 in context 123 created</code> | ||
+ | |||
+ | |||
+ | == deletegroup == | ||
+ | |||
+ | '''<code>deletegroup</code>''' is the tool to delete a group in a given context. There is no need to remove the group members before. | ||
+ | |||
+ | === Parameters === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -h, --help | ||
+ | |Prints a help text | ||
+ | |- | ||
+ | | --environment | ||
+ | |Show info about commandline environment | ||
+ | |- | ||
+ | | --nonl | ||
+ | |Remove all newlines (\n) from output | ||
+ | |- | ||
+ | | --responsetimeout <integer> | ||
+ | |response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0''' | ||
+ | |- | ||
+ | | -i, --groupid <groupid> | ||
+ | |The id or the name of the group | ||
+ | |- | ||
+ | | -n, --name <name> | ||
+ | |The group name | ||
+ | |} | ||
+ | === Extra parameters when authentication is enabled === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -A, --adminuser <string> | ||
+ | |Context Admin user name | ||
+ | |- | ||
+ | | -P, --adminpass <string> | ||
+ | |Context Admin password | ||
+ | |} | ||
+ | === Return value === | ||
+ | |||
+ | <code>0</code> on success | ||
+ | |||
+ | <code>>0</code> on failure | ||
+ | |||
+ | === Mandatory parameters === | ||
+ | |||
+ | '''<code>contextid {adminuser adminpass} (groupid or name)</code>''' | ||
+ | |||
+ | === Command output === | ||
+ | |||
+ | On success: | ||
+ | |||
+ | <code>group <groupid> in context <contextid> deleted</code> | ||
+ | |||
+ | On failure: | ||
+ | |||
+ | <code>group <groupid> in context <contextid> could not be deleted: <reason from server></code> | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | <code>root@oxhe~# </code>'''<code>/opt/open-xchange/sbin/deletegroup -c 123 -n sales</code>''' | ||
+ | |||
+ | <code>group 4 in context 123 deleted</code> | ||
+ | |||
+ | |||
+ | == listgroup == | ||
+ | |||
+ | '''<code>listgroup</code>''' is the tool to list and search for groups in a given context | ||
+ | |||
+ | === Parameters === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -h, --help | ||
+ | |Prints a help text | ||
+ | |- | ||
+ | | --environment | ||
+ | |Show info about commandline environment | ||
+ | |- | ||
+ | | --nonl | ||
+ | |Remove all newlines (\n) from output | ||
+ | |- | ||
+ | | --responsetimeout <integer> | ||
+ | |response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0''' | ||
+ | |- | ||
+ | | -c, --contextid <integer> | ||
+ | |The id of the context | ||
+ | |- | ||
+ | | -s, --searchpattern <string> | ||
+ | |Search/List pattern, default “*” | ||
+ | |- | ||
+ | | --csv | ||
+ | |command output as csv | ||
+ | |} | ||
+ | === Extra parameters when authentication is enabled === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -A, --adminuser <string> | ||
+ | |Context Admin user name | ||
+ | |- | ||
+ | | -P, --adminpass <string> | ||
+ | |Context Admin password | ||
+ | |} | ||
+ | === Return value === | ||
+ | |||
+ | <code>0</code> on success | ||
+ | |||
+ | <code>>0</code> on failure | ||
+ | |||
+ | === Mandatory parameters === | ||
+ | |||
+ | '''<code>contextid {adminuser adminpass}</code>''' | ||
+ | |||
+ | === Command output === | ||
+ | |||
+ | Standard output: | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | |id | ||
+ | |name | ||
+ | |displayname | ||
+ | |members | ||
+ | | | ||
+ | |- | ||
+ | |3 | ||
+ | |users | ||
+ | |"all users" | ||
+ | |"2, 4, 5, 8" | ||
+ | | | ||
+ | |} | ||
+ | csv output: | ||
+ | |||
+ | <code>id, name, displayname, email, members</code> | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | <code>root@oxhe~# </code>'''<code>listgroup -c 123</code>''' | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | |id | ||
+ | |name | ||
+ | |displayname | ||
+ | |members | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | |- | ||
+ | |3 | ||
+ | |users | ||
+ | |"all users" | ||
+ | |"2, 4, 5, 8" | ||
+ | | | ||
+ | | | ||
+ | | | ||
+ | |} | ||
+ | |||
+ | == changegroup == | ||
+ | |||
+ | '''<code>changegroup</code>''' is the tool to change a group in a given context. | ||
+ | |||
+ | === Parameters === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -h, --help | ||
+ | |Prints a help text | ||
+ | |- | ||
+ | | --environment | ||
+ | |Show info about commandline environment | ||
+ | |- | ||
+ | | --nonl | ||
+ | |Remove all newlines (\n) from output | ||
+ | |- | ||
+ | | --responsetimeout <integer> | ||
+ | |response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0''' | ||
+ | |- | ||
+ | | -c, --contextid <contextid> | ||
+ | |The id of the context | ||
+ | |- | ||
+ | | -i, --groupid <groupid> | ||
+ | |The id or the name of the group | ||
+ | |- | ||
+ | | -n, --name <string> | ||
+ | |The group name | ||
+ | |- | ||
+ | | -d, --displayname <string> | ||
+ | |The displayname for the Group | ||
+ | |- | ||
+ | | -a, --addmembers <userid(s)> | ||
+ | |List of members to add to group, separated by ", " | ||
+ | |- | ||
+ | | -r, --removemembers <userid(s)> | ||
+ | |List of members to be removed from group, separated by ", " | ||
+ | |} | ||
+ | |||
+ | === Extra parameters when authentication is enabled === | ||
+ | |||
+ | {| border="1" | ||
+ | |- | ||
+ | | -A, --adminuser <string> | ||
+ | |Context Admin user name | ||
+ | |- | ||
+ | | -P, --adminpass <string> | ||
+ | |Context Admin password | ||
+ | |} | ||
+ | |||
+ | === Return value === | ||
+ | |||
+ | <code>0</code> on success | ||
+ | |||
+ | <code>>0</code> on failure | ||
+ | |||
+ | === Mandatory parameters === | ||
+ | |||
+ | '''<code>contextid {adminuser adminpass} (groupid or name) and at minimum one parameter for an attribute to change</code>''' | ||
+ | |||
+ | === Command output === | ||
+ | |||
+ | On success: | ||
+ | |||
+ | <code>group <groupid> in context <contextid> changed</code> | ||
+ | |||
+ | On failure: | ||
+ | |||
+ | <code>group <groupid> in context <contextid> could not be changed: <reason from server></code> | ||
+ | |||
+ | === Example === | ||
+ | |||
+ | <code>root@oxhe~# </code>'''<code>/opt/open-xchange/sbin/changegroup -c 123 -i 5 -d "new groupname"</code>''' | ||
+ | |||
+ | <code>group 5 in context 123 changed</code> | ||
+ | |||
+ | |||
+ | [[Category: Administrator]] | ||
− | |||
[[Category: AppSuite]] | [[Category: AppSuite]] | ||
[[Category: AdminGuide]] | [[Category: AdminGuide]] | ||
+ | [[Category: CommandLineTools]] |
Latest revision as of 13:42, 23 April 2015
creategroup
creategroup
is the tool to create a new group in a given context. Groups are created with no group members when no userid(s) are supplied with the parameter -a.
Parameters
-h, --help | Prints a help text |
--environment | Show info about commandline environment |
--nonl | Remove all newlines (\n) from output |
--responsetimeout <integer> | response timeout in seconds for reading response from the backend (default 0s; infinite) Available with v7.8.0 |
-c, --contextid <integer> | The id of the contex |
-n, --name <string> | The group name |
-d, --displayname <stringe> | The displayname for the group |
-a, --addmembers <userid(s)> | List of members to add to the group separated by ", " |
Extra parameters when authentication is enabled
-A, --adminuser <string> | Context Admin user name |
-P, --adminpass <string> | Context Admin password |
Return value
0
on success
>0
on failure
Mandatory parameters
contextid {adminuser adminpass} name displayname
Command output
On success:
group <groupid> in context <contextid> created
On failure:
group in context <contextid> could not be created: <reason from server>
Example
root@oxhe~#
/opt/open-xchange/sbin/creategroup -c 123 -n "sales" -d "Sales Department"
group 4 in context 123 created
deletegroup
deletegroup
is the tool to delete a group in a given context. There is no need to remove the group members before.
Parameters
-h, --help | Prints a help text |
--environment | Show info about commandline environment |
--nonl | Remove all newlines (\n) from output |
--responsetimeout <integer> | response timeout in seconds for reading response from the backend (default 0s; infinite) Available with v7.8.0 |
-i, --groupid <groupid> | The id or the name of the group |
-n, --name <name> | The group name |
Extra parameters when authentication is enabled
-A, --adminuser <string> | Context Admin user name |
-P, --adminpass <string> | Context Admin password |
Return value
0
on success
>0
on failure
Mandatory parameters
contextid {adminuser adminpass} (groupid or name)
Command output
On success:
group <groupid> in context <contextid> deleted
On failure:
group <groupid> in context <contextid> could not be deleted: <reason from server>
Example
root@oxhe~#
/opt/open-xchange/sbin/deletegroup -c 123 -n sales
group 4 in context 123 deleted
listgroup
listgroup
is the tool to list and search for groups in a given context
Parameters
-h, --help | Prints a help text |
--environment | Show info about commandline environment |
--nonl | Remove all newlines (\n) from output |
--responsetimeout <integer> | response timeout in seconds for reading response from the backend (default 0s; infinite) Available with v7.8.0 |
-c, --contextid <integer> | The id of the context |
-s, --searchpattern <string> | Search/List pattern, default “*” |
--csv | command output as csv |
Extra parameters when authentication is enabled
-A, --adminuser <string> | Context Admin user name |
-P, --adminpass <string> | Context Admin password |
Return value
0
on success
>0
on failure
Mandatory parameters
contextid {adminuser adminpass}
Command output
Standard output:
id | name | displayname | members | |
3 | users | "all users" | "2, 4, 5, 8" |
csv output:
id, name, displayname, email, members
Example
root@oxhe~#
listgroup -c 123
id | name | displayname | members | |||
3 | users | "all users" | "2, 4, 5, 8" |
changegroup
changegroup
is the tool to change a group in a given context.
Parameters
-h, --help | Prints a help text |
--environment | Show info about commandline environment |
--nonl | Remove all newlines (\n) from output |
--responsetimeout <integer> | response timeout in seconds for reading response from the backend (default 0s; infinite) Available with v7.8.0 |
-c, --contextid <contextid> | The id of the context |
-i, --groupid <groupid> | The id or the name of the group |
-n, --name <string> | The group name |
-d, --displayname <string> | The displayname for the Group |
-a, --addmembers <userid(s)> | List of members to add to group, separated by ", " |
-r, --removemembers <userid(s)> | List of members to be removed from group, separated by ", " |
Extra parameters when authentication is enabled
-A, --adminuser <string> | Context Admin user name |
-P, --adminpass <string> | Context Admin password |
Return value
0
on success
>0
on failure
Mandatory parameters
contextid {adminuser adminpass} (groupid or name) and at minimum one parameter for an attribute to change
Command output
On success:
group <groupid> in context <contextid> changed
On failure:
group <groupid> in context <contextid> could not be changed: <reason from server>
Example
root@oxhe~#
/opt/open-xchange/sbin/changegroup -c 123 -i 5 -d "new groupname"
group 5 in context 123 changed