public inbox for [email protected]  
help / color / mirror / Atom feed
From: Bharani SV-forum <[email protected]>
To: pgsql-general <[email protected]>
To: Adrian Klaver <[email protected]>
Subject: Re: cannot drop a tablespace which never exists in pg_tablespace
Date: Fri, 20 Dec 2024 16:52:19 +0000 (UTC)
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
	<CANzqJaAda4nZbkG=c+72ry5GdaxrJ6Jzr6fz1quhq8tTfaX1Pg@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<CANzqJaC1Uk4H=55vV_jbFYMuD1f9Bb_4Y9WKvkZA3bt92bEUnw@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>

 I found the culprit env variable was defined as PG_DATA inlieu of PGDATA
cleared and dropped itand restarted dband created once again tablespace in the desired location and it worked
Thank YouRegards
    On Friday, December 20, 2024 at 11:50:20 AM EST, Adrian Klaver <[email protected]> wrote:  
 
 On 12/20/24 08:09, Bharani SV-forum wrote:
> Adrian
> Inline image
> 
> initially i had created tblspace outside pg_data env variable

Did you run CREATE TABLESPACE as shown below?:

https://www.postgresql.org/docs/current/sql-createtablespace.html

Did you ever use the tablespace?

> e.g PG_DATA env variable is defined to /XXX/YYYY/ABC/15/data
> 
> the tablespace was created under  /XXX/YYYY/ABC/15/tblspace/<<tbl_spcname>>/
> assume tablespace name is abc_data
> 
> *cd /XXX/YYYY/ABC/15/tblspace/abc_data/*
> ls -atl
> drwxr-x---. 2 postgres postgres  6 Dec 19 22:08 PG_15_202209061
> 
> ls -altR
> drwxr-x---. 2 postgres postgres  6 Dec 19 22:08 PG_15_202209061
> 
> i reconfirmed
> SELECT * FROM pg_tablespace ;
>   oid  |  spcname   | spcowner | spcacl | spcoptions
> ------+------------+----------+--------+------------
>   1663 | pg_default |       10 |        |
>   1664 | pg_global  |       10 |        |
> 
> not having any entry about tablespace abc_data
> 
> Can you guide
> 

-- 
Adrian Klaver
[email protected]



  

view thread (61+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: cannot drop a tablespace which never exists in pg_tablespace
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox