PDA

View Full Version : New PC: Restoring database & registration



eendje01
01-11-2009, 04:34 PM
As my motherboard suddenly decided to give up, I decided to use this as an excuse to purchase a nice new computah...

This however, brought up 2 issues:

1.
Now, since I only have my hdd from the old pc, I copied the entire postgres 8.2 folder, with all data in it, and I plan to restore my old holdem manager database with it. Unfortunately I only see guides on how to 'backup' your database and howto 'restore' a backed-up database.

Since I didnt make a formal backup (I only have the raw files from the old postgres folder), I coulde very much use some assistance in how to restore my HM database. Anyone kind enough to help?

2. -> (This one is for the HM admins...)
Clearly, as I freshly installed HM on my new elite computer (;)) I needed to register/activate HM again. Since I allready activated it on my old PC (which is resting in piece atm), it says I allready used my maximum nr of activations and I need to deactivate 1 HM before I can continue.

Now, I can't de-activate the HM on the dead pc (as it is dead), and I really want to keep using HM on my laptop (which uses the PC2 activation option).
What do I do now?

Thanks in advance!

PS: I use the latest Holdem Manager and Postgres (8.3). My old database was in postgres 8.2. I use Windows XP Pro on the new pc (same as old one).

Al1
01-11-2009, 05:05 PM
1. This is not very hard to do, however I know morny is an expert with moving DBs. It will be good if you can reinstall the same postgreSQL version you used before, to avoid others issues: http://www.postgresql.org/ftp/binary/

Escalated to morny (Support), he will answer asap.

2. Just ask Roy to reset your 2 licenses: sales@holdemmanager.net
(and just reassign a license to your laptop too, that's not a problem)

morny
01-11-2009, 09:06 PM
Heres the details of how to backup and restore postgreSQL copy and paste, its always better to use the exact same version of postgreSQL too. The thing is this is the least successful way to recover your hands so it dosent always work unfortunately.

if you have installed postgresql again then turn off the service by finding PostgreSQL in the Start Menu and using the Stop Service option. Then delete the \Data folder in the new installation of postgres and copy your backed up \Data folder over. if you can't delete then you may need to reboot.

Then in the PostgreSQL menu click on Start Service and if everything went right you should be able to connect to your old database.

Please update the thread with your results or of course if you need further assistance.

eendje01
01-13-2009, 04:55 PM
Thank the both of you for the fast replies.

Morny: As you suggested I uninstalled Postgres 8.3 (restarted pc to be sure) and installed Postgres 8.2.5 -> Since the only lead to the exact version I could find was the file called 'postgresql-8.2-504.jdbc2.jar' in the old G:\Program Files\PostgreSQL\8.2\jdbc folder, I assumed I needed Postgres 8.2.5

However, I can't seem to start the service. After reboot it doesn't startup automatically and if I start it manually (or let HM start it) it appears in taskmanager for a few seconds and then closes itself.

Therefor, obviously, HM can't connect to the database...

Is there any more information I can provide you with, maybe some screenshots I can post somewhere...?

Thanks!

morny
01-13-2009, 08:45 PM
Do you know how to check the event log, Control Panel > Admin > Event Viewer and have a look in there for a postgreSQL error, most likely it will give an error like "cannot find table x" or something similar and in this case your database will be corrupted unaccessible. let me know if it dosent say this or says something else but as i mentioned already this isnt an ideal way to do it and not always successful

eendje01
01-14-2009, 09:50 AM
Ok, I did what you said and got the following:

First a bunch of error messages (yesterday when I tried to start the service a couple of times on a row):
2009-01-13 21:48:41 FATAL: could not remove old lock file "postmaster.pid": Permission denied
2009-01-13 21:48:41 HINT: The file seems accidentally left over, but it could not be removed. Please remove the file by hand and try again.

So, as suggested by the error log, I removed the file by hand and restarted the service, then I got the error:
2009-01-14 14:40:31 FATAL: could not create lock file "postmaster.pid": Permission denied

This made sence, as I checked the Postgres 8.2 folder and it was set on 'Read-only'. Therefor I changed this for this folder & all subfolders and started the service again. Now I keep getting:
Timed out waiting for server startup

This time, it is not reported as error but as information field (in Event Viewer).

As you may have guessed, the server is still not running...

morny
01-14-2009, 10:56 AM
If you manually try to start the service what error does it give, can you try version 8.3 and see if it gives the same error.

eendje01
01-15-2009, 04:11 PM
I copied the data folder with my HM data from the PostgreSQL\8.2 folder and pasted it over the data folder in the 8.3 folder (which was allready there, from a previous installation), then I tried to re-install PostgreSQL 8.3.5.

(Of course I allready had uninstalled postgreSQL 8.3 so that only the data folder remained).

It then notices that there is allready a data folder in the 8.3 folder, and it gives the following error:
"The existing data directory (catalog version: 200611241) is not compatible with this server (catalog version: 200711281)"

It does not give this error if I try to install PostgreSQL 8.3.5 when the 8.3 folder contains a valid data folder (created with Postgres 8.3). Therefor I figure that the 8.3.x PostgreSQL intallation can not handle the old data, so if anything would work, it would be PostgreSQL 8.2.x and not 8.3


However, 8.2 keeps giving me the error:2009-01-15 20:53:05 FATAL: could not create lock file "postmaster.pid": Permission denied

morny
01-15-2009, 06:50 PM
i can have a look if youd like but to be honest this copy and paste version from PC to PC dosent work too often (usually works fine on the same computer) but if you want me to have a look email me morny@holdemmanager.net and let me know a suitable time tommorrow