Page 1 of 2
MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Tue Jan 23, 2024 4:16 pm
by Wkmaurom
I've been using various Linux operating systems for about 8-9 months.
On all systems, I use Btrfs.
On Fedora 39, I label the partitions as @ and @home, which are recognized by Timeshift. However, I've never been able to create @ partitions for Btrfs snapshots on MX Linux. As a result, Timeshift, which is included in the system from the start, only gives me the rsync option. How can I solve this? MX Linux for me it would be ideal. I don't really like rolling systems even though I've used openSUSE Tumbleweed a lot. At the same time I don't really like systems that are too static. I often need updated graphics/photography and geological apps and always up-to-date browsers.
So I ask, kindly, could anyone tell me how I can use my MX Linux installations with timeshift btrfs snapshots?
Thanks in advance.
Mauro
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions [Solved]
Posted: Tue Jan 23, 2024 4:55 pm
by fehlix
Wkmaurom wrote: Tue Jan 23, 2024 4:16 pm
So I ask, kindly, could anyone tell me how I can use my MX Linux installations with timeshift btrfs snapshots?
Instead of repeat here a howto, maybe watch this video
Installing MX 21 with btrfs system partition and subvolumes
which would give you an idea, how this can be done within the MX Installer. The current installer is a bit newer,
but the same principle as shown. And timeshift would offer to use btrfs-mode for snapshot operations.
HTH
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Tue Jan 23, 2024 5:12 pm
by couldBworse
@Wkmaurom
the link provided by @fehlix is not the only way to do this.....,but it is the video/tutorial/how-to i followed and found to be the most straight-forward,simple, and direct way to achieve true sub-vols that can be utilized by timeshift....
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Tue Jan 23, 2024 5:27 pm
by Wkmaurom
fehlix wrote: Tue Jan 23, 2024 4:55 pm
Wkmaurom wrote: Tue Jan 23, 2024 4:16 pm
So I ask, kindly, could anyone tell me how I can use my MX Linux installations with timeshift btrfs snapshots?
Instead of repeat here a howto, maybe watch this video
Installing MX 21 with btrfs system partition and subvolumes
which would give you an idea, how this can be done within the MX Installer. The current installer is a bit newer,
but the same principle as shown. And timeshift would offer to use btrfs-mode for snapshot operations.
HTH
Thank you very much
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Tue Jan 23, 2024 8:04 pm
by DukeComposed
An important point that dolphin_oracle makes in this video that may not be well understood is that the btrfs snapshots that Timeshift makes are kept locally on that same btrfs partition, and he underscores that this makes Timeshift useful as a system rollback utility, not a backup solution.
For a backup, you would want to at least export those snapshots to an external location with "btrfs send". That way in the event of a disk failure or when btrfs breaks, you have another copy of that snapshot kept somewhere other than on the broken machine.
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Wed Jan 24, 2024 1:58 am
by Wkmaurom
Thanks a lot to everyone. I had been looking for a solution for months... without success.
As soon as I have some time I'll try and update you.
Thanks
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Wed Jan 24, 2024 5:30 am
by Wkmaurom
I would like to thank everyone. I managed to install MX Linux with the method you indicated and timeshift works great.
Thank you very much @fehlix , @DukeComposed , @couldBworse
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Wed Jan 24, 2024 4:50 pm
by couldBworse
DukeComposed wrote: Tue Jan 23, 2024 8:04 pm
An important point that dolphin_oracle makes in this video that may not be well understood is that the btrfs snapshots that Timeshift makes are kept locally on that same btrfs partition, and he underscores that this makes Timeshift useful as a system rollback utility, not a backup solution.
For a backup, you would want to at least export those snapshots to an external location with "btrfs send". That way in the event of a disk failure or when btrfs breaks, you have another copy of that snapshot kept somewhere other than on the broken machine.
thank you for pointing this out.....
might i humbly/respectfully add that
the external disk should ideally be formatted with Btrfs to utilize the btrfs send and btrfs receive commands effectively, These commands are designed for Btrfs-to-Btrfs interactions, ensuring efficient snapshot transfer and maintaining snapshot integrity.
format:
create and mount:
Code: Select all
mkdir /mnt/external_btrfs
mount /dev/sdX /mnt/external_btrfs
something like......
send:
Code: Select all
btrfs send /mnt/btrfs_root/@snapshots/snapshot_name | sudo btrfs receive /mnt/external_btrfs
Snapshots that you intend to move (send) to another location must be in a read-only state.
Btrfs requires snapshots to be read-only for the btrfs send command to work. mine were not read only....
create read only:
Code: Select all
btrfs subvolume snapshot -r /mnt/btrfs_root/@ /mnt/btrfs_root/@snapshots/snapshot_name
change existing to read only:
Code: Select all
btrfs property set -ts /mnt/btrfs_root/@snapshots/snapshot_name ro true
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Wed Jan 24, 2024 9:24 pm
by DukeComposed
couldBworse wrote: Wed Jan 24, 2024 4:50 pm
might i humbly/respectfully add that
the external disk should ideally be formatted with Btrfs to utilize the btrfs send and btrfs receive commands effectively, These commands are designed for Btrfs-to-Btrfs interactions, ensuring efficient snapshot transfer and maintaining snapshot integrity.
You make a good point. Folks still using btrfs owe it to themselves to understand the peculiarities of btrfs send and receive, which can be described, at best, as "quirky". However, sends do not necessarily require an existing btrfs partition to receive it. If one plans to upload their snapshot to the cloud, for example, one should be able to send a snapshot to a file, "btrfs send my_snapshot > my_backup.btrfs.dat", and then store that .dat file as a single archive of data. It will be unusable in that state until it's received back into a functional btrfs partition, but it's a single file which can be stored anywhere, on any file system.
Re: MX Linux with fs btrfs and timeshift with @root and @home label partitions
Posted: Thu Feb 01, 2024 6:23 pm
by bassplayer69
This is a great topic. I use snapper
Code: Select all
sudo apt install -y snapper inotify-tools
and grub-btrfs
https://github.com/Antynea/grub-btrfs so I can have snapshots automatically made pre and post every time I use apt to install a new package. I use grub-btrfs to be able to boot into a snapshot. I have it setup with systemd, but both work without systemd with a little more work to set it up properly.