AFS pts command
AFS allows you to create groups of users and to set permissions for the entire group. These groups can then be used in fs setacl statements to assign permissions to the group of users. For example:
fs setacl . lsmith:pals rlidwka
Creating a group
Use the pts creategroup command to create a new group of users, specifying your username and the name of the group you want to create. The command format is:
pts creategroup your_user_name:groupname
Specifying your AFS username tells AFS that you own this group and allows you to specify the members. groupname can be anything you like. For instance, user brown might create the group buddies with the command:
pts creategroup brown:buddies
Adding or removing members from the group
Once the name of the group has been specified, you can tell AFS who belongs to it with the pts adduser command, which has the form:
pts adduser -user usernames -group your_user_name:groupname
A similar command can be used to remove a user from a group:
pts removeuser -user usernames -group your_user_name:groupname
For example, to remove users mahdavi and rreddy from group lsmith:src, type:
pts removeuser -user mahdavi rreddy -group lsmith:src
Deleting an entire group
If you decide that you no longer need to use the group, you can delete it with the pts delete command:
pts delete -name your_user_name:groupname
When you delete a group, you should remove it from all acls that reference it. To do this, use the fs cleanacl command, as follows:
fs cleanacl -dir directory
where directory is an AFS directory whose acls referenced the group.
Additional pts commands
There are a number of additional commands you may want to investigate as you become more familiar with AFS groups:
- pts membership
- to find out who belongs to a group
- pts examine
- to find out who owns a group, who created a group and so forth
- pts listowned
- to find out which groups are owned by a specific user.
In addition, pts also supplies online help.