VMware App Volumes event database cleaning

Before upgrading the VMware App Volumes Manager to the newest version 2.12, it’s recommended to clean the event database first.
With older version of App volumes like 2.10,2.11 the manager checks and records the device status like;

– Power on
– Shut down
– startup
– Reset
– Removed id

Without cleaning, the database can quickly grow to a size more than 100 GB

# Before cleaning ensure that you have a recent backup

Check the data


SELECT * FROM log_records WHERE created_at < DATEADD(day, -60, GETDATE());
SELECT * FROM snapvol_timeseries WHERE created_at < DATEADD(day, -60, GETDATE());
SELECT * FROM system_messages WHERE created_at < DATEADD(day, -60, GETDATE());

Delete the data


DELETE FROM log_records WHERE created_at < DATEADD(day, -60, GETDATE());
DELETE FROM snapvol_timeseries WHERE created_at < DATEADD(day, -60, GETDATE());
DELETE FROM system_messages WHERE created_at < DATEADD(day, -60, GETDATE());

Additional you can change the days to 30


DELETE FROM log_records WHERE created_at < DATEADD(day, -30, GETDATE());
DELETE FROM snapvol_timeseries WHERE created_at < DATEADD(day, -30, GETDATE());
DELETE FROM system_messages WHERE created_at < DATEADD(day, -30, GETDATE());

After that, shrink the database and do a check on one of the managers

# Recovery model must be set to simple #

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s