VMware Cloud Community
lvaibhavt
Hot Shot
Hot Shot

Purge old VC performance Data

Hi All,

I have a VC server and DB on a different Server. My client has asked me to keep performance data only for 90 days and delete the rest.

I followed article VMware KB: Purging old data from the database used by VMware vCenter Server 4.x and 5.0.x

I ran the script on my environment and this is what it returned

test.PNG

it has close to 2500363 rows that needs to be deleted. I have created steps that I will perform to get this going. I am running VC 5.5 and my hosts are on 5.1

  • Take a backup of the Virtual Center Database.
  • Power down VC Server test1 and the Database server test2
  • Copy the vmdk/vmx files of server test2 to another folder (this is as a backup)
  • Power on test2 and purge the files of the Database as per article
  • Once the purging is complete; power on the VC Server.
  • Verify the VC and DB connection

please let me know if this looks ok or anything else needs to be done

Thanks in advance

0 Kudos
4 Replies
rcporto
Leadership
Leadership

Why not take a snapshot instead of copy vmdk/vmx ?

---

Richardson Porto
Senior Infrastructure Specialist
LinkedIn: http://linkedin.com/in/richardsonporto
0 Kudos
lvaibhavt
Hot Shot
Hot Shot

purging would generate a lot of I/O and this would quickly fill the datastore and increase the size of snapshot

0 Kudos
rcporto
Leadership
Leadership

Yes, I know... but I doubt that the space for the snapshot will be greater than the full copy of vmdk... my recommendation to take a snapshot is only to speed up the process.

Anyway, your steps looks ok for me 🙂

---

Richardson Porto
Senior Infrastructure Specialist
LinkedIn: http://linkedin.com/in/richardsonporto
0 Kudos
lvaibhavt
Hot Shot
Hot Shot

Hi All,

I ran the test on my lab environment and it returned an error. snapshot attached

test 1.PNG

In the summary it says that it attempted to delete 68000 thousand rows but deleted only 1.

test 2.PNG

when I ran the script again; it shows that there are no rows to delete

test 3.PNG

I had stopped the VC service and then gone ahead with the deletion. Now when I check the graphs it only shows data for the previous day only -- all the previous data is gone. this is what I wanted and had set the script to delete all the data except previous day.

Did I do something wrong?

Thanks

0 Kudos