Change Security Attributes (CHGSECA)

Where allowed to run: All environments (*ALL)
Threadsafe: No
Parameters
Examples
Error messages

The Change Security Attributes (CHGSECA) command changes the security attributes of a system. This command can be issued to:

When the UID (user ID number) is to be changed, a search is made for the first available user ID number, starting at the specified value. When the GID (group ID number) is to be changed, a search is made for the first available group ID number, starting at the specified value. If the maximum number is reached before an available number is found, the search will wrap and continue searching starting at 101. These numbers will then be used the next time a UID or GID is generated, for example, when the Create User Profile (CRTUSRPRF) command is issued and *GEN is specified for the UID parameter or the GID parameter, or when profiles are restored. Each subsequent time a UID or GID is generated, the search starts with the last used UID or GID that was generated.

If the UID or GID parameter is not specified, or *SAME is specified, no change will be made to the starting value.

You can use this command to set the starting point for generating UIDs or GIDs on i5/OS to one value (for example 3000) and the starting point on a different system could be set to a different value (for example 5000). This facilitates generating unique UID or GID values on multiple systems in a network.

The Change User Profile (CHGUSRPRF) command or the Change User Profile UID or GID (QSYCHGID) API can be used to specify the same UID for profiles on different systems or to The same GID for profiles on different systems.

Restrictions:

Top

Parameters

Keyword Description Choices Notes
UID User ID number 101-4294967294, *SAME Optional
GID Group ID number 101-4294967294, *SAME Optional
Top

User ID number (UID)

Specifies the new starting value at which a search for an available user ID (UID) number will begin.

*SAME
No change is made to the starting value for generated UIDs.
101-4294967294
Specify the new starting value at which a search for an available UID number will begin.
Top

Group ID number (GID)

Specifies the new starting value at which a search for an available group ID (GID) number will begin.

*SAME
No change is made to the starting value for generated GIDs.
101-4294967294
Specify the new starting value at which a search for an available GID number will begin.
Top

Examples

CHGSECA   UID(2000)  GID(3000)

User ID numbers generated after this command has run will start with the first available user ID number found with the search starting at 2000. Group ID numbers generated after this command has run will start with the first available user ID number found with the search starting at 3000.

Top

Error messages

*ESCAPE Messages

CPFB304
User does not have required special authorities.
Top