Page 1 of 2
I can't purge database
Posted:
Sun May 12, 2013 7:36 am
by alpyn
Hi guys,
I've found my database is too big (33GB) and I would like to remove some old hands.
The problem is — I can't. Every time when I try to purge, PT4 freezes after a few seconds and does not respond, so I have to force quit. I was trying to remove hands between various dates, at a specific date and so on. Nothing worked. By the way, I have i5 processor, Vertex 4 SSD disk and 4GB RAM.
Does anyone have similar issue? What should I do if I really want to purge database?
Re: I can't purge database
Posted:
Sun May 12, 2013 7:45 am
by alpyn
The only solution I can see at this moment is to export a newer hands, delete current database, create a new one and import those exported hands into a new database. But it doesn't sound like a easy and time-saving job.
Re: I can't purge database
Posted:
Sun May 12, 2013 9:16 am
by WhiteRider
Purging is a very involved process and purging any large number of hands from such a large database will take a considerable amount of time. It will appear to be stuck initially but it is working. Terminating the process can cause problems in your database, so you'll need to rebuild the cache if you are going to continue to use that database (Database > Database Management).
If you want to remove a significant proportion of the hands you may well find it faster to export the hands you want to keep and import them to a new database.
Re: I can't purge database
Posted:
Sun May 12, 2013 11:16 am
by alpyn
Thanks for the answer. Can you estimate necessary time for purging this 33GB database with my hardware configuration? I consider to run this process tonight, but if it takes more than 15 hours, I would rather export newer hands into a new database.
Re: I can't purge database
Posted:
Sun May 12, 2013 1:38 pm
by WhiteRider
It isn't really possible to estimate the time as there are many factors. What sort of proportion of that database are you planning to purge?
Re: I can't purge database
Posted:
Sun May 12, 2013 8:23 pm
by alpyn
I'd like to purge ~800k observed hands.
Re: I can't purge database
Posted:
Mon May 13, 2013 3:34 am
by WhiteRider
That will take some considerable time, but would probably be quicker than re-importing the rest of that database. You may want to start your purge with a partial purge (using date ranges for example) and let it run overnight to minimize interference with your use of PT4. It will take longer overall like that since it has to update the cache for the affected players, but it would mean that PT4 wasn't tied up for so long all at once.
Re: I can't purge database
Posted:
Mon May 13, 2013 6:38 am
by alpyn
Thanks, I will try it tonight. Just to be sure — is it alright if Activitiy Monitor showes that PT4 takes only 0.2% CPU and is not responding?
Re: I can't purge database
Posted:
Mon May 13, 2013 9:40 am
by kraada
That doesn't necessarily mean there's a problem - a lot of the work is done by PostgreSQL which would be the postgres.exe processes.
Re: I can't purge database
Posted:
Wed May 15, 2013 3:53 am
by alpyn
I let the process ran overnight. You were right, process was completed, but for some reason, not a single hand was purged :-/ I select myself as an active player, chose right site, chose observed hands only, select dates between 1/1/2013-4/15/2013 and chose all stakes. Do you have any idea why no hand was purged?