PostgreSQL size

Questions and discussion about PokerTracker 4 for Windows

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

PostgreSQL size

Postby crtcm » Wed Mar 04, 2020 5:00 am

Hello,

I'm starting to run out of space on my ssd. Postgresql takes around 150gb and my PT4 database it's at 50GB. What can i do to free up some space?

Thank you!
crtcm
 
Posts: 48
Joined: Wed Dec 18, 2013 9:21 am

Re: PostgreSQL size

Postby Flag_Hippo » Wed Mar 04, 2020 7:55 am

If you have unused databases then you can delete them otherwise if you want to reduce the size of your existing database then you would need to remove data from that database by purging hands however you should be aware that purging is a very involved process and in a large database it may take some time to complete. Also before purging you also need to have enough free space on that drive for the housekeeping/vacuum functions to complete successfully and recover disk space and this is typically equivalent to the size of the database itself so if you don't have that you may end up with a database in an unusable state and even less free space. Depending on the amount of hands you want to remove you may find it easier to re-import the hands you want to keep to a new database.
Flag_Hippo
Moderator
 
Posts: 17115
Joined: Tue Jan 31, 2012 7:50 am

Re: PostgreSQL size

Postby crtcm » Wed Mar 04, 2020 9:37 am

I only have around 5GB of free space left so i guess i can't start purging hands since the database has 50GB. What are the steps i need to take in order to create a new database, import only last 1-2 years and then delete the old one?
crtcm
 
Posts: 48
Joined: Wed Dec 18, 2013 9:21 am

Re: PostgreSQL size

Postby crtcm » Wed Mar 04, 2020 10:10 am

Or do i delete the current database and then create a new one and import everything from the PT4 - processed folder since 1-2 years ago?
crtcm
 
Posts: 48
Joined: Wed Dec 18, 2013 9:21 am

Re: PostgreSQL size

Postby Flag_Hippo » Wed Mar 04, 2020 2:19 pm

You can create a new database and re-import hands but don't delete the original database until you are sure you have everything you need. Hands can be imported to the new database from your 'Processed' folder and if you don't have all of your hands there you can export hands from the database before deleting it. Also export your player/hand notes if you have them (Database -> Notes) and if you have a number of tournaments with manually entered results then exporting those tournaments from PokerTracker 4 will create summary files containing the manual results so they can get recorded when imported into a new database.
Flag_Hippo
Moderator
 
Posts: 17115
Joined: Tue Jan 31, 2012 7:50 am

Re: PostgreSQL size

Postby crtcm » Thu Mar 05, 2020 12:44 am

After i deleted the old PT4 database (50GB) the size of postgreSQL was the same, around 100GB. Is this normal? I'm running version 9.3.22 There is a folder in it that takes up this space, Data with subfolders Base (30GB), Logs (57GB) and Pg93 (14GB).

Is there anything else i can do to clear more space?
crtcm
 
Posts: 48
Joined: Wed Dec 18, 2013 9:21 am

Re: PostgreSQL size

Postby Flag_Hippo » Thu Mar 05, 2020 6:50 am

crtcm wrote:After i deleted the old PT4 database (50GB) the size of postgreSQL was the same, around 100GB. Is this normal?

You said that PostgreSQL was taking up 150GB and your main PokerTracker 4 database was 50GB so deleting that would leave 100GB.
crtcm wrote:Data with subfolders Base (30GB)

Do you have multiple databases in PokerTracker 4? Have you used any other programs with this version of PostgreSQL e.g. Holdem Manager?
crtcm wrote:Logs (57GB) and Pg93 (14GB).

This looks like PostgreSQL was not installed on your computer by PokerTracker, Holdem Manager or manually via the Enterprise DB website. I've only seen this structure with the 'Pg93' folder when PostgreSQL is installed using a BigSQL installer and it's not something I am familiar with but if the 'Logs' folder just contains PostgreSQL log files you should be able to safely delete the contents of the 'Logs' folder.
Flag_Hippo
Moderator
 
Posts: 17115
Joined: Tue Jan 31, 2012 7:50 am

Re: PostgreSQL size

Postby crtcm » Thu Mar 05, 2020 7:09 am

I have only one database in PT4, the one i mentioned. Maybe i've used HM2 a few years ago but for a brief period of time. I don't have it installed now on my PC.

This is how the file looks like, what can i delete?

https://imgur.com/a/y8qER5H

Or do you think i should delete and reinstall Postgresql and PT4?
crtcm
 
Posts: 48
Joined: Wed Dec 18, 2013 9:21 am

Re: PostgreSQL size

Postby Flag_Hippo » Thu Mar 05, 2020 3:49 pm

crtcm wrote:I have only one database in PT4, the one i mentioned. Maybe i've used HM2 a few years ago but for a brief period of time. I don't have it installed now on my PC.

You should be able to check if you have any other databases via PGAdmin.
crtcm wrote:This is how the file looks like, what can i delete?

They just look like additional log files so you can delete those as well. If your install is creating these large files and not deleting old ones then I recommend turning logging off in PostgreSQL.
crtcm wrote:Or do you think i should delete and reinstall Postgresql and PT4?

If everything else is working that isn't necessary.
Flag_Hippo
Moderator
 
Posts: 17115
Joined: Tue Jan 31, 2012 7:50 am

Re: PostgreSQL size

Postby crtcm » Fri Mar 06, 2020 4:54 am

Done, thank you for your help!
crtcm
 
Posts: 48
Joined: Wed Dec 18, 2013 9:21 am


Return to PokerTracker 4

Who is online

Users browsing this forum: No registered users and 1 guest