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 1qDmgS-0003pS-09 for pgsql-admin@arkaria.postgresql.org; Mon, 26 Jun 2023 13:55:12 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1qDmgQ-0007io-OO for pgsql-admin@arkaria.postgresql.org; Mon, 26 Jun 2023 13:55:10 +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 1qDmgQ-0007gg-CQ for pgsql-admin@lists.postgresql.org; Mon, 26 Jun 2023 13:55:10 +0000 Received: from mail-yw1-x112a.google.com ([2607:f8b0:4864:20::112a]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1qDmgN-000ayN-RZ for pgsql-admin@lists.postgresql.org; Mon, 26 Jun 2023 13:55:09 +0000 Received: by mail-yw1-x112a.google.com with SMTP id 00721157ae682-5703cb4bcb4so25420607b3.3 for ; Mon, 26 Jun 2023 06:55:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1687787706; x=1690379706; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=njkoEJbwxpnr4SbRKZIwgj+dHNSLuqdCnGSHI4gDMaM=; b=afBehTIyTyiOvJvnvP6CZyOBTjQhg8NgW1Aqh3xvyfHMTR0i3QkYj/p4tDb5r2OxoF 8lQKbooUsPhsRKh7C3KP+7pvAxQQAXz/HInQsvkthc1YP4PfD8avv92jbep91Ngq48zT MpTn6mthVRQTRjaofLtl28iPNwL613+5mlp7J79DmC2SWUxCuJmiy+3qwanq1xgLivbq ATrqt0+0R/H4IondRsUxwH/SNc9Ogtq009j04ut+hVw0NpwGUGiDh2taUUQhGmyBUZd/ J18PTn16lE/vqMN+XTXgcsPnY1fQmh16CZ1eB23iM4c9VHAvB9BoZi1RioTGY3au39IL Tr6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687787706; x=1690379706; h=content-transfer-encoding:in-reply-to:from:references:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=njkoEJbwxpnr4SbRKZIwgj+dHNSLuqdCnGSHI4gDMaM=; b=eYyLYqJSAw3q3G9ap0/ktdfDQ6zt52m5exlKNQX4dtiOc+uyN88TQYiIDfTe/ro3Q4 9F/s4kgz4aXflFT+2zeaV7nsX107a7y1zQ/0d03uQatje+wOWZlnLpXReG6oZhH4ElEU VILGIScIlDyx3WBTpOK1sXHJGKNVyerW6yrVhER+OZ048bZkGQ+sLK8TbUoxP7eT4vFD MHPOMvFAl/9h7Mjk//ATVXCDtvCMDAPDe56UuTQjKi5g51WuJkwabIoM5qcuYuGczYNn dhhGzqJkj4PeUfi2KftjAX1WykkZGYOf8+FT1zuJz3P25mDv+rrDXSJRRX8pUZ/m5ZKp lKOQ== X-Gm-Message-State: AC+VfDxcbfH4jlDkCWyUFWUyGZjBsqmnEawm9Y/xl7JlrF05mtNTXx60 /+74S041R0wJE1i4HYDHgiwA+ibrGxA= X-Google-Smtp-Source: ACHHUZ6K9JUeoo/dSBKP0BPZN5MtwqLlvCdmrE9HGE8eIeB/L6od3Z170nwDSpfjDpilGvIsR0aovg== X-Received: by 2002:a25:d310:0:b0:bc8:f082:2301 with SMTP id e16-20020a25d310000000b00bc8f0822301mr16155177ybf.6.1687787705889; Mon, 26 Jun 2023 06:55:05 -0700 (PDT) Received: from ?IPV6:2600:1700:bd2c:b810:f8c6:8913:77fd:2653? ([2600:1700:bd2c:b810:f8c6:8913:77fd:2653]) by smtp.googlemail.com with ESMTPSA id c143-20020a25c095000000b00bd74eb95db3sm1169905ybf.16.2023.06.26.06.55.05 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Jun 2023 06:55:05 -0700 (PDT) Message-ID: <29c782b4-9ae3-364d-bca9-44f48c340aa3@gmail.com> Date: Mon, 26 Jun 2023 08:55:05 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: Postgresql Database cant start after restore using pgBackRest Content-Language: en-US To: pgsql-admin@lists.postgresql.org References: <484cbe3c-eb15-5327-df72-3338c17c7855@pgmasters.net> From: Ron In-Reply-To: <484cbe3c-eb15-5327-df72-3338c17c7855@pgmasters.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 6/26/23 08:08, David Steele wrote: > On 6/25/23 18:53, Deo Felix wrote: >>   I am doing backup with pgbackrest in the database server every day at >> night, I was testing to restore the backup in another server, the restore >> was successfully however the database cant start >> >> *pgbackrest --stanza=data --delta --log-level-console=detail restore* > > Usually this happens when you promote a standby while the primary is still > running. The promotion of the standby will create a new timeline (in this > case 2) and then push WAL to the archive on this new timeline. > > When you restore, PostgreSQL will try to recover to timeline 2 (by > default) even though timeline 2 can't be reached from timeline 1 backups > that were made after the promotion. > > So, you need to instruct PostgreSQL to stay on timeline 1 rather than try > to switch to timeline 2. You can do that by setting > --target-timeline=current, i.e. stay on the timeline that was current when > the backup was made. Did I not have this problem because I restored to a different pg-path? -- Born in Arizona, moved to Babylonia.