What Commands Will Remove Superuser Privilege for a LogonID?

Document ID : KB000129029
Last Modified Date : 14/03/2019
Show Technical Document Details
Introduction:
Superuser privilege was granted temporarily to a LogonID, and now needs to be removed. 
Question:
What commands can remove Superuser privilege for a LogonID?
Environment:
z/OS
USS
Answer:
Here are examples of two ways to REMOVE Superuser privilege for Logonid OMVSU2: 

1) Change the UID number - make it non-zero:

SET PROFILE(USER) DIV(OMVS) 
CHANGE OMVSU2 UID(199) HOME(/u/omvsu2) OMVSPGM(/bin/sh) 

OR 

2)  Delete the OMVS record for that LogonID completely (i.e. keep the Logonid but take away all OMVS data): 

SET PROFILE(USER) DIV(OMVS) 
DELETE OMVSU2