Documentation ¶
Index ¶
- Constants
- Variables
- type Entry
- type FStab
- func (f *FStab) Add(e Entry, replace bool) error
- func (f *FStab) GetEntries() ([]*Entry, error)
- func (f *FStab) GetEntryByMountPoint(mountpoint string) (*Entry, error)
- func (f *FStab) GetEntryBySource(source string) (*Entry, error)
- func (f *FStab) RemoveByMountPoint(mountpoint string, comment bool) error
Constants ¶
View Source
const ( PassDoNotCheck = 0 PassCheckDuringBoot = 1 PassCheckAfterBoot = 2 DefaultPath = "/etc/fstab" )
Variables ¶
View Source
var ( ErrInvalidFSTabEntry = errors.New("invalid fstab entry") ErrDifferentFSTabEntryWithSameMountPoint = errors.New("a different fstab entry with the same mount point already exists") )
Functions ¶
This section is empty.
Types ¶
type Entry ¶
type Entry struct { // The device name, label, UUID, or other means of specifying the partition or data source this entry refers to. Source string // Where the contents of the device may be accessed after mounting MountPoint string // The type of file system to be mounted. FSType string // Options describing various other aspects of the file system, such as whether it is automatically mounted at boot, which users may mount or access it, whether it may be written to or only read from, its size, and so forth; the special option defaults refers to a pre-determined set of options depending on the file system type. Options string // A number indicating whether and how often the file system should be backed up by the dump program; a zero indicates the file system will never be automatically backed up. Dump int // A number indicating the order in which the fsck program will check the devices for errors at boot time Pass int }
type FStab ¶
type FStab struct {
// contains filtered or unexported fields
}
func (*FStab) GetEntries ¶
func (*FStab) GetEntryByMountPoint ¶
Click to show internal directories.
Click to hide internal directories.