Btrfs filesystem readonly

While trying to back up the last parts of my system, I discovered one reason why I’ll never use Timeshift.

My Btrfs file system is corrupted but mountable (read-only). In read-only mode, I can access everything. I can even transfer every single snapshot of the system using btrfs send. However, Btrfs only allows sending snapshots that are marked as read-only. Luckily, I used snapper, so all snapshots are read-only.

But why use btrfs send instead of rsync -aHXx...?

  • btrfs send doesn’t miss a single bit (you can’t miss the right options).
  • btrfs send is faster.
  • btrfs send can send multiple snapshots, so you can transfer, for example, 50 snapshots of a 90 GB subvolume in such a way that they occupy the same amount of space at the destination as at the source (perhaps only 100 GB). Only 100 GB are actually transferred, and then all 50 snapshots are at the destination.

My lessons:

  • Snapshots can be transferred this way. However, I can back up the writable subvolumes only with rsync (without deduplication).
  • If I had used timeshift, all snapshots would be marked writable, and I wouldn’t be able to send them with btrfs send.
  • Changing the RW attribute of a snapshot is “always” possible, but not if the filesystem is mounted read-only. (Mounting it writable is not possible and is prohibited also generally in the case of a damaged file system)

:footprints:

3 Likes

The measured power consumption

  • in idle mode is approximately 60 watts;
  • under load, it goes up to 95 watts.
    :footprints:

    And I’ve found another way to back up even the latest state of the volumes(/@ /@home /@…) :
  • The last read-only snapshot (/@snapshots/12345/snapshot of /@) on the backup copy is snapshoted with btrfs to a new writable snapshot there with the name /@ . btrfs subvolume snapshot /mnt/dest/@snapshots/12345/snapshot /mnt/dest/@
  • and then synchronized with the volume on the source drive using rsync -acPxXA /mnt/src/@/ /mnt/dest/@/
  • This way the subvolume @ ist rw, and ist connected with all snapshoted, but hast all the newest files from /mnt/src/@ .

:footprints:

Measured from what? (I can use a multimeter to measure it too, but bare wires can scare people.) If are those the actual numbers you are drawing (not a motherboard estimate it’s reading). Still, getting these peak power rates are pretty hard achieve on your own. They happen for brief moments often when you don’t expect, usually with load, but often with chance. (And these are hard to measure.)

This is also an advertised 240W PSU when it was new. Can it do that now?

It’s not just about throttling your CPU and using RAM. Are you writing to all your SSDs at once? Someone said 10W, but they can be much higher with writes and clears.

With my PSU, I don’t care about hubs, but in your case those add up. (I think my old USB2 unpowered hubs draw max 5W, but newer USB3 and especially USB3 Type-C hubs, it can be much higher (especially with a rated PD).

Remember this ~100W, can spike higher when all your components spike in power at once. This can be very hard to achieve on your own with just benchmarking utils and the like. Just having everything spike once, can have some adverse side effects. As you have might have found? Still speculation. But a likely one it seems.


I’ve done 1000s.. Just type this first.

sudo btrfs set prop /mnt/timeshift-btrfs/snapshots/YYYY-MM-DD_HH-MM-SS/@ ro true

With problems, there was always a way too.

But you send them to another btrfs file system. Timeshift has nothing to do with this. (For me it’s just automated/incrementals over ssh, or I do big one off jobs through nc.) And volumes appear on my remote backup FS as ro (the default of the receive end).

Plus, the problem you had, doesn’t care about btrfs snapshot read only flags. It’s writing regardless. The security of read only volumes, assumes you have working hardware.

We always circle back to this.. But Timeshift doe not use rsync! (Unless you have ext4, or force it to ext4 mode on btrfs.)

2 Likes

Power-meter Like kill a Watt
(My. Education ist in electronics, and i Work in combined Software/Hardware engineering)
These are medium mesurements. Peak May bei twice. And i found that i missread the Label. It is 420Watt (Not 240) :rofl:

Bequiet says my PC may use maximal 260watt and needs at least a 300Watt NT
But i will by a new one with at least 550Watt