The vRealize Operations Appliance has it’s own local database. Behind the scenes it is running vPostgres to store information for the infrastructure it is monitoring. Over time the database tables can become fragmented and impact performance of the user interface. Always snapshot or backup your appliance before attempting this procedure. NOTE: This procedure is not currently supported by VMware. Use at your own risk or call VMware support to assist you. This has only been tested on vROPS 6 single node deployment. I will be testing distributed soon.
1. Login to vCenter and take a snapshot of your vROPS appliance VM.
2. Login to the vROPS appliance as root or sudo to root and run the following command and press enter
su - postgres -c "/opt/vmware/vpostgres/current/bin/reindexdb -a > /tmp/reindexdb.log"
cat /tmp/reindexdb.log
su - postgres -c "/opt/vmware/vpostgres/current/bin/reindexdb -a > /tmp/reindexdb.log"
chmod u+x /reindexdb.sh
As someone who supports this product, I am wondering just how much performance improvements can be attained by this trick. vPostgres only stores alerts and alarms in vROps 6, and it should only accounts for about 5% of the data in the system. The other 95% of the data storage and processing is handled by other services. Does this really make an appreciable difference in a production system?
I have found the improvements to be mostly in the UI responsiveness. This is after the appliance has been deployed for some time. Over time the UI can become slow and sluggish. I believe this is because the java pages that are displayed depend on the vPostgres DB.
It’s too bad they are still using vPostgres 9.3 and not 9.4..