PDA

View Full Version : Restore HEM1 db from directory



mjr161
07-25-2012, 05:55 PM
I'm trying to help a friend get their HEM1 db back. Their laptop was broken and I have the pulled hard drive, but they don't have any pg backups, just the directories. Can someone please help solve this? I've tried just stopping the service and overwriting the data directory, but the server won't start up afterwards.

I'm not sure if it matters, but the old installation was on a Win7 comp, the new on a WinXP VM on a mac. Any help would be appreciated.

Patvs
07-25-2012, 11:02 PM
Which SQL version was he using before? You have to use the same version
Suppose he was using SQL 8.4.x-->
On the new computer (WinXP VM on Mac)--> you only have to move the old /PostgreSQL/8.4/data folder to the new computer.

Install PostgreSQL 8.4.x with the installer from PostgreSQL: The world's most advanced open source database (http://www.postgresql.org)
During the installation select the location of where you moved the /data folder as the /data folder.



Note: this will only actually work 50% of the time. Ideally, you should have saved the archive folder from the old computer (C:/HMArchive) which contains the original handhistory files, so you can reimport them into the new computer.

mjr161
07-26-2012, 12:34 AM
The directory on the old computer is 8.4... so I installed the same version from postgresql.org.

Are you saying I have to repoint the directory to wherever I restore it during the postgres install?

Patvs
07-26-2012, 12:45 AM
If you install PostgreSQL and select the location of the data folder (and that folder already contains an existing database)
it should detect the old database-->finish the SQL installation--> when you start HoldemManager you can select the old database again

mjr161
07-26-2012, 01:01 AM
Ok I followed that, but it doesn't seem to be able to start the server. In PGAdmin I get this message when I double click the server...

Server doesn't listen
The server doesn't accept connections: the connection library reports
could not connect to server: Connection refused (0x0000274D/10061) Is the server running on host "127.0.0.1" and accepting TCP/IP connections on port 5432?

Patvs
07-26-2012, 01:10 AM
If it didn't give an error when you directed it to the /data folder (containing the /data content of the old computer), but after that (at the very END of the installation) didn't want to start the server:

check these settings:
-1 Turn on the secondary Logon. The secondary logon service is a standard windows service which is available on every windows computer. In the latest versions it is not started automatically. You need to start it via control panel > administrative tools > services. Starting it once should insure it works in the future also.


-2 Read:
http://holdemmanager.net/forum/showthread.php?t=8182
and check your hosts file (notice there shouldn't be a "#" in front of 127.0.0.1 and you have to reboot the computer if you make any changes to this file)

-3 Add postgres.exe and pg_ctl.exe (and port 5432) to the firewall exceptions list

mjr161
07-26-2012, 01:24 AM
1. Secondary login was already on... I stopped and restarted it, didn't seem to help.

2. I followed the instructions and rebooted the machine (VM), no luck

3. I have no firewall installed (winxp)

Is there anyone there that can attempt a restore? I'm a very technical person, but after 8 hours of troubleshooting I'm not sure I'm going to figure this out doing it myself.

netsrak
07-26-2012, 04:39 AM
If the service is still not starting the data folder probably contains damaged data.
I don't think there is anything left we can do for you and this is beyond our normal service.

mjr161
08-05-2012, 03:27 PM
Does it need to match the specific build within 8.4 to work (8.4.10). If so, can you tell me which version of 8.4 is downloaded during the install of HEM1?

Patvs
08-05-2012, 05:51 PM
Any 8.4.x is compatible with other 8.4.x builds.