volume

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2020 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type VolAPIImplementor

type VolAPIImplementor struct{}

VolAPIImplementor - struct for implementing the internal Volume APIs

func New

func New() VolAPIImplementor

New - Construct a new Volume API Implementation.

func (VolAPIImplementor) DismountVolume

func (VolAPIImplementor) DismountVolume(volumeID, path string) error

DismountVolume - unmounts the volume path by removing the partition access path

func (VolAPIImplementor) FormatVolume

func (VolAPIImplementor) FormatVolume(volumeID string) (err error)

FormatVolume - Format a volume with a pre specified filesystem (typically ntfs)

func (VolAPIImplementor) GetVolumeDiskNumber added in v0.2.0

func (VolAPIImplementor) GetVolumeDiskNumber(volumeID string) (int64, error)

GetVolumeDiskNumber - gets the disk number where the volume is.

func (VolAPIImplementor) GetVolumeIDFromMount added in v0.2.0

func (VolAPIImplementor) GetVolumeIDFromMount(mount string) (string, error)

GetVolumeIDFromMount - gets the volume ID given a mount point, the function is recursive until it find a volume or errors out

func (VolAPIImplementor) IsVolumeFormatted

func (VolAPIImplementor) IsVolumeFormatted(volumeID string) (bool, error)

IsVolumeFormatted - Check if the volume is formatted with the pre specified filesystem(typically ntfs).

func (VolAPIImplementor) ListVolumesOnDisk

func (VolAPIImplementor) ListVolumesOnDisk(diskID string) (volumeIDs []string, err error)

ListVolumesOnDisk - returns back list of volumes(volumeIDs) in the disk (requested in diskID).

func (VolAPIImplementor) MountVolume

func (VolAPIImplementor) MountVolume(volumeID, path string) error

MountVolume - mounts a volume to a path. This is done using the Add-PartitionAccessPath for presenting the volume via a path.

func (VolAPIImplementor) ResizeVolume

func (VolAPIImplementor) ResizeVolume(volumeID string, size int64) error

ResizeVolume - resizes a volume with the given size, if size == 0 then max supported size is used

func (VolAPIImplementor) VolumeStats added in v0.2.0

func (VolAPIImplementor) VolumeStats(volumeID string) (int64, int64, error)

VolumeStats - retrieves the volume stats for a given volume

func (VolAPIImplementor) WriteVolumeCache added in v0.2.2

func (VolAPIImplementor) WriteVolumeCache(volumeID string) (err error)

WriteVolumeCache - Writes the file system cache to disk with the given volume id

Jump to

Keyboard shortcuts

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