Hello,
I have just done a fresh installation of Fedora 34 on a new computer and used the automatic disk partitioning proposed by the installer. Now my disk has the following layout: - /boot (ext4) - /boot/efi (EFI system partition) - / (btrfs), with two subvolumes: @root and @home.
In case of a new fresh installation of Fedora, I would like to preserve the @home subvolume only and instead overwrite the rest. However, I am not sure what I should do (note, I don't want to use dnf upgrade).
Just as an experiment, I tried to simulate a fresh (re)installation of Fedora 34 and I selected "Custom" as the disk partitioning method. The installer showed the above disk layout. So, my idea was to use the same approach I used in the past (with ext4 partitions). Specifically: * For the "/boot" and "/boot/efi" partitions, I specified "/boot" and "/boot/efi" as mount points, respectively, and flagged the "Reformat" checkbox. * For the "/home" subvolume, I specified "/home" as the mount point, without flagging the "Reformat" checkbox. * For "/", I cannot tell the installer to reformat it. I am not sure what to do. I would create a new btrfs filesystem with "/" as the mount point, but I am not sure it is correct.
Do you have any suggestions?
Thank you. Marco
On Sun, May 23, 2021 at 11:25 AM Marco Guazzone marco.guazzone@gmail.com wrote:
Hello,
I have just done a fresh installation of Fedora 34 on a new computer and used the automatic disk partitioning proposed by the installer. Now my disk has the following layout:
- /boot (ext4)
- /boot/efi (EFI system partition)
- / (btrfs), with two subvolumes: @root and @home.
In case of a new fresh installation of Fedora, I would like to preserve the @home subvolume only and instead overwrite the rest. However, I am not sure what I should do (note, I don't want to use dnf upgrade).
Just as an experiment, I tried to simulate a fresh (re)installation of Fedora 34 and I selected "Custom" as the disk partitioning method. The installer showed the above disk layout. So, my idea was to use the same approach I used in the past (with ext4 partitions). Specifically:
- For the "/boot" and "/boot/efi" partitions, I specified "/boot" and "/boot/efi" as mount points, respectively, and flagged the "Reformat" checkbox.
- For the "/home" subvolume, I specified "/home" as the mount point, without flagging the "Reformat" checkbox.
- For "/", I cannot tell the installer to reformat it. I am not sure what to do. I would create a new btrfs filesystem with "/" as the mount point, but I am not sure it is correct.
Do you have any suggestions?
There's definitely a trick. The installer normally enforces reformatting a partition/LV for sysroot. Btrfs gets an exception by merely enforcing creation of a new subvolume on an existing Btrfs file system for sysroot. The way to do that is to create a new / mount point rather than clicking on an existing one; also helpful is to not specify a size for this mount point, just leave that 2nd field empty.
There is a test case that describes this in detail and hopefully someone will turn it into a quickdoc. (It's on my to do list but I'm not sure when I'm going to get around to it. https://fedoraproject.org/wiki/QA:Testcase_partitioning_custom_btrfs_preserv...
On Mon, May 24, 2021 at 4:07 AM Chris Murphy lists@colorremedies.com wrote:
On Sun, May 23, 2021 at 11:25 AM Marco Guazzone marco.guazzone@gmail.com wrote:
...
Do you have any suggestions?
There's definitely a trick. The installer normally enforces reformatting a partition/LV for sysroot. Btrfs gets an exception by merely enforcing creation of a new subvolume on an existing Btrfs file system for sysroot. The way to do that is to create a new / mount point rather than clicking on an existing one; also helpful is to not specify a size for this mount point, just leave that 2nd field empty.
There is a test case that describes this in detail and hopefully someone will turn it into a quickdoc. (It's on my to do list but I'm not sure when I'm going to get around to it.
https://fedoraproject.org/wiki/QA:Testcase_partitioning_custom_btrfs_preserv...
Thanks a lot, Chris!
That page is exactly what I was looking for. I followed each step and all went OK. In case that document is targeted also to inexperienced users, I would suggest the following changes: * Step 5: specify to click on "Done" after selecting "Custom" * Step 10: specify how to remove the "root" subvolume, also mentioning what to do when the dialog box "Are you sure you want to delete all of the data on root?" appears.
Thank you. Best regards, Marco