linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* should btrfs reserve some space for root, so a normal user can't cause "no space left" problems?
@ 2021-01-08  7:56  
  2021-01-08  9:46 ` Andrei Borzenkov
  0 siblings, 1 reply; 2+ messages in thread
From:   @ 2021-01-08  7:56 UTC (permalink / raw)
  To: linux-btrfs

I have done a test where I filled up an entire btrfs raid 1 filesystem as a normal user. Then I simulated a failing drive. it turned out I was unable to replace the drive, as raid1 need free space on both drives. See this mail for details [1]

I can understand the technical reasoning behind the requirement of both drives having some free space. But why does btrfs by default allow a normal, non root user to completely fill up the drive? Maybe it's a good idea to reserve some blocks on the filesystem that are only available for the root user, much like ext4 does that (via tune2fs [-m reserved_blocks_percent] and [-r reserved_blocks_count])

[1] https://www.mail-archive.com/linux-btrfs@vger.kernel.org/msg92550.html

---

Take your mailboxes with you. Free, fast and secure Mail & Cloud: https://www.eclipso.eu - Time to change!



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: should btrfs reserve some space for root, so a normal user can't cause "no space left" problems?
  2021-01-08  7:56 should btrfs reserve some space for root, so a normal user can't cause "no space left" problems?  
@ 2021-01-08  9:46 ` Andrei Borzenkov
  0 siblings, 0 replies; 2+ messages in thread
From: Andrei Borzenkov @ 2021-01-08  9:46 UTC (permalink / raw)
  To: Cedric.dewijs, linux-btrfs

08.01.2021 10:56, Cedric.dewijs@eclipso.eu пишет:
> I have done a test where I filled up an entire btrfs raid 1 filesystem as a normal user. Then I simulated a failing drive. it turned out I was unable to replace the drive, as raid1 need free space on both drives. See this mail for details [1]

As explained in this mail, you did not "replace" drive, you added new
drive. This is different operation.

> 
> I can understand the technical reasoning behind the requirement of both drives having some free space. But why does btrfs by default allow a normal, non root user to completely fill up the drive? Maybe it's a good idea to reserve some blocks on the filesystem that are only available for the root user, much like ext4 does that (via tune2fs [-m reserved_blocks_percent] and [-r reserved_blocks_count])
> 
> [1] https://www.mail-archive.com/linux-btrfs@vger.kernel.org/msg92550.html
> 
> ---
> 
> Take your mailboxes with you. Free, fast and secure Mail & Cloud: https://www.eclipso.eu - Time to change!
> 
> 


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-01-08  9:47 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-08  7:56 should btrfs reserve some space for root, so a normal user can't cause "no space left" problems?  
2021-01-08  9:46 ` Andrei Borzenkov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).