Documentation ¶
Index ¶
- func CanConnect() bool
- func CheckAndSetConnect(nodes []string) error
- func CreateReplica(address string, uuid string, size uint64, pool string) error
- func CreateReplicaExt(address string, uuid string, size uint64, pool string, thin bool) error
- func DestroyAllPools(addrs []string) error
- func DestroyPool(name, addr string) error
- func FaultNexusChild(address string, Uuid string, Uri string) error
- func FindReplicas(uuid string, addrs []string) ([]v0MayastorReplica, error)
- func GetPool(name, addr string) (*v0MayastorPool, error)
- func ListNvmeControllers(addrs []string) ([]v0NvmeController, error)
- func ListPools(addrs []string) ([]v0MayastorPool, error)
- func ListReplicas(addrs []string) ([]v0MayastorReplica, error)
- func RmNodeReplicas(addrs []string) error
- func RmReplica(address string, uuid string) error
- func ShareBdev(address string, bdevUuid string) (string, error)
- func UnshareBdev(address string, bdevUuid string) error
- type V0MayastorNexus
- type V0RebuildStatsReply
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CanConnect ¶
func CanConnect() bool
CanConnect retrieve the cached connectable state to Mayastor instances on the cluster under test
func CheckAndSetConnect ¶
CheckAndSetConnect call to cache connectable state to Mayastor instances on the cluster under test Just dialing does not work, we need to make a simple gRPC call (GetMayastorInfo)
func CreateReplica ¶
CreateReplica create a replica on a mayastor node, with parameters
thin fixed to false and share fixed to NVMF. Other parameters must be specified
func CreateReplicaExt ¶
CreateReplicaExt create a replica on a mayastor node
func DestroyAllPools ¶
func DestroyPool ¶
func FindReplicas ¶
FindReplicas given a list of node ip addresses, enumerate the set of replicas on mayastor using gRPC on each of those nodes returns accumulated errors if gRPC communication failed.
func ListNvmeControllers ¶
ListNvmeControllers given a list of node ip addresses, enumerate the set of nvmeControllers on mayastor using gRPC on each of those nodes returns accumulated errors if gRPC communication failed.
func ListPools ¶
ListPools given a list of node ip addresses, enumerate the set of pools on mayastor using gRPC on each of those nodes returns accumulated errors if gRPC communication failed.
func ListReplicas ¶
ListReplicas given a list of node ip addresses, enumerate the set of replicas on mayastor using gRPC on each of those nodes returns accumulated errors if gRPC communication failed.
func RmNodeReplicas ¶
RmNodeReplicas given a list of node ip addresses, delete the set of replicas on mayastor using gRPC on each of those nodes returns errors if gRPC communication failed.
func UnshareBdev ¶
UnshareBdev unshare a bdev with uuid
Types ¶
type V0MayastorNexus ¶
type V0MayastorNexus struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Uuid string `protobuf:"bytes,1,opt,name=uuid,proto3" json:"uuid,omitempty"` Size uint64 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` State mayastorGrpc.NexusState `protobuf:"varint,3,opt,name=state,proto3,enum=mayastor.NexusState" json:"state,omitempty"` Children []*mayastorGrpc.Child `protobuf:"bytes,4,rep,name=children,proto3" json:"children,omitempty"` DeviceUri string `protobuf:"bytes,5,opt,name=device_uri,json=deviceUri,proto3" json:"device_uri,omitempty"` Rebuilds uint32 `protobuf:"varint,6,opt,name=rebuilds,proto3" json:"rebuilds,omitempty"` }
V0MayastorNexus Mayastor Nexus data
func FindNexus ¶
func FindNexus(uuid string, addrs []string) (*V0MayastorNexus, error)
FindNexus given a list of node ip addresses, return the V0MayastorNexus with matching uuid returns accumulated errors if gRPC communication failed.
func ListNexuses ¶
func ListNexuses(addrs []string) ([]V0MayastorNexus, error)
ListNexuses given a list of node ip addresses, enumerate the set of nexuses on mayastor using gRPC on each of those nodes returns accumulated errors if gRPC communication failed.
func (V0MayastorNexus) GetChildren ¶
func (msn V0MayastorNexus) GetChildren() []v0MayastorNexusChild
func (V0MayastorNexus) GetSize ¶
func (msn V0MayastorNexus) GetSize() uint64
func (V0MayastorNexus) GetStateString ¶
func (msn V0MayastorNexus) GetStateString() string
func (V0MayastorNexus) GetString ¶
func (msn V0MayastorNexus) GetString() string
func (V0MayastorNexus) GetUuid ¶
func (msn V0MayastorNexus) GetUuid() string
type V0RebuildStatsReply ¶
type V0RebuildStatsReply struct { BlocksTotal uint64 `protobuf:"varint,1,opt,name=blocks_total,json=blocksTotal,proto3" json:"blocks_total,omitempty"` // total number of blocks to recover BlocksRecovered uint64 `protobuf:"varint,2,opt,name=blocks_recovered,json=blocksRecovered,proto3" json:"blocks_recovered,omitempty"` // number of blocks recovered Progress uint64 `protobuf:"varint,3,opt,name=progress,proto3" json:"progress,omitempty"` // rebuild progress % SegmentSizeBlks uint64 `protobuf:"varint,4,opt,name=segment_size_blks,json=segmentSizeBlks,proto3" json:"segment_size_blks,omitempty"` // granularity of each recovery copy in blocks BlockSize uint64 `protobuf:"varint,5,opt,name=block_size,json=blockSize,proto3" json:"block_size,omitempty"` // size in bytes of each block TasksTotal uint64 `protobuf:"varint,6,opt,name=tasks_total,json=tasksTotal,proto3" json:"tasks_total,omitempty"` // total number of concurrent rebuild tasks TasksActive uint64 `protobuf:"varint,7,opt,name=tasks_active,json=tasksActive,proto3" json:"tasks_active,omitempty"` // number of current active tasks }
func GetRebuildStats ¶
func GetRebuildStats(uuid string, dstUri string, addrs string) (V0RebuildStatsReply, error)
GetRebuildStats given a node ip address, return the V0RebuildHistory with matching uuid and uri returns accumulated errors if gRPC communication failed.