Questions tagged [btrfs]

A volume-managing, snapshot-supporting copy-on-write (COW) filesystem included in the Linux kernel.

822 questions
21
votes
5 answers

Is there a way to monitor progress of a btrfs rebalance?

I'm replacing a failed harddrive in a mirrored btrfs. btrfs device delete missing /[mountpoint] is taking very long, so I assume that it's actually rebalancing data across to the replacement drive. Is there any way to monitor the progress of such an…
user50849
  • 5,202
18
votes
1 answer

How does enabling btrfs quotas impact the system?

I use btrfs snapshots quite a bit, and one of the things that interests me is how much space a given snapshot takes up - or to be more specific - how much exclusive data a btrfs snapshot is taking up, so that I know if I delete the snapshot, how…
Tal
  • 2,112
14
votes
3 answers

Why can't a regular user delete a btrfs subvolume

Using a loop-mounted user created btrfs filesystem, with the permissions set correcly, a user is able to freely create btrfs subvolumes: user@machine:~/btrfs/fs/snapshots$ /sbin/btrfs sub create newsubvol Create subvolume './newsubvol' However,…
loopbackbee
  • 4,602
14
votes
1 answer

How much space would be freed by removing a btrfs subvolume?

Is there any way to calculate how much space I would free if I would remove one (or several) subvolumes on a Btrfs disk (without actually removing them)? I know that there is "currently no code that will do the calculation for you", but how would…
Hjulle
  • 317
13
votes
3 answers

How do I expand btrfs metadata?

My btrfs metadata is getting full. (I'm creating hourly snapshots using btrbk.) How do I increase / extend the space allocated to the metadata of a btrfs filesystem? Or is it automatically expanded?
Tom Hale
  • 30,455
11
votes
4 answers

How can I check if btrfs send / receive worked properly?

btrfs send and receive can be used to transfer terabytes of data, but these commands don't produce helpful progress output (even with -v). How can I check if they succeeded? For example, if I create a new subvolume called source, write 1 GB of…
sjy
  • 896
11
votes
2 answers

Show mounted btrfs subvolumes?

Is there a command to show which btrfs subvolumes are mounted on each mountpoint? Alternatively, is there somewhere (e.g. in the /proc or /sys trees) where the information can be read? The output from the df command simply shows the filesystem's…
StarNamer
  • 3,162
10
votes
2 answers

Get size of btrfs directory which may contain subvolumes

The usual way to get directory size is: du -hs /path/to/directory However, it's not working and I suspect it's a btrfs issue. It's reporting that the size of a subdirectory with submodules is more than the total size of the disk itself. However I'm…
10
votes
5 answers

How to repair a BTRFS block?

For some unknown reasons, my BTRFS filesystem is corrupted. dmesg prints BTRFS critical (device sda2): corrupt leaf, slot offset bad: block=43231330304,root=1, slot=47 (more than 1000x in the dmesg trace). How to repair block #43231330304?
9
votes
3 answers

Tiered storage with BTRFS - how is it done?

NETGEAR uses BTRFS in their ReadyNAS OS, and implements Tiered Storage in their latest versions. They started with "Metadata" tier only in ReadyNAS v6.9, and then added "Data Tier" in v6.10. The system uses SSDs as Tier-0 to speed up access to the…
9
votes
3 answers

`btrfs check --force` without --repair on a mounted device

I try to check the device containing /home and see: $ sudo btrfs check --force /dev/vg_svelte/home WARNING: filesystem mounted, continuing because of --force ERROR: cannot open device '/dev/vg_svelte/home': Device or resource busy ERROR: cannot open…
Tom Hale
  • 30,455
9
votes
3 answers

How to replace a device in BTRFS RAID-1 filesystem?

I have a BTRFS RAID-1 filesystem with 2 legs. One disk needs to be replaced because of re-occuring read errors. Thus, the plan is: add a 3rd leg -> result should be: 3 way mirror remove the faulty disk -> result should be: 2 way mirror Thus, I did…
maxschlepzig
  • 57,532
8
votes
1 answer

Can btrfs handle different RAID levels for different subvolumes?

I'd like to assign different RAID levels to different subvolumes in my btrfs filesystem, eg have a subvolume /home that uses RAID 1 and a subvolume /var that uses RAID 0. Is that at all possible (if so, how?) or do I have to rely on separate…
Marcus
  • 243
  • 3
  • 5
8
votes
4 answers

Btrfs subvolume questions

Just a few questions about Btrfs: Do I have to mount a Btrfs filesystem before creating subvolumes on it? Can I easily convert an existing directory into a subvolume? (i.e. if I want to make "/home" a separate subvolume can I just go…
Clinton
  • 729
8
votes
2 answers

btrfs found uncorrected disk errors, How can I find which files they are in?

I ran btrfs scrub and got this: scrub status for 57cf76da-ea78-43d3-94d3-0976308bb4cc scrub started at Wed Mar 15 10:30:16 2017 and finished after 00:16:39 total bytes scrubbed: 390.45GiB with 28 errors error details: csum=28 …
1
2 3
8 9