btrfs

package
v3.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 1, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const TopSubVol = "@"

Variables

This section is empty.

Functions

func CreateQuotaGroup

func CreateQuotaGroup(s *sys.System, path, qGroup string) error

CreateQuotaGroup creates the given quota group for the btrfs filesystem, path is usually the mountpoint of the btrfs filesystem

func CreateSnapshot

func CreateSnapshot(s *sys.System, path, base string, copyOnWrite bool) error

CreateSnapshot creates a btrfs snapshot to the given path from the given base

func CreateSubvolume

func CreateSubvolume(s *sys.System, path string, copyOnWrite bool) error

CreateSubvolume creates a btrfs subvolume to the given path

func DeleteSubvolume

func DeleteSubvolume(s *sys.System, path string) error

DeleteSubvolume removes the given subvolume. Before removing the subvolume it sets the RW property to ensure it can be deleted, if deletion fails the property change remains applied.

func EnableQuota

func EnableQuota(s *sys.System, path string) error

EnableQuota enables btrfs quota the btrfs filesystem, path is usually the mountpoint of the btrfs filesystem

func NoCopyOnWrite

func NoCopyOnWrite(s *sys.System, path string) error

NoCopyOnWrite disables copy on write to the given subvolume

func SetBtrfsPartition

func SetBtrfsPartition(s *sys.System, path string) error

SetBtrfsPartition configures toplevel subvolume, enables quota sets the quota group 1/0, and defines the toplevel subvolume as the default subvolume. Path is the mountpoint of the btrfs filesystem.

func SetDefaultSubvolume

func SetDefaultSubvolume(s *sys.System, path string) error

SetDefaultSubvolume sets the given subvolume as the default subvolume to mount

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL