Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gnt4U-00013W-Bj for pgsql-general@arkaria.postgresql.org; Sun, 27 Jan 2019 22:38:35 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gnt4T-0004N8-6V for pgsql-general@arkaria.postgresql.org; Sun, 27 Jan 2019 22:38:33 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gnt4R-0004JJ-N9 for pgsql-general@lists.postgresql.org; Sun, 27 Jan 2019 22:38:32 +0000 Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gnt4P-0000Lo-6q for pgsql-general@postgresql.org; Sun, 27 Jan 2019 22:38:31 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 9D12220BA1; Sun, 27 Jan 2019 17:38:27 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute6.internal (MEProxy); Sun, 27 Jan 2019 17:38:27 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= subject:to:cc:references:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=fm2; bh=O pNuRyitnqRIRF98FHK47rgxB07em/wM1q6NsemP1Qs=; b=iwtJw2XtySyFYsSf1 wGZAGgj7RJ7fc6vsQWGGuLyh9uHw7IZjN/ReDF/1AqCtoWwXZDTDUIbIB5bq/GML NNcVS6pBHA8yHfG9HWEPXeegviGUKAoeBpqHgDeRsDJJtYytX1QlON58GVTVjVyc 0X2W8+pTnxLbhLMUWuVlE5CF/oEOIvnppMLYIXN7nR2Xdz/sRITMx27AhcODa9JZ F3hlsJdwGSN9abYwKpqhicQ/CBDbtUswvHUipenxv8KYNwp0tTDOposUySvkTRod BajcehS4yuM6z/H2bQ4VZlWb9tERI/u5YbjuFn1mq+Se28CdL3i1G6je8Q9cVFsR FAyfA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=OpNuRyitnqRIRF98FHK47rgxB07em/wM1q6NsemP1 Qs=; b=nAZPzxvWIiTQdRVhq4htVuxL7U3UprkPHCtPWzv/LyG85ISkGjluTFgQv 2Hm0F1bLze0sLH6heAcWzjEk002yeGXaKbFFGLZBQq0DoSsV92ZIhPldgynQY5hW AyhHzmE/lI/K2z7/3vEHF+4epSo3AA8O4ChJgrmmHba4VwlMyz7xI71fCmugdSQo 225sHTdKpCgnbB1idPQ5kB35SlkeW+RXhcC9ThsH/BHpTTwllBZp3LdvwSvUTkME hIF9fG3vvSRwsbb0zSrPBuRpEHcz/TJmlCBGEwqIa5W6uTgaibRLs99/eC+FHQ0q 02PqRUUeK5v6J0AdQTqtKj7RPsIig== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedtledrieekgdduieegucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfquhhtnecuuegrihhlohhuthemucef tddtnecunecujfgurhepuffvfhfhkffffgggjggtgfesthejredttdefjeenucfhrhhomh eptegurhhirghnucfmlhgrvhgvrhcuoegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghv vghrrdgtohhmqeenucffohhmrghinhepphhoshhtghhrvghsqhhlrdhorhhgnecukfhppe ejuddrvdduvddrudefgedrfeenucfrrghrrghmpehmrghilhhfrhhomheprggurhhirghn rdhklhgrvhgvrhesrghklhgrvhgvrhdrtghomhenucevlhhushhtvghrufhiiigvpedt X-ME-Proxy: Received: from [192.168.1.2] (unknown [71.212.134.3]) by mail.messagingengine.com (Postfix) with ESMTPA id AB56210281; Sun, 27 Jan 2019 17:38:26 -0500 (EST) Subject: Re: Error message restarting a database To: Begin Daniel Cc: pgsql-general References: <85497da8-6e5c-4ed9-6412-7b72de5bc7fc@aklaver.com> <6ce3f730-8808-88d0-79ba-161325d4f128@aklaver.com> From: Adrian Klaver Message-ID: <181d5008-fd82-9791-7c8a-38099184ab2d@aklaver.com> Date: Sun, 27 Jan 2019 14:38:25 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 1/27/19 2:22 PM, Begin Daniel wrote: > -----Original Message----- > From: Adrian Klaver [mailto:adrian.klaver@aklaver.com] > Sent: Sunday, January 27, 2019 16:52 > To: Begin Daniel > Cc: pgsql-general > Subject: Re: Error message restarting a database > > On 1/27/19 1:38 PM, Begin Daniel wrote: >> -----Original Message----- >> From: Adrian Klaver [mailto:adrian.klaver@aklaver.com] >> Sent: Sunday, January 27, 2019 16:15 >> To: Begin Daniel >> Cc: pgsql-general >> Subject: Re: Error message restarting a database >> >> On 1/27/19 12:56 PM, Begin Daniel wrote: >> >> Not a good day, forgot to actually Cc list last time. >> >>> -----Original Message----- >>> From: Adrian Klaver [mailto:adrian.klaver@aklaver.com] >>> Sent: Sunday, January 27, 2019 15:43 >>> To: Begin Daniel >>> Subject: Re: Error message restarting a database >>> >>> On 1/27/19 12:38 PM, Begin Daniel wrote: >>> Please reply to list also >>> Ccing list. >>>> -----Original Message----- >>>> From: Adrian Klaver [mailto:adrian.klaver@aklaver.com] >>>> Sent: Sunday, January 27, 2019 15:33 >>>> To: Begin Daniel; pgsql-general@lists.postgresql.org >>>> Subject: Re: Error message restarting a database >>>> >>>> On 1/27/19 12:23 PM, Begin Daniel wrote: >>>>> I worked with a PostgreSQL database (9.3) for a couple of years on my >>>>> PC. I shut down the PostgreSQL server about a year ago and I obviously >>>>> did not access the database since. Now I am trying to access again to >>>>> the database but I get the following error message... >>>>> >>>>> FATAL: *"pg_tblspc/113608/PG. 9.3_ 201306121/18364" is not a valid data >>>>> directory >>>>> >>>>> DETAIL: File *" pg_tblspc/113608/PG. 9.3_ 201306121/18364/PG_VERSION" is >>>>> missing. >>>>> >>>>> Anyone has an idea on how to solve this problem? >>>> >>>> What OS and version? >>>> Best guess is your OS updated Postgres in the past year and the newer >>>> version is trying to load an older data directory. >>>> >>>>> >>>>> Daniel >>>>> >>>> >>>> OS and version... >>>> Windows 10 Pro, Version 1809 installed on 2019-01-11 >>>> OS Build 17763.253 >>> >>> Whoops, just realized the errors are pointing at a tablespace/dir. >>> >>> Does the directory in the error message exist? >>> >>>> >>>> >>> I have multiple tablespaces. According to the definition of my tablespaces, the error point on the following directory: K:\pgsqlData\PG_9.3_201306121\18364 >>> The directory exists with 888 items in it, but there is no file named PG_VERSION >>> >> >> Are all the tablespaces connected to a single Postgres instance? >> >> Are you still using Postgres 9.3? >> >> Does the Postgres top level data directory still exist? >> >> >> Right, not a good day ;-) >> - All tablespaces are connected to a single Postgres database instance >> - I am still using Postgres 9.3 since I did not change anything related to PostgreSQL since I shut down the server a year ago >> - I am not sure what you mean by top level directory. > > PGDATA from here: > https://www.postgresql.org/docs/10/storage-file-layout.html > > I am going to say PGDATA exists given the below. > > >> >> I am using PgAdmin to access my PostgreSQL databases. I can access the default database (postgres), tablespace definitions, group roles and login roles. The other database instance I have is the one that send me error messages. >> > > To be clear you are running only one instance(cluster) of Postgres and > that instance has several databases defined in it, correct? > > 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 > -- Adrian Klaver adrian.klaver@aklaver.com