19 July,2017 by Tom Collins
During a recent consultation there was a requirement to block DB2 LUW database connections. The purpose was to test monitoring alerts and assess the correct response when a database connection could not be established.
The requirement was to maintain the DB2 instance active and all the other databases as online
An easy way to block database connections is to use the MAXAPPLS database configurable. This parameter specifies the maximum number of concurrent applications that can be connected (both local and remote) to a database.
The trick is to set the DB2 LUW database MAXAPPLS configurable to 1, and ensure that you obtain the database connection. Any other database connection will fail, regardless of whether it is remote or local.
You may discover some issues applying MAXAPPLS to 1. Adjusting MAXAPPLS is closely associated to MAXLOCKS . But the decisions to adjust the MAXLOCKS is dependant on how you currently have the database configured
db2 update db cfg for MTTESTDB using MAXAPPLS 1
This is only a preview. Your comment has not yet been posted.
As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.
Having trouble reading this image? View an alternate.
Posted by: |