Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1v3qIm-004SMn-Mg for pgsql-hackers@arkaria.postgresql.org; Wed, 01 Oct 2025 06:27:00 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1v3qIj-00G7Vu-EW for pgsql-hackers@arkaria.postgresql.org; Wed, 01 Oct 2025 06:26:58 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1v3qIj-00G7UU-3Q for pgsql-hackers@lists.postgresql.org; Wed, 01 Oct 2025 06:26:57 +0000 Received: from mail-ed1-x529.google.com ([2a00:1450:4864:20::529]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1v3qIg-000oyu-2v for pgsql-hackers@lists.postgresql.org; Wed, 01 Oct 2025 06:26:56 +0000 Received: by mail-ed1-x529.google.com with SMTP id 4fb4d7f45d1cf-6318855a83fso12843710a12.2 for ; Tue, 30 Sep 2025 23:26:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1759300012; x=1759904812; darn=lists.postgresql.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=x5//hZKB8BpFlyxM1SuCYlY1rf6qtCCgkXW4ZJuWKCw=; b=n7ToW83XpKMXoE6sQ3ABC1K2IDHkVJVXxwXJPbxOdkCD36HJs8U5zPO57Dee+jm5eE LrcolpaLJvqPCykIfu4XGifROERvSl4s5qqWSbu8Fa9YVUMYdhjlnpkPv7NWoiUHia7U Ctr/HitU4SpbwNhrKgRQJQwdhh0eer4YgbidY2sbg2dUFxNoBhyUpJtZGCcZfLY26LB+ zRJN/4j7nWqa1uwKzmbPFxzxjphfWwFUZ8GhMvPbiU7mOM1APxepzWVKwKtNSoxG1v3U ZxCqAGGuVWIOJnNQS6VMNGrqYBsIB/LoJR+5+KjlECoKpRDU/rMIjj1aT+ZHVgfjJ0I9 Kv7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1759300012; x=1759904812; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=x5//hZKB8BpFlyxM1SuCYlY1rf6qtCCgkXW4ZJuWKCw=; b=w0rei8Y3BhzLhNdaTVCF1XWqhFM6kB7FChP2iyVcu20d+JxJ+TOi/HnuYIaPM8y6RZ DKJYqQRprlG1q/GzsTQzkXIFcQ4fat/y3SIIcRQB2ZDnOk8ohs5ur5hEGVPjMcCITAtC PN7FUfEIUJeoNOrkNKWv4yDeIl4JoDISZXqUamzoBhSw4r10xQzndfU/EJUvu4dprLVZ 9cweiuGEw8iDy/Xn5Upx/6zEP018Lgs/UPj5tCDVxN2LKPu2+KKW2boZplFAPfvqJmDh QAkay8dpwFZEwu8g9X9hZlNZGYGOs4hFqzqyG8dSOR/knkwQ6QyP1EdYYJVrPi3WFwk2 rGpg== X-Gm-Message-State: AOJu0YxMCfEfni9x49mUkr+5Wwhxwm/HFSWFiB4YNnl1GSQHWpluuVx4 3ifCo5yf9GKlAs1JDBnWY++0QQErSSDgCapHilXEr769jDeYcBv4Ckzn6gpN2bUtVQg= X-Gm-Gg: ASbGnctLGr+OdZbSSgHXpZLBxN2+EhqzKPElExoRcLhdJ19ZwCbRIAmSwVbjoeq/ZaY r5UHj+M3CrQjP80kn+TI9ogslCJMwAHbLmS0PvP1x55xDOCQzs3JHRTtLNO6H7ySKyUGoWxnOJD xsIOXIiMwUtjf4wlsd62emyAyFwlLzU2OKqSA7L1kzkm0Oau3WJZAcwrdOp2Sp8UuroVveB//m1 3WhUj5MQsMwFdN0c19eRYO/uPLQmiURxVo0y+Nph1iw1+gOpZXW9P1yuP8VEuzjTbhweSTYC0gm +tX9R0wypknIjH4fSuBQ13A6JFUnQljoNOmAhlY2hVeJ0zZMGN4KbXtWf+mgh0bHBZn+EM8Z/ch UaLVGfQ4NkwVknnSIsaPTJ9Nr/DZQlfpZ3IS51rAJz08zG/8= X-Google-Smtp-Source: AGHT+IHsR6SaOVlkFJRPgTS471EXnmihpLWVuk4VKVKc5LWC5Y5GrYKH0cjUEZ49K0F2MKcce5iPbQ== X-Received: by 2002:a05:6402:4404:b0:634:5705:5719 with SMTP id 4fb4d7f45d1cf-63678c0de34mr2650841a12.5.1759300011968; Tue, 30 Sep 2025 23:26:51 -0700 (PDT) Received: from laurenz.albe-K4N0CV00F97414D ([213.208.157.89]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-63662dc0a3csm2816516a12.48.2025.09.30.23.26.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Sep 2025 23:26:51 -0700 (PDT) Message-ID: <45b3a1dd6be28dd409850a5503c029a97ca0754e.camel@cybertec.at> Subject: Re: The ability of postgres to determine loss of files of the main fork From: Laurenz Albe To: Aleksander Alekseev , Frits Hoogland Cc: pgsql-hackers@lists.postgresql.org Date: Wed, 01 Oct 2025 08:26:50 +0200 In-Reply-To: References: <013D63E2-5D75-492E-85FF-1D5CC0148C82@gmail.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.56.2 (3.56.2-2.fc42) MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Tue, 2025-09-30 at 18:55 +0300, Aleksander Alekseev wrote: > > Therefore, I would like to request an enhancement: add an option to > > verify_heapam() that causes the primary key index to be scanned and mak= es > > sure that all line pointers in the index point to existing tuples. >=20 > I'm a bit puzzled by your emphasis on primary keys. In Postgres it is > legal to have tables without PKs, indexes, or even columns: >=20 > =3D# create table my_table(); > =3D# select * from my_table; >=20 > To clarify, are you proposing not to check such tables? If there is no index on a table, there is no way to determine a missing segment. I don't think that Frits deliberately wants to *not* check such tables, it's just that there is no way to do it as things are now. Just because a check is not possible in certain cases is no good reason to forgo a check in those cases where it is possible. Yours, Laurenz Albe