lat-groups - The lazy administrator's tool to create groups and to add members to it.
Creates or deletes groups on Mitel's SME servers (5.x/6.x). This tool is functionally equivalent to the 'groups' option in the server-manager, but can be run from the command line or called from an other script. It allows you, for example, to add a large number of accounts to a group, or delete groups on a remote machine via an ssh console.
See /usr/doc/lazy-admin-tools/example.groups for the format of the input file.
lat-groups -a [-n] -c ``group | descr. | gid | user1| user2''
lat-groups -a [-n] -i /path/to/groups.list
lat-groups -r [-f] -c ``group | user1 | user2''
lat-groups -d [-f] -c ``group''
lat-groups -d [-f] -i /path/to/groups.list
The following options are supported:
Default behaviour on SME is to add both users to any group, thus limiting the number of groups on the server to 28. Note, however, that SME is very persistent with this 'feature'. Each time you add or remove a user via the server-manager, both 'admin' and 'www' are added again.
group* : Must contain only lower-case letters, numbers, hyphens, periods and underscores, and should start with a lower-case letter. Wildcards (* and ?) can only be used to delete groups. descr. : Free-text description of the group gid : Group ID. If omitted, a suitable gid will be generated. member(s) : Username of a member of the group. Must be an existing account on the server.
* mandatory field
lat-groups -a -c ``hogwarts | School of Witchcraft | | harry | hermione''
Creates group 'hogwarts' with users 'harry' and 'hermione'.
lat-groups -a -i /root/griffindor.list
Creates the groups defined in /root/griffindor.list. Refer to /usr/doc/lazy-admin-tools/example.groups for an example of an input file.
lat-groups -a -n -i /root/griffindor.list
Creates the groups defined in /root/griffindor.list. The users 'admin' and 'www' are *not* added to the group.
lat-groups -d -f -c ``class*''
Deletes all groups whose name start with 'class'. All groups are deleted without prompting (-f).
lat-groups -r -f -c `` * | admin | www''
Removes users 'admin' and 'www' from all groups on the system. Don't prompt before removing.
lat-groups -a -c ``quidditch | Different ball game | 7005''
Creates group 'quidditch' with group ID 7005.
lat-users(8), lat-pseudonyms(8), lat-ibays(8), lat-quota(8), lat-domains(8), lat-hosts(8), lat-procmail(8), lat-pptp(8), lat-dump(8)
Version 0.9.0 (2004-09-08). The latest version is hosted at http://www.contribs.org/contribs/mblotwijk/
(c)2003-2004, Altiplano bvba (http://www.altiplano.be). Released under the terms of the GNU license.
Please report bugs to <Bugs@Altiplano.Be>