[Wine] Postgresql 8.0 installation

Martin Gregorie martin at gregorie.org
Mon Aug 2 11:39:43 CDT 2010


On Mon, 2010-08-02 at 10:35 -0500, sabir_mustafa wrote:
> The PostgeSQL i am trying to run is a Windows Installer.
>
OK. I thought it might be.

There's really no reason for running PostgreSQL under Wine: PowerBuilder
doesn't care where the database is installed as long as it can open a
connection to it. In addition, there are a number of disadvantages:

- PostgreSQL may be more fragile run under Wine
- wine will demand access to an X-server while running PostgresQL
  which means you probably can't run it as a background task
- there may be performance overheads that native PostgreSQL won't have
- you won't be able to run PostgreSQL as a Linux service. 

  IMO this is a major disadvantage because: 
  - running as a service means that PostgreSQL will automatically
    start when the system is booted and will be correctly shut down
    when Linux is stopped. 
  - Its easy to configure native PostgreSQL so it will just sit
    quietly in the background and look after itself.
  - you can set up automatically scheduled database backups
  - PostgreSQL updates will be automatically applied by your distor's
    package manager. 

PostgreSQL will almost certainly be available as a standard package for
your distro, so it can be installed by your distro's package manager.
There is a full compliment of native, ODBC, JDBC and Python drivers
available for it too.

PostgreSQL for Linux can easily be addressed as localhost:5432 from Wine
if its installed on the same hardware as PowerBuilder. 

> The problem is that our old developed application is in PowerBuilder
> (I m still confirming version from the operators) with back end
> database PostgeSQL 8.
>
Do you know that PowerBuilder is compatible with PostgreSQL? I didn't
notice any native support, so you'll probably have to use ODBC. 

> I want my people to get rid of silly viruses. Thats why I want to
> change the whole thing to Wine rather than having a new development.
> 
Understood, but while PowerBuilder will have to be run under Wine you
don't need to run the target database under wine as well: it can be run
under Linux on the same hardware or on a remote server - all that
matters is that PowerBuilder can see the database server. 

As an example, I remember trouble shooting a database performance
problem back in the mid 90s: the PowerBuilder application was in London
on a PC but the target database was Sybase 9 on an NCR UNIX box in Abu
Dhabi. The problem turned out to be the auto-generated SQL SELECT
statement in the PowerBuilder application. We replaced it with a
hand-written query and got the performance we expected. I don't know if
PowerBuilder autogenerates better SQL these days, but its worth looking
at it to see if its sensible and to use the Postgres EXPLAIN verb to see
how costly the query is and optimise it/add supporting indexes etc. as
needed.


Martin





More information about the wine-users mailing list