block

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2016 License: Apache-2.0 Imports: 13 Imported by: 28

Documentation

Overview

block provides the implementation of the "block" volume type, using a Torus file as a block device.

Index

Constants

View Source
const VolumeType = "block"

Variables

This section is empty.

Functions

func CreateBlockVolume

func CreateBlockVolume(mds torus.MetadataService, volume string, size uint64) error

func DeleteBlockVolume added in v0.1.0

func DeleteBlockVolume(mds torus.MetadataService, volume string) error

func NewBlockVolGC

func NewBlockVolGC(srv *torus.Server, inodes gc.INodeFetcher) (gc.GC, error)

Types

type BlockFile

type BlockFile struct {
	*torus.File
	// contains filtered or unexported fields
}

func (*BlockFile) Close

func (f *BlockFile) Close() (err error)

func (*BlockFile) Sync

func (f *BlockFile) Sync() error

type BlockVolume

type BlockVolume struct {
	// contains filtered or unexported fields
}

func OpenBlockVolume

func OpenBlockVolume(s *torus.Server, volume string) (*BlockVolume, error)

func (*BlockVolume) DeleteSnapshot added in v0.1.0

func (s *BlockVolume) DeleteSnapshot(name string) error

func (*BlockVolume) GetSnapshots added in v0.1.0

func (s *BlockVolume) GetSnapshots() ([]Snapshot, error)

func (*BlockVolume) OpenBlockFile

func (s *BlockVolume) OpenBlockFile() (file *BlockFile, err error)

func (*BlockVolume) OpenSnapshot added in v0.1.0

func (s *BlockVolume) OpenSnapshot(name string) (*BlockFile, error)

func (*BlockVolume) RestoreSnapshot added in v0.1.1

func (s *BlockVolume) RestoreSnapshot(name string) (err error)

func (*BlockVolume) SaveSnapshot added in v0.1.0

func (s *BlockVolume) SaveSnapshot(name string) error

type Snapshot added in v0.1.0

type Snapshot struct {
	Name     string
	When     time.Time
	INodeRef []byte
}

Directories

Path Synopsis
aoe provides the implementation of an ATA over Ethernet server, backed by a Torus block volume.
aoe provides the implementation of an ATA over Ethernet server, backed by a Torus block volume.

Jump to

Keyboard shortcuts

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