PDA

View Full Version : How to configure postgresql on Ubuntu?



SteveCut
05-13-2011, 05:46 PM
I want to run HEM and my poker clients under XP running in Virtual Box under Ubuntu. I thought it would be more efficient to have the db running under native Ubuntu. I remember Netsrak and 'The Minder' writing that they had this configuration. How do I configure postgresql for this?

Patvs
05-13-2011, 08:28 PM
Read: http://forums.holdemmanager.com/manager-general/21952-running-postgres-8-3-ubunt-9-04-timeout-value-connectionstring.html

SteveCut
05-14-2011, 07:16 AM
Thanks, but that doesn't really help with the configuration. The problem is that the postgre configuration is automated now, which is great for the standard installation but not good if we need something different. Are there any manual postgre installation instructions still about? Even if it's for windows I can probably work it out for Ubuntu.

Patvs
05-14-2011, 11:18 AM
Try an older installer from PostgreSQL: The world's most advanced open source database (http://www.postgresql.org)
8.2/8.3 installers should still give you the options to setup everything manually.

SteveCut
05-14-2011, 12:06 PM
Problem resolved. :)
I set postgresql up manually on Ubuntu, downloaded the latest ODBC drivers on XP. Set up an ODBC connection and it's working fine.

pipocas
08-27-2011, 10:01 PM
hi
Is that configuration more efficient?

Can you explain more specificly how did you configured it? the postgresql server and the link (?) between postgresql and ODBC.

SteveCut
08-28-2011, 12:48 PM
I think it's more efficient because you have to allocate processors and memory to the Windows VM, but you still need to hold back most of your processing power and memory to run UNIX. If you run everything under Windows, your UNIX allocated resources are not used and your Windows allocated resources are over-used. Also, having the db and HH files at the top level OS makes sharing across computers simpler (I just use Ubuntu One to synch all my HH files and do a manual import from HMArchive every time I switch machines. I know there is the HM cloud now too but I don't want to use that, at least until it's proven.)

Anyway, the config above works seamlessly. The connection between UNIX and Windows is a virtual one, so it seems to be just as fast transfer-wise as a connection on one OS.

I can't remember everything I did, so can't give you a step-by-step guide but here's a few guidelines of what I remember doing. I resolved most problems by googling and managed to hack it all together. Try it yourself and if you get stuck I'll try to help.

Install VirtualBox on Ubuntu.
Install PostgreSQL on Ubuntu.
Set up the HM default user and password for Postgresql - the ones described in the HM doucumentation (postgres and postgrespass?)
Install Windows on VirtualBox. (Allocate a very large virtual disk as it won't actually be allocated until needed and it's hard to increase the size later. Other settings like memory and processors are easy to reconfigure later.)
Install VBox extensions on Windows (for seamless mouse usage etc.)
Install PostgreSQL ODBC driver on Windows and configure connection to postgreSQL running on UNIX
Install HM on Windows, UNchecking the setting to install PostgreSQL.
When HM starts and the default local db connection fails, configure a connection to the IP for the postgreSQL server.
Share folder(s) on your UNIX machine for use by Windows. I created a shared 'HH' (hand history) folder under 'Public'.
In Windows allocate a virtual drive 'H:' pointed at the 'HH' folder.
Configure your poker clients and HM to use hand history folders in H: and archive to a H:/HMArchive folder.

Well that's a start. I'm sure I've forgotten lots. Let me know when you get stuck.