z/OS RACF basic user management

Delete a user:

  1. Search all datasets owned from this user:

        TSO SR CLASS(DATASET) MASK(USERXXX)
    
  2. Delete datasets (or if it have important data you can change the owner):

        TSO DD 'USERXXX.*'
    
  3. If have alias:

        TSO DELETE (USERXXX) ALIAS
    
  4. Delete user:

        TSO DELUSER USERXXX
    

View users:

  1. View all users:

        TSO SR CLASS(USER)
    
  2. View all UID(0) users:

        TSO SR CLASS(USER) UID(0)
    
  3. List user:

        TSO LU
    

Or other user:

      TSO LU USERXXX

4.List OMVS segment:

      TSO LU USERXXX OMVS

Or TSO:

      TSO LU USERXXX TSO

Change permissions:

      TSO ALU USERXXX REVOKED

LIST DATASET INFO

      TSO LD [ALL] DATASET('USER')
              TSO LD [ALL] DATASET('USER.*') [AUTHUSER]
              TSO LD [ALL] ID(USER)
              TSO LD [ALL] ID(GROUP)
              TSO LD [ALL] PREFIX(TWS) [NORACF]

ADD DATASET INFO

      TSO AD [SAME OPTS OF ALD]

ALTER DATASET INFO

      TSO ALD 'USER.*' OWNER(USER)
              TSO ALD 'USER.*' NOTIFY(USER)
              TSO ALD 'USER.*' UACC(NONE|ALTER|CONTROL|UPDATE|READ|EXECUTE)
              TSO ALD 'USER.*' AUDIT(NONE|READ|ALTER|UPDATE|FAILURES|SUCCESS|ALL)
              TSO ALD 'USER.TOPSECRT.*' [/] OWNER(USER)

LIST RACF INFO

      TSO SR CLASS(USER) [UID(0)] [NOMASK]
              TSO SR CLASS(TSOAUTH) USER(USER) [NOMASK]
              TSO SR CLASS(DATASET) [NOMASK]

LIST USER INFO

      TSO LU [USER] [ALL|OMVS|TSO]

LIST GROUP INFO

      TSO LG [GROUP]

LIST ALLOCATED DATASETS

      TSO LISTA

More info: IBM