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 1m2Fbi-0005RV-N1 for pgsql-general@arkaria.postgresql.org; Sat, 10 Jul 2021 16:13:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1m2Fbh-0000Rk-G4 for pgsql-general@arkaria.postgresql.org; Sat, 10 Jul 2021 16:13:33 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m2Fbh-0000JS-4T for pgsql-general@lists.postgresql.org; Sat, 10 Jul 2021 16:13:33 +0000 Received: from mail-ot1-x330.google.com ([2607:f8b0:4864:20::330]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1m2Fba-0004UH-Om for pgsql-general@lists.postgresql.org; Sat, 10 Jul 2021 16:13:31 +0000 Received: by mail-ot1-x330.google.com with SMTP id j10-20020a05683015cab02904b568e08dccso6823420otr.4 for ; Sat, 10 Jul 2021 09:13:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding:content-language; bh=MIfmjkneiiRdyPDsiOvzME/oDK8Jijf1UlLJB1bZ250=; b=PWk/1bV6oHGbBLoLE1fnZZotUNf1+bSbR6UzLsq7vJeG7APdpH3G1/Pgkni27J7pkd cCXywgtGUxpM7+gi4hZbzRIarH2j55i7Wjg8GaaIlOKfNwBnqBhULpIXSBdVkkJKo5kU Phk/FK5JebhAH0TnxQh/9JHHH+Wr442aeBWYndEoHCsM+VyS1xe4t2DUs5LR9JgBjxlD lVyfPIjE0YT9lzkqxCSnp24RZ4mRJ6gFJ7yKq8jCdSGk2q2/TOgmXj5hlZDO6ebWRun2 6aB/ZMf5LlrFL5o2QQYqICS2BUzyDhYjZDkQ0WSz8HKrZME0z5w1LIgTHnGpucwH+BGj PF7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=MIfmjkneiiRdyPDsiOvzME/oDK8Jijf1UlLJB1bZ250=; b=tGr3Dn9AUjgT3NjC5XR+m+aZnnKAvNnTpD1A8DuZhYiC8KXw/LbNAe15DQb0aXMIaZ +5GV13gb+2oI5Mt+0LosQgGwmVasdYxcPjP3sDVMwpFq1rdw7MRWDuA6Jb5EhYJayTnO JgjzdoNgANMX5XWGYqEpUmbr78XZ//O2mVWgb0WwvaRPmDhtiZkEcuo2F3LT8J0WEr7u XzPCWp8Klfu++hs7OvQKPAw4acwKYp+dE4+hpQhpq6FFJAenKnc6GqOKersx5Qslwha2 7uxNjl7NprdNRVV1RO55nPaM8oLxKXKEAp+3W2qm/PN4hF4ru4c3GpM5a6OM9ESqmIsW icqw== X-Gm-Message-State: AOAM532SL33aKfbT65m6diugZJ2KUmwXv0fO7C1lNUoGAQ8VPzFVMn4J 81sHtvr7ZDoUrHnPLhQ3ip/z/mA1FbgBGA== X-Google-Smtp-Source: ABdhPJwfX5mKz+mQTNKbrgbDbMiPQwBQuZLAtH8uN2Wtji/ogoZCdg43c+MS/KrPvaj+v8No/cqaAw== X-Received: by 2002:a9d:7686:: with SMTP id j6mr33255706otl.232.1625933605484; Sat, 10 Jul 2021 09:13:25 -0700 (PDT) Received: from [192.168.88.10] (ip174-67-141-204.no.no.cox.net. [174.67.141.204]) by smtp.googlemail.com with ESMTPSA id a44sm1611809ooj.12.2021.07.10.09.13.24 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 10 Jul 2021 09:13:25 -0700 (PDT) Subject: Re: Why can't I drop a tablespace? To: pgsql-general@lists.postgresql.org References: <1625857495692@dmwebmail.dmwebmail.chezphil.org> <1625931781020@dmwebmail.dmwebmail.chezphil.org> From: Ron Message-ID: Date: Sat, 10 Jul 2021 11:13:23 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <1625931781020@dmwebmail.dmwebmail.chezphil.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 7/10/21 10:43 AM, Phil Endecott wrote: > Phil Endecott wrote: >> Yesterday I had a disk-nearly-full problem, and decided to try to resolve >> it by moving one large table to a spare disk in a new tablespace: >> >> =# create tablespace tempspace location "/db_temp"; >> =# alter table requests set tablespace tempspace; [snip] > - Is my idea that these files should have been deleted but weren't > during the disk-full panic plausible? > > - If I do move them away, what will Postgres do if it tries to access > them and finds they are missing? Is it well-behaved in this case? > > - If I move them away, I would try to exercise the database (e.g. > do variants of "select sum(column1) from table") in some way to make > sure that it is all functioning. Any suggestions about how best to do > this? I'd shut down postgres, rename those files, and then analyzing the relevant tables after startup.  Probably also run amcheck against the relevant tables' indices. https://access.crunchydata.com/documentation/amcheck-next/1.5/#interface -- Angular momentum makes the world go 'round.