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 1gUvcj-0004WH-LC for pgsql-general@arkaria.postgresql.org; Thu, 06 Dec 2018 15:31:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gUvbj-00053m-3i for pgsql-general@arkaria.postgresql.org; Thu, 06 Dec 2018 15:30:31 +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 1gUvbh-0004zB-D3 for pgsql-general@lists.postgresql.org; Thu, 06 Dec 2018 15:30:30 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gUvba-0001iF-Ff for pgsql-general@lists.postgresql.org; Thu, 06 Dec 2018 15:30:28 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 3453521FA9; Thu, 6 Dec 2018 10:30:20 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Thu, 06 Dec 2018 10:30:20 -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=fm1; bh=Z JHfSbeCXFehDXyLnS0TloONgwW6yq1dywqFSR4lsiw=; b=fOv7T+d6sMcHvJRHy 8IBniD1fDZ5/599ILT3CbmWc6QpR2IRRh/t4/tJluihDNIyTNmSRyArwnFCWHSC7 JxIaMT2vF3/qK9JBQ9+eCvp7JTHi+s02+PPzmfdsxeMRKCQdu5WZP/EXXlEgJ5xC bVr4nogdkadSzbmWRHEnmGepnkK9pXTCbq7wgfdP3JdRzr9OlPHfj5iVbSRgoz9D Lywtvv4wNTxbpx5cJMVtmzuaoREb+hHZKQXQqRq1M4M2gLXMgLYG21tBmOBgwKse 0nC7HzKqgIRWvVPCT4e8jmIC9jDVQPqf+dKyzn97NYhCr8JBa0E7/Teqb5pPa/wu 5fIHA== 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=ZJHfSbeCXFehDXyLnS0TloONgwW6yq1dywqFSR4ls iw=; b=Zjr1ET/umlLTo7O0Xtelj2P3rrub99qyH0rq20VJGKNFhz8pw2+yT3482 QlC+9mLIkqQ/QpNj6qxQ9uRtp1QNjbIXr61mQG6YorWr6KN7Rbq8AQDg4kxf6b9V RQfZLflSskXYjc/E+y4hs9MnPpMuC9FkqI2JC5t1O6rKOoW6gBZQ2W/qLv8SoN8f O6F8CXeauKaIPrNmZ6vdSzCLnlHsl/MByQOrkx5+Z7gtGFPXNA9Wqy6Vk2Qhy93z A8q9iw5qnxik9vR4IvAY8vplILC9ZZRaF6fFwN17LcX5VjmSBtcds09r/tsKlmBr 875CMUEmAQr4a379HnYWmeFKByg4g== X-ME-Sender: X-ME-Proxy: Received: from [192.168.1.3] (unknown [71.212.134.3]) by mail.messagingengine.com (Postfix) with ESMTPA id BA4E1E4A43; Thu, 6 Dec 2018 10:30:18 -0500 (EST) Subject: Re: postgis after pg_upgrade To: Slavcho Trnkovski , schneider@ardentperf.com Cc: pgsql-general@lists.postgresql.org References: From: Adrian Klaver Message-ID: Date: Thu, 6 Dec 2018 07:30:18 -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: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 12/6/18 12:40 AM, Slavcho Trnkovski wrote: > Hi, > But my understanding is that this approach is used when upgrading PostGIS. Which maybe necessary when upgrading the database: http://postgis.net/docs/manual-2.4/postgis_installation.html#upgrading Which seems to be what is happening in your case, as before you reinstalled the extension you got(from OP): select PostGIS_full_version(); postgis_full_version --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- POSTGIS="2.4.5 r16765" *PGSQL="94" (procs need upgrade for use with "96") *GEOS="3.6.2-CAPI-1.10.2 4d2925d6" PROJ="Rel. 4.9.3, 15 August 2016" GDAL="GDAL 1.11.4, released 2016/01/25" LIBXML="2.9.1" LIBJSON="0.11" RASTER (1 row) > I'm upgrading postgresql from 9.4 to 9.6 and PostGIS version remains the > same (2.4.5). > If I execute: >   drop extension postgis; >   CREATE EXTENSION postgis SCHEMA postgis; > select PostGIS_full_version(); > >         postgis_full_version > ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ >  POSTGIS="2.4.5 r16765" PGSQL="96" GEOS="3.6.2-CAPI-1.10.2 4d2925d6" > PROJ="Rel. 4.9.3, 15 August 2016" GDAL="GDAL 1.11.4, released > 2016/01/25" LIBXML="2.9.1" LIBJSON="0.11" RASTER > > everything looks OK. Is this wrong? > > Regards, > Slavcho > > On Tue, Dec 4, 2018 at 7:41 PM Jeremy Schneider > > wrote: > > On 11/30/18 05:11, Slavcho Trnkovski wrote: > > I have postgresql 9.4 with postgis extension installed (latest > version, > > 2.4.5). I upgraded postgresql from 9.4 to 9.6. > > After upgrading to 9.6 I get the following result > > from PostGIS_full_version() > >  select PostGIS_full_version(); > > > >  ... (procs need upgrade for use with "96") ... > > > > Is there any way to resolve this besides recreating the extension? > > If I'm reading the postgis docs correctly, this message specifically > means that you must do a full dump/reload of postgis-enabled databases. > > http://postgis.net/docs/manual-2.4/postgis_installation.html#upgrading > > > If you can't find the postgis_upgrade*.sql specific for upgrading > > your version you are using a version too early for a soft upgrade > > and need to do a HARD UPGRADE. > > > > The PostGIS_Full_Version function should inform you about the need > > to run this kind of upgrade using a "procs need upgrade" message. > > > > By HARD UPGRADE we mean full dump/reload of postgis-enabled > > databases. > > -- > http://about.me/jeremy_schneider > -- Adrian Klaver adrian.klaver@aklaver.com