[GENERAL] Is postgres installed?

2010-05-21 Thread christophe . andre
Hi,

How I know whether Postgres is already installed or not on a machine(on
Linux and Windows)?
I found that pg_ctl --version could be used or I also tried to check into
the registry (for windows HKLM\SOFTWARE\PostgreSQL\Installations), however
with Windows Server 2003 pg_ctl is not recognized (probably not in the
path) and the registries are not written (nothing appears under
HKLM\SOFTWARE\)

Is there another check I can do?

Thanks
Christophe


-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] Is postgres installed?

2010-05-21 Thread Rob Richardson
What about searching your hard drive for pg_ctl.exe? 

RobR

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] Is postgres installed?

2010-05-21 Thread Raymond O'Donnell
On 21/05/2010 14:43, christophe.an...@elsys-design.com wrote:

> How I know whether Postgres is already installed or not on a machine(on
> Linux and Windows)?
> I found that pg_ctl --version could be used or I also tried to check into
> the registry (for windows HKLM\SOFTWARE\PostgreSQL\Installations), however
> with Windows Server 2003 pg_ctl is not recognized (probably not in the
> path) and the registries are not written (nothing appears under
> HKLM\SOFTWARE\)

On Windows, you could just have a look in c:\program files\postgresql.
There are usually some items in the Start Menu also.

On Linux, you'll see if it's actually running by doing

  ps ax | grep postgres

or the like... If it's not running, where you'd look for the files
varies from one distro to another, but using "find" should throw up some
of them.

Ray.


-- 
Raymond O'Donnell :: Galway :: Ireland
r...@iol.ie

-- 
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


Re: [GENERAL] Is postgres installed?

2010-05-22 Thread Craig Ringer

On 21/05/2010 9:43 PM, christophe.an...@elsys-design.com wrote:

Hi,

How I know whether Postgres is already installed or not on a machine(on
Linux and Windows)?
I found that pg_ctl --version could be used


Only if PostgreSQL's binary directory is on the PATH, which it may not 
be especially on Windows.


There's no reliable way to detect a PostgreSQL install on UNIX/Linux/BSD 
either. You can look for pg_ctl on the path and tell the user that the 
pg_ctl for the postgresql install they want to use simply must be on the 
path. However, some Linux flavours support parallel installation of 
multiple versions of PostgreSQL (and multiple clusters for a given 
version), and will *not* have pg_ctl on the path for versions of 
PostgreSQL installed on the system.


On Ubuntu/Debian you'll only find `pg_ctlcluster', which is a pg_ctl 
wrapper that takes additional 'version' and 'cluster' arguments. On 
these systems you can use pg_lsclusters to find PostgreSQL clusters.


Alternately, you could simply require the user to set up the PATH 
manually, eg


  PATH=/usr/lib/postgresql/8.4/bin:$PATH  ./yourprogram

which will work anywhere and everywhere there's a Pg install.


or I also tried to check into
the registry (for windows HKLM\SOFTWARE\PostgreSQL\Installations), however
with Windows Server 2003 pg_ctl is not recognized (probably not in the
path) and the registries are not written (nothing appears under
HKLM\SOFTWARE\)


How was Pg installed? Using which installer package?

Here (Vista, XP and Windows 7) Pg appears under
   HKLM\Software\Postgresql\Installations\postgresql-8.4
as installed by the EnterpriseDB "one-click" installer.

If you "installed" Pg from the zip file, there's no real way to figure 
out if it's installed except checking the PATH for pg_ctl.exe or 
checking the running process list for postgres.exe . Both are fallible - 
the former if pg_ctl isn't on the path, the latter if PostgreSQL is 
installed but not currently running.


--
Craig Ringer

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[GENERAL] Is postgres installed by default in Fedora Core 5 ??

2006-10-27 Thread Sandeep Kumar Jakkaraju
Is postgres installed by default in Fedora Core 5 ??
 
-
Sandeep Kumar Jakkaraju  


Re: [GENERAL] Is postgres installed by default in Fedora Core 5 ??

2006-10-29 Thread Wes Sheldahl
On 10/27/06, Sandeep Kumar Jakkaraju <[EMAIL PROTECTED]> wrote:
Is postgres installed by default in Fedora Core 5 ??
 
-
Sandeep Kumar Jakkaraju  

I know that there are Fedora 5 RPM's for postgresql, that you can easily install via yum or your favorite install method. It's *probably* included among the applications you can install during the Fedora installation process itself. To install the client and server packages via yum, you would do:
yum install postgresql postgresql-serverCheers,-- Wes SheldahlSheldahl Consulting LLChttp://www.sheldahlconsulting.comPhone: 859-338-3349
Fax: 866-387-4484[EMAIL PROTECTED]