AppSuite:Group management: Difference between revisions

From Open-Xchange
(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...")
 
No edit summary
 
(2 intermediate revisions by one other user not shown)
Line 1: Line 1:
<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>creategroup</code></strong> 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.</p><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Parameters</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-h,--help</td><td align="left">Prints a help text</td></tr><tr><td align="left">    --environment</td><td align="left">Show info about commandline environment</td></tr><tr><td align="left">    --nonl</td><td align="left">Remove all newlines (\n) from output</td></tr><tr><td align="left">-c,--contextid &lt;integer&gt;</td><td align="left">The id of the contex</td></tr><tr><td align="left">-n,--name &lt;string&gt;</td><td align="left">The group name</td></tr><tr><td align="left">-d,--displayname &lt;stringe&gt;</td><td align="left">The displayname for the group</td></tr><tr><td align="left">-a,--addmembers &lt;userid(s)&gt;</td><td align="left">List of members to add to the group separated by ","</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Extra parameters when authentication is enabled</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-A,--adminuser &lt;string&gt;</td><td align="left">Context Admin user name</td></tr><tr><td align="left">-P,--adminpass &lt;string&gt;</td><td align="left">Context Admin password</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Return value</h3></div></div></div><p><code class="computeroutput">0</code> on success</p><p><code class="computeroutput">&gt;0</code> on failure</p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Mandatory parameters</h3></div></div></div><p><strong class="userinput"><code>contextid {adminuser adminpass} name displayname</code></strong></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Command output</h3></div></div></div><p>On success:</p><p><code class="computeroutput">group &lt;groupid&gt; in context &lt;contextid&gt; created</code></p><p>On failure:</p><p><code class="computeroutput">group in context &lt;contextid&gt; could not be created: &lt;reason from server&gt;</code></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Example</h3></div></div></div><p><code class="computeroutput">root@oxhe~# </code><strong class="userinput"><code>/opt/open-xchange/sbin/creategroup -c 123 -n "sales" -d "Sales Department"</code></strong></p><p><code class="computeroutput">group 4 in context 123 created</code></p></div></div>
<div class="sect1" lang="en-EN"><div class="titlepage"><div><div><h2 class="title" style="clear: both">deletegroup</h2></div></div></div><p><strong class="userinput"><code>deletegroup</code></strong> is the tool to delete a group in a given context.
There is no need to remove the group members before.</p><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Parameters</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-h,--help</td><td align="left">Prints a help text</td></tr><tr><td align="left">    --environment</td><td align="left">Show info about commandline environment</td></tr><tr><td align="left">    --nonl</td><td align="left">Remove all newlines (\n) from output</td></tr><tr><td align="left">-i,--groupid &lt;groupid&gt;</td><td align="left">The id or the name of the group</td></tr><tr><td align="left">-n,--name &lt;name&gt;</td><td align="left">The group name</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Extra parameters when authentication is enabled</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-A,--adminuser &lt;string&gt;</td><td align="left">Context Admin user name</td></tr><tr><td align="left">-P,--adminpass &lt;string&gt;</td><td align="left">Context Admin password</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Return value</h3></div></div></div><p><code class="computeroutput">0</code> on success</p><p><code class="computeroutput">&gt;0</code> on failure</p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Mandatory parameters</h3></div></div></div><p><strong class="userinput"><code>contextid {adminuser adminpass} (groupid or name)</code></strong></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Command output</h3></div></div></div><p>On success:</p><p><code class="computeroutput">group &lt;groupid&gt; in context &lt;contextid&gt; deleted</code></p><p>On failure:</p><p><code class="computeroutput">group &lt;groupid&gt; in context &lt;contextid&gt; could not be deleted: &lt;reason from server&gt;</code></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Example</h3></div></div></div><p><code class="computeroutput">root@oxhe~# </code><strong class="userinput"><code>/opt/open-xchange/sbin/deletegroup -c 123 -n sales</code></strong></p><p><code class="computeroutput">group 4 in context 123 deleted</code></p></div></div>
<div class="sect1" lang="en-EN"><div class="titlepage"><div><div><h2 class="title" style="clear: both">listgroup</h2></div></div></div><p><strong class="userinput"><code>listgroup</code></strong> is the tool to list and search for groups in a given context</p><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Parameters</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-h,--help</td><td align="left">Prints a help text</td></tr><tr><td align="left">    --environment</td><td align="left">Show info about commandline environment</td></tr><tr><td align="left">    --nonl</td><td align="left">Remove all newlines (\n) from output</td></tr><tr><td align="left">-c,--contextid &lt;integer&gt;</td><td align="left">The id of the context</td></tr><tr><td align="left">-s,--searchpattern &lt;string&gt;</td><td align="left">Search/List pattern, default “<span class="quote">*</span>”</td></tr><tr><td align="left">--csv</td><td align="left">command output as csv</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Extra parameters when authentication is enabled</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-A,--adminuser &lt;string&gt;</td><td align="left">Context Admin user name</td></tr><tr><td align="left">-P,--adminpass &lt;string&gt;</td><td align="left">Context Admin password</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Return value</h3></div></div></div><p><code class="computeroutput">0</code> on success</p><p><code class="computeroutput">&gt;0</code> on failure</p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Mandatory parameters</h3></div></div></div><p><strong class="userinput"><code>contextid {adminuser adminpass}</code></strong></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Command output</h3></div></div></div><p>Standard output:</p><div class="informaltable"><table border="0"><colgroup><col><col><col><col><col></colgroup><tr><td align="left">id</td><td align="left">name</td><td align="left">displayname</td><td align="left">members</td><td class="auto-generated">&nbsp;</td></tr><tr><td align="left">3</td><td align="left">users</td><td align="left">"all users"</td><td align="left">"2,4,5,8"</td><td class="auto-generated">&nbsp;</td></tr></table></div><p>csv output:</p><p><code class="computeroutput">id,name,displayname,email,members</code></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Example</h3></div></div></div><p><code class="computeroutput">root@oxhe~# </code><strong class="userinput"><code>listgroup -c 123</code></strong></p><div class="informaltable"><table border="0"><tr><td align="left">id</td><td align="left">name</td><td align="left">displayname</td><td align="left">members</td><td class="auto-generated">&nbsp;</td><td class="auto-generated">&nbsp;</td><td class="auto-generated">&nbsp;</td></tr><tr><td align="left">3</td><td align="left">users</td><td align="left">"all users"</td><td align="left">"2,4,5,8"</td><td class="auto-generated">&nbsp;</td><td class="auto-generated">&nbsp;</td><td class="auto-generated">&nbsp;</td></tr></table></div></div></div>
<div class="sect1" lang="en-EN"><div class="titlepage"><div><div><h2 class="title" style="clear: both">changegroup</h2></div></div></div><p><strong class="userinput"><code>changegroup</code></strong> is the tool to change a group in a given context.</p><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Parameters</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-h,--help</td><td align="left">Prints a help text</td></tr><tr><td align="left">    --environment</td><td align="left">Show info about commandline environment</td></tr><tr><td align="left">    --nonl</td><td align="left">Remove all newlines (\n) from output</td></tr><tr><td align="left">-c,--contextid &lt;contextid&gt;</td><td align="left">The id of the context</td></tr><tr><td align="left">-i,--groupid &lt;groupid&gt;</td><td align="left">The id or the name of the group</td></tr><tr><td align="left">-n,--name &lt;string&gt;</td><td align="left">The group name</td></tr><tr><td align="left">-d,--displayname &lt;string&gt;</td><td align="left">The displayname for the Group</td></tr><tr><td align="left">-a,--addmembers &lt;userid(s)&gt;</td><td align="left">List of members to add to group, separated by ","</td></tr><tr><td align="left">-r,--removemembers &lt;userid(s)&gt;</td><td align="left">List of members to be removed from group, separated by ","</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Extra parameters when authentication is enabled</h3></div></div></div><div class="informaltable"><table border="0"><tr><td align="left">-A,--adminuser &lt;string&gt;</td><td align="left">Context Admin user name</td></tr><tr><td align="left">-P,--adminpass &lt;string&gt;</td><td align="left">Context Admin password</td></tr></table></div></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Return value</h3></div></div></div><p><code class="computeroutput">0</code> on success</p><p><code class="computeroutput">&gt;0</code> on failure</p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Mandatory parameters</h3></div></div></div><p><strong class="userinput"><code>contextid {adminuser adminpass} (groupid or name) and at minimum one parameter for an attribute to change</code></strong></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Command output</h3></div></div></div><p>On success:</p><p><code class="computeroutput">group &lt;groupid&gt; in context &lt;contextid&gt; changed</code></p><p>On failure:</p><p><code class="computeroutput">group &lt;groupid&gt; in context &lt;contextid&gt; could not be changed: &lt;reason from server&gt;</code></p></div><div class="sect2" lang="en-EN"><div class="titlepage"><div><div><h3 class="title">Example</h3></div></div></div><p><code class="computeroutput">root@oxhe~# </code><strong class="userinput"><code>/opt/open-xchange/sbin/changegroup -c 123 -i 5 -d "new groupname"</code></strong></p><p><code class="computeroutput">group 5 in context 123 changed</code></p></div></div>


== 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 &lt;integer&gt;
|response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0'''
|-
| -c, --contextid &lt;integer&gt;
|The id of the contex
|-
| -n, --name &lt;string&gt;
|The group name
|-
| -d, --displayname &lt;stringe&gt;
|The displayname for the group
|-
| -a, --addmembers &lt;userid(s)&gt;
|List of members to add to the group separated by ", "
|}
=== Extra parameters when authentication is enabled ===
{| border="1"
|-
| -A, --adminuser &lt;string&gt;
|Context Admin user name
|-
| -P, --adminpass &lt;string&gt;
|Context Admin password
|}
=== Return value ===
<code>0</code> on success
<code>&gt;0</code> on failure
=== Mandatory parameters ===
'''<code>contextid {adminuser adminpass} name displayname</code>'''
=== Command output ===
On success:
<code>group &lt;groupid&gt; in context &lt;contextid&gt; created</code>
On failure:
<code>group in context &lt;contextid&gt; could not be created: &lt;reason from server&gt;</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 &lt;integer&gt;
|response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0'''
|-
| -i, --groupid &lt;groupid&gt;
|The id or the name of the group
|-
| -n, --name &lt;name&gt;
|The group name
|}
=== Extra parameters when authentication is enabled ===
{| border="1"
|-
| -A, --adminuser &lt;string&gt;
|Context Admin user name
|-
| -P, --adminpass &lt;string&gt;
|Context Admin password
|}
=== Return value ===
<code>0</code> on success
<code>&gt;0</code> on failure
=== Mandatory parameters ===
'''<code>contextid {adminuser adminpass} (groupid or name)</code>'''
=== Command output ===
On success:
<code>group &lt;groupid&gt; in context &lt;contextid&gt; deleted</code>
On failure:
<code>group &lt;groupid&gt; in context &lt;contextid&gt; could not be deleted: &lt;reason from server&gt;</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 &lt;integer&gt;
|response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0'''
|-
| -c, --contextid &lt;integer&gt;
|The id of the context
|-
| -s, --searchpattern &lt;string&gt;
|Search/List pattern, default “*”
|-
| --csv
|command output as csv
|}
=== Extra parameters when authentication is enabled ===
{| border="1"
|-
| -A, --adminuser &lt;string&gt;
|Context Admin user name
|-
| -P, --adminpass &lt;string&gt;
|Context Admin password
|}
=== Return value ===
<code>0</code> on success
<code>&gt;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 &lt;integer&gt;
|response timeout in seconds for reading response from the backend (default 0s; infinite) '''Available with v7.8.0'''
|-
| -c, --contextid &lt;contextid&gt;
|The id of the context
|-
| -i, --groupid &lt;groupid&gt;
|The id or the name of the group
|-
| -n, --name &lt;string&gt;
|The group name
|-
| -d, --displayname &lt;string&gt;
|The displayname for the Group
|-
| -a, --addmembers &lt;userid(s)&gt;
|List of members to add to group, separated by ", "
|-
| -r, --removemembers &lt;userid(s)&gt;
|List of members to be removed from group, separated by ", "
|}
=== Extra parameters when authentication is enabled ===
{| border="1"
|-
| -A, --adminuser &lt;string&gt;
|Context Admin user name
|-
| -P, --adminpass &lt;string&gt;
|Context Admin password
|}
=== Return value ===
<code>0</code> on success
<code>&gt;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 &lt;groupid&gt; in context &lt;contextid&gt; changed</code>
On failure:
<code>group &lt;groupid&gt; in context &lt;contextid&gt; could not be changed: &lt;reason from server&gt;</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: OX7]]
[[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