From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 04BBEC83005 for ; Wed, 7 Jun 2023 20:20:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232417AbjFGUUG (ORCPT ); Wed, 7 Jun 2023 16:20:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44550 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233068AbjFGUT5 (ORCPT ); Wed, 7 Jun 2023 16:19:57 -0400 X-Greylist: delayed 417 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Wed, 07 Jun 2023 13:19:36 PDT Received: from vps.thesusis.net (vps.thesusis.net [34.202.238.73]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 851B02710 for ; Wed, 7 Jun 2023 13:19:36 -0700 (PDT) Received: by vps.thesusis.net (Postfix, from userid 1000) id 9FFDE1239A0; Wed, 7 Jun 2023 16:12:08 -0400 (EDT) References: <26251cfd-f138-a787-f0e8-528c1c5c6778@gmail.com> User-agent: mu4e 1.7.12; emacs 27.1 From: Phillip Susi To: Bernd Lentes Cc: Andrei Borzenkov , "linux-btrfs@vger.kernel.org" Subject: Re: rollback to a snapshot Date: Wed, 07 Jun 2023 16:08:45 -0400 In-reply-to: Message-ID: <87zg5b821z.fsf@vps.thesusis.net> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-btrfs@vger.kernel.org Bernd Lentes writes: > Could you propose a setup here which does not use top level subvolumes ? > I found it very frustrating that everyone says "BTRFS is great, you can do snapshots and easily rollback". > Because in reality rollback is not easy. How can i avoid to use top level subvolumes ? > I have some Suse boxes which seem to have a correct default setup. But when i install e.g. an Ubuntu box > i really don't know how to setup BTRFS manually. > There was a great Wiki (https://archive.kernel.org/oldwiki/btrfs.wiki.kernel.org/index.php/Main_Page.html), > but now it's outdated. Is there something new ? The last time I installed Ubuntu on btrfs, the installer automatically created a top level subvolume named @ and actually installed the system in that subvolume, then configured grub to tell the kernel to mount the root btrfs volume with the flag subvol="@" so that the system would boot normally. Then you just mount the real root of the filesystem somewhere else and make a snapshot of the @ subvolume. When you want to roll back, you just rename @ to something else, and either rename or create a new writable snapshot from your previous snapshot and name it @, then reboot.