Re: Moving PostgreSQL data directory on Windows - Mailing list pgsql-general

From Magnus Hagander
Subject Re: Moving PostgreSQL data directory on Windows
Date
Msg-id 6BCB9D8A16AC4241919521715F4D8BCE6C7E80@algol.sollentuna.se
Whole thread Raw
In response to Moving PostgreSQL data directory on Windows  (Ottó Havasvölgyi <havasvolgyi.otto@gmail.com>)
Responses Re: Moving PostgreSQL data directory on Windows  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Moving PostgreSQL data directory on Windows  (Ottó Havasvölgyi <havasvolgyi.otto@gmail.com>)
List pgsql-general
> Hello,
>
> I would like to move the data directory to another location.
> I have done this:
> 1. Stop PostgreSQL
> 2. Move data directory
> 3. Create a PGDATA env. variable to the new location 4. Start
> PostgreSQL
>
> And it cannot start, because it cannot find postgresql.conf.
> (in Event log) What should I do now?

Are you running it as a service:? If so you need to reconfigure the service. Unfortunatly,the only way to do this is
usingregedit. Go to 
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\pgsql-8.1

Open the value "ImagePath" and change the data directory.

//Magnus

pgsql-general by date:

Previous
From: Doug McNaught
Date:
Subject: Re: Moving PostgreSQL data directory on Windows
Next
From: Doug McNaught
Date:
Subject: Re: Moving PostgreSQL data directory on Windows