Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kAHq7-0001mB-OK for pgsql-admin@arkaria.postgresql.org; Mon, 24 Aug 2020 19:09:07 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kAHq4-0004E7-Ry for pgsql-admin@arkaria.postgresql.org; Mon, 24 Aug 2020 19:09:04 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kAHq4-0004E0-H2 for pgsql-admin@lists.postgresql.org; Mon, 24 Aug 2020 19:09:04 +0000 Received: from mail-qk1-x741.google.com ([2607:f8b0:4864:20::741]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1kAHpx-0002is-D3 for pgsql-admin@postgresql.org; Mon, 24 Aug 2020 19:09:03 +0000 Received: by mail-qk1-x741.google.com with SMTP id g26so8557540qka.3 for ; Mon, 24 Aug 2020 12:08:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :content-transfer-encoding:in-reply-to:user-agent; bh=S4AxhIX9PNfVqddzRnNMkzQ9Wv/JzN7XrRcHsTH6SNU=; b=HWD7FQy7E4UyrZlDT6h+ZGoptQpLPAOH/qsgj6ufENU3T665rMxjFJhs7tBdttS9lR dMEgrM3mClaMgmCy/r+cKpdIp9DKjdnO7NqFIzliHFaWMcvGU24xijPuNfMhfy9ZvSo6 vQZFLmfnW5CdgUudrhUx0F0xa8eNolsdyYrN47SgfCD6XAxqK8oHX45UUoflHTPJtONO YpnqHkcP5wPwJoNOtIGSF4fK2HX47ahc4GirkD0HgFw0A5Hkb0G9iJ1PEMgGHTRdUo4Q a3ofoDEAk/kMHRrCCA6MndNbjWxavSzwn3WtFuWbtn00YMNWtnrvd6hmWjDTZLwdUPoD 37ZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition:content-transfer-encoding:in-reply-to :user-agent; bh=S4AxhIX9PNfVqddzRnNMkzQ9Wv/JzN7XrRcHsTH6SNU=; b=nA/FBJ/N+iiceVrq2APLmizft6UUTDzr6SwbtvE79mYfyhLhXPYLyE6RUPyDO/64v8 Vz28xEWvmyUh2KC5WwHM0C0bjg3E4i8KtErib8wBaxntFDLQlrzaI/yBUm6VnA+C3R72 oUuQLcpKwjbrtmyztvcnvbVdPck03r63xyKY7gg5ADVhTYeBGqUg3ZqRTp2XWqm4k+C5 ceAmqIcabYT92aeKO+MCJUKdnRCZIuZ8fUVrSL6HyouR0FXhmXhcLxFtsIG/wFRL3/VP SzEqFTLIAjh03XJdMYQ4prhyApg2HdTPZ19xGEAlZdVvlv5m89WJtW6ONz2xIHk3aKjZ +jiQ== X-Gm-Message-State: AOAM530HvShHDUDPuo8cgJI2Aqr9Rd5VqKzEN/++oWclRmiMpFAtWoXF xwOxwxnHM7t5hZ+KYw3SdMP1NA== X-Google-Smtp-Source: ABdhPJz5qv1ZjIhak87sAU9yA5H/XlbXVXfSqI0tBy9zUNhmEV5AU8i0vFh2Hf1qnj+/IhzeDl0uKQ== X-Received: by 2002:a37:2d42:: with SMTP id t63mr5426329qkh.99.1598296135804; Mon, 24 Aug 2020 12:08:55 -0700 (PDT) Received: from perhan.alvh.no-ip.org ([190.95.19.47]) by smtp.gmail.com with ESMTPSA id n23sm10066432qkk.105.2020.08.24.12.08.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 24 Aug 2020 12:08:55 -0700 (PDT) Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id 82F822A1689; Mon, 24 Aug 2020 15:08:53 -0400 (-04) Date: Mon, 24 Aug 2020 15:08:53 -0400 From: Alvaro Herrera To: Wells Oliver Cc: pgsql-admin Subject: Re: Odd pg dump error: cache lookup failure Message-ID: <20200824190853.GA14456@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2020-Aug-24, Wells Oliver wrote: > My pg_dump scripts have been bombing lately, and this is the error I see a > bit into the backup process: > > pg_dump: error: query failed: ERROR: cache lookup failed for attribute 1 > of relation 1152770777 What pg version is this, and can you run the query directly using psql and have it throw the same error? What do select * from pg_class where oid = '1152770777' and select * from pg_attribute where attrelid = '1152770777' show? If the latter fails to show an entry for attnum=1, does it magically appear if you do SET enable_indexscan=off; SET enable_bitmapscan=off; prior to running the query? -- Álvaro Herrera https://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services