set_local_group_profile_field

Use the set_local_group_profile_field command to set the value of the specified profile field for the currently selected local UNIX or Linux group that has a profile defined in the current zone. Before executing this command, you must create a new local group by executing the new_local_group_profile command, or select an existing local group by executing the select_local_group_profile command.

You can save a group object before the group profile is complete. However, the group profile is not added to /etc/group on each UNIX and Linux computer in the zone until the group profile is complete and the profileflag field is set to 1 (enabled). See new_local_group_profile for details about which fields (attributes) a group profile must have to be considered complete.

Zone type

Hierarchical only.

Syntax

set_local_group_profile_field field_name value

Abbreviation

slgpf

Options

This command takes no options.

Arguments

This command takes the following arguments:

Argument Type Description

field_name

string

Required. Specifies the local group profile field to set. The possible values are:

  • gid
  • member
  • profileflag

You can also specify AIX extended attributes as the field to set an extended attribute value for a group. Extended attribute fields start with the aix. prefix. For example, the admin extended attribute can be set by specifying aix.admin as the field.

value

 

Required. The data type depends on the field being set. The possible values for each field are:

  • Any field: Clear any field by entering a hyphen character (-).
  • gid: A numeric group identifier.
  • member: The UNIX name of a local user to add to the group.
  • profileflag: 1 or 3.

    If set to 1, the group profile is enabled. If the group profile is complete and the profile flag is set to 1, the profile will be installed or updated in /etc/group at the next local account refresh interval.

    If set to 3, the group profile is removed from /etc/group at the next local account refresh interval.

Return value

This command returns nothing if it runs successfully.

Examples

The following example sets the GID of the currently selected group to 20001.

set_local_group_profile_field gid 20001

The following example adds the UNIX user anton.splieth to the currently selected local group.

set_local_group_profile_field member anton.splieth

The following example sets the profile flag of the currently selected group to 1 (enabled), so that if the group profile is complete, the profile will be installed or updated in /etc/group at the next local account refresh interval.

set_local_group_profile_field profileflag 1

If the current group is on AIX, you can set group AIX extended attributes and values. For example, to identify the current group as an administrative group, you can set the admin extended attribute:

set_local_group_profile_field aix.admin true

Related commands

The following related ADEdit commands let you view and administer local UNIX and Linux users and groups that have profiles defined in the current zone:

  • delete_local_group_profile deletes a local UNIX or Linux group that has a profile defined in the current zone.
  • delete_local_user_profile deletes a local UNIX or Linux user that has a profile defined in the current zone.
  • get_local_group_profile_field displays the value of a profile field for the currently selected local UNIX or Linux group that has a profile defined in the current zone.
  • get_local_groups_profile displays a TCL list of profiles for local groups that are defined in the current zone.
  • get_local_user_profile_field displays the value of a profile field for the currently selected local UNIX or Linux user that has a profile defined in the current zone.
  • get_local_users_profile displays a TCL list of profiles for local users that are defined in the current zone.
  • list_local_groups_profile displays a list of local UNIX and Linux groups that have a profile defined in the current zone.
  • list_local_users_profile displays a list of local UNIX and Linux users that have a profile defined in the current zone.
  • new_local_group_profile creates an object for a local UNIX or Linux group in the currently selected zone.
  • new_local_user_profile creates an object for a local UNIX or Linux user in the currently selected zone.
  • save_local_group_profile saves the currently selected local UNIX or Linux group object after you create the group object or edit profile field values in the group object.
  • save_local_user_profile saves the currently selected local UNIX or Linux user object after you create the user object or edit profile field values in the user object.
  • select_local_group_profile selects a local UNIX or Linux group object for viewing or editing.
  • select_local_user_profile selects a local UNIX or Linux user object for viewing or editing.
  • set_local_user_profile_field sets the value of a field for the currently selected local UNIX or Linux user that has a profile defined in the current zone.