View Full Version : HUD is slow due to a big DB
FoldRiverPlz
04-25-2011, 08:52 AM
Hi
I play cashgames on Microgaming and Ongame. I have been playing there since February. I now have a database of around 70.000 hands.
So when I start auto import it takes like more than two minutes for the HUD to show correctly on my tables. In the beginning it only took like 6 seconds.
What can I do? I mean it is only getting worse since my DB keeps getting bigger.
Hope you guys can help me out.
/Thomas
fozzy71
04-25-2011, 03:32 PM
Make sure windows is fully updated and change your Windows Control Panel > Regional Settings Format to English (USA).
Please update to the latest version - http://www.holdemmanager.com/Downloads/HmUpdate.exe
For prima:
Uncheck "Import from Subfolders" in the auto-import settings.
Move the gamehistory.dat file your \hmarchive folder and import it via Import From File(s).
Try a new session with auto-import. A new handhistory file should be generated.
You should manually archive that file periodically as HM cant auto archive it like other sites.
For Ongame:
Move any files in the handhistory folder to your \hmarchive folder and import them via import file or import from folder.
In general:
Logging:
I would suggest you turn off logging on your new SQL installation as well as these other performance improvements in my signature - Top 10: HEM performance increase tips
To turn off logging, follow these instructions. This is the first thing I do anytime I install SQL for someone.
- Start > My Computer > Tools > Folder Options > View > UnCheck 'Hide Extensions for known file types' > OK
- C:\Program Files\PostgreSQL\data\postgresql.conf > Right-Click > Open With.. > NotePad > Check 'Always use this program'
- Scroll about half way down to ~Lines 245 - 260:
- The last line of this block of code, for the 'logging_collector', must be changed from On to Off.
------------------------------------------------------------------------------
# ERROR REPORTING AND LOGGING
#------------------------------------------------------------------------------
# - Where to Log -
log_destination = 'stderr' # Valid values are combinations of
# stderr, csvlog, syslog and eventlog,
# depending on platform. csvlog
# requires logging_collector to be on.
# This is used when logging to stderr:
logging_collector = off # Enable capturing of stderr and csvlog
File > Save; File > Close
Start > Programs > PostgreSQL 8.3 > Reload Configuration.
- Start > My Computer > C:\Program Files\PostgreSQL\data\pg_log, or C:\Program Files (x86)\PostgreSQL\data\pg_log, if you have 64 bit Vista. Delete all files in that folder. And it might be a good idea to empty your recycle bin at that point, or use a 3rd party utility like CCleaner to clean up all your junk/temporary files. You want to do this before you get to the vacuum and defrag process.
Regarding database maintenance:
You should regularly purge mined hands in your database, after purge vacuum / full analyze the database via pgadmin. You do not want to purge any Hero hands so make sure your alias is properly configured before purging.
http://faq.holdemmanager.com/questions/100/Purge+Hands+from+Database
http://faq.holdemmanager.com/questions/197/Purge+Hands
Then you can vacuum/analyze - http://faq.holdemmanager.com/questions/88/Vacuum+Analyze+Database+#manual
Before you defragment you should stop the PostgreSQL service:
Start > Programs > PostgreSQL 8.x > Stop Server
Use your favorite defrag tool. I recommend Smart Defrag.
After defrag I recommend you reboot your PC. If you need to access the DB before rebooting you can start the PostgreSQL service.
Start > Programs > PostgreSQL 8.x > Start Server
I would suggest you do the majority of the things in this thread: http://www.holdemmanager.net/forum/showthread.php?t=11194
Some of the most important things, imo:
- Remove the WinnerName, WinnerCards and WinnerWon from the Options > Hands View Column Selection.
- Turning off logging and deleting existing logs
- Vacuum/Full/Analyze, then Reindex - http://faq.holdemmanager.com/questions/88/Vacuum+Analyze+Database+#manual
- Defrag last and make sure you stop the postgresql service before you defrag. I personally use Smart Defrag.
- Do a Cold Boot (Shut Down > Start) before you use HM again
Powered by vBulletin® Version 4.2.3 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.