The default administration workload SYSDEFAULTADMWORKLOAD is a special DB2-supplied workload definition that is not subject to any DB2® thresholds. Use this workload to take corrective action that cannot otherwise be performed, such as altering prohibitive threshold definitions that prevent all activities from running in a workload.
Although you require no special authority to use the SET WORKLOAD command, you require ACCESSCTRL, DATAACCESS, DBADM, SECADM, or WLMADM authority to assign a connection to the default administration workload. Otherwise, SQL0552N is returned during workload assignment.
SET WORKLOAD TO SYSDEFAULTADMWORKLOAD
The following example shows how you can use the SYSDEFAULTADMWORKLOAD workload to take corrective action when no other corrective action is possible.
If you create a severely prohibitive concurrency threshold so that no activities can execute, because the threshold is always being exceeded, the same threshold can prevent you from correcting the problem. To be able to alter the prohibitive threshold, you must first set the workload so that the work runs in the default administration workload. Because activities running in this workload are not subject to thresholds, you can correct the problem and set the workload (for your ID) back to the default behavior.
The threshold that is the cause of the problem is created accidentally with the following statement. Concurrency should have been set to 100 but was set to 0. This threshold effectively prevents any activity from executing:
CREATE THRESHOLD PROHIBITIVE FOR DATABASE ACTIVITIES
ENFORCEMENT DATABASE WHEN CONCURRENTDBCOORDACTIVITIES > 0
STOP EXECUTION
If you attempt to execute even just a simple SELECT statement, an error is returned, because concurrency is set to 0:
SELECT * FROM SYSCAT.TABLES
SQL4712N The threshold "PROHIBITIVE" has been exceeded. Reason code = "6".
SQLSTATE=5U026
Before you can take corrective action, you must set the workload to the default administration workload:
SET WORKLOAD TO SYSDEFAULTADMWORKLOAD
This statement can be issued only by someone with ACCESSCTRL, DATAACCESS, DBADM, SECADM, or WLMADM authority and causes any connection to be assigned to the SYSDEFAULTADMWORKLOAD workload, where activities are not subject to the prohibitive threshold.
The problem can now be corrected by altering the threshold so that activities can run:
ALTER THRESHOLD PROHIBITIVE WHEN CONCURRENTDBCOORDACTIVITIES > 100 STOP EXECUTION
Once corrected, change the workload back so that the connection will no longer be assigned to SYSDEFAULTADMWORKLOAD but to whatever workload it was assigned to before:
SET WORKLOAD TO AUTOMATIC
The same SELECT statement used before should now complete successfully:
SELECT * FROM SYSCAT.TABLES
...
DB20000I The SQL command completed successfully.