moving tablespaces on windows - is it possible? - Mailing list pgsql-admin

From Kasia Tuszynska
Subject moving tablespaces on windows - is it possible?
Date
Msg-id D7BFFE348C53EF4E8AA0698B1E395FA9101CB152@flybywire.esri.com
Whole thread Raw
In response to problem with pg_stat_activity view  ("Sofer, Yuval" <Yuval_Sofer@bmc.com>)
List pgsql-admin

Hi Everybody,

Is it possible to move the directory associated to a tablespace and update that information in the postgres cluster?

I was expecting something like : ALTER TABLESPACE LOCATION “C:\...” but found no such usage.  Looking it up in the documentation I found that on linux one could

- shutdown postgres instance

- move the directory

- fix the symbolic link in $PGDATA/pg_tblspc

- start postgres instance

- update the pg_tablespace entry

 

I am running postgres 8.3.0 on windows 2003 sp2, according to wikipedia windows “symbolic links” have been implemented on xp only, so my platform would not have them. Altering the pg_tablespace it’s self and moving the directory does not work, I get the following error: could not create directory “pg_tblspc/16439/111451”; No such file or directory.

 

Questions:

  1. is it possible to move a tablespace ?
  2. how does the instance keep track of the pg_tblspc contents if there are no symbolic links on windows?

 

Thank you,

Sincerely,

Kasia

pgsql-admin by date:

Previous
From: "Alejandro D. Burne"
Date:
Subject: Re: [GENERAL] secure connections
Next
From: Saii
Date:
Subject: Source of User Defined functions.