RE: Error message restarting a database

From: Begin Daniel <jfd553(at)hotmail(dot)com>
To: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: RE: Error message restarting a database
Date: 2019-08-17 20:46:20
Message-ID: YQXPR01MB392546E9FEA3EABF3B1C398B94AE0@YQXPR01MB3925.CANPRD01.PROD.OUTLOOK.COM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Sent: Sunday, January 27, 2019 8:18:08 PM
To: Begin Daniel
Cc: pgsql-general
Subject: Re: Error message restarting a database

On 1/27/19 2:45 PM, Begin Daniel wrote:

>> If you go to PGDATA.pg_tblspc do you have links to the tablespaces?
>>
>> I only installed one instance of Postgres on my PC, which I use to manage two databases (postgres and osmdump). osmdump is the database that complains.
>>
>> Regarding the links to the tablespaces, I first ran the following request.
>> SELECT spcname FROM pg_tablespace; and got the following list.
>> "pg_default"
>> "pg_global"
>> "workspace"
>> "datadrive1"
>> "datadrive2"
>> "datadrive3"
>> "datadrive0"
>>
>> I went to E:\pgsqlData\pg_tblspc and found the links to the five last tablespaces above (I manually created them, the first two were created when I installed Postgres).
>> E:\pgsqlData\pg_tblspc \113608\PG_9.3_201306121\18364 link to the 888 items mentioned previously (physically stored in K:\pgsqlData\pg_tblspc...)
>
> Hmm, K:\pgsqlData\pg_tblspc looks suspiciously like something
> masquerading as another PGDATA directory. Does a directory listing show
> what is shown in?:
>
> https://www.postgresql.org/docs/10/storage-file-layout.html
>
>> I also found a PG_VERSION file in E:\pgsqlData. The file contains the value 9.3
>>
>> Daniel
>>
>
> Sorry, bad copy paste, you should have read K:\pgsqlData\PG_9.3_201306121\18364
> The suggested content is found only in E:\pgsqlData, including PG_VERSION file and pg_tblspc subdirectory
>

Your original post had:

FATAL: *"pg_tblspc/113608/PG. 9.3_ 201306121/18364" is not a valid data
directory

PG. 9.3_ 201306121/18364 does not look like PG_9.3_201306121\18364.
To me it looks like a case of corrupted symlink(or whatever it is called
on Windows).

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com<mailto:adrian(dot)klaver(at)aklaver(dot)com>

You were right. I was able to correct them and restart the database.
Thank

Daniel

In response to

Browse pgsql-general by date

  From Date Subject
Next Message stan 2019-08-17 23:37:25 How to determine what is preventing deleting a rule
Previous Message Will Storey 2019-08-17 18:13:35 Re: Unexpected "canceling statement due to user request" error