![]() | If you want to use an existing user or group ID, you do not need to create new ones at this time. Instead, you can proceed to the next step. |
You must perform this step as root.
Next, create a user ID that will be the instance owner. This user ID
will be the name of the instance. Make this user's primary group
the SYSADM group created above. In our examples, the instance user ID
is db2inst1 and the SYSADM group is dbadmin1.
![]() | Dedicate the instance owner user ID to that instance's use only. This allows for easier error recovery if a system error occurs. |
mkgroup dbadmin1 mkuser pgrp=dbadmin1 groups=dbadmin1 home=/home/db2inst1 db2inst1 passwd db2inst1
For example:
mkgroup db2fadm1 mkuser pgrp=db2fadm1 groups=db2fadm1 home=/home/db2fenc1 db2fenc1 passwd db2fenc1
Fenced User Defined Functions (UDFs) and Stored Procedures will execute under this user and group. The group must be the primary group of the user. The user for Fenced UDFs and Stored Procedures is specified as a parameter of the instance creation script. The group for Fenced UDFs and Stored Procedures is implicitly set to the primary group of this specified user (db2fenc1).
For security reasons, we recommend that you do not use the instance name as the FencedID. However, if you are not planning to use fenced User Defined Functions or Stored Procedures, you can set the FencedID to the instance name instead of creating another user for the FencedID.
Notes: