From time to time, it is necessary to optimize the WebSphere Portal database. Following is an example command that can be used against DB2. We have seen notable performance increases after optimizing the DB with this method in a site that leverages a lot of Personalization Rules and content from WCM.
| Quoted From IBM Documentation "The db2 reorgchk command is one of the most important and often overlooked DB2 tuning commands. The db2 reorgchk command is overlooked because it is not a one-time tuning item. As updates are performed on the DB2 database, the statistical information about the tables will not be up to date. The db2 reorgchk command updates the important statistics that are used by the DB2 optimizer. It is recommended that the db2 reorgchk command be repeated after approximately every 10,000 updates." |
In a production environment, you may consider having this command automatically run on a periodic basis. This can be done by updating the AUTO_REORG database configuration parameter to ON. This parameter is part of the automatic maintenance configuration parameter hierarchy. For more information, see: Automatic table maintenance in DB2, Part 2: Automatic table and index reorganization in DB2 for Linux, UNIX, and Windows![]()