link

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 23, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterRouterLink(router *mux.Router)

Types

type Link struct {
	Action  string   `json:"Action"`
	Name    string   `json:"Name"`
	MTU     string   `json:"MTU"`
	Kind    string   `json:"Kind"`
	Mode    string   `json:"Mode"`
	Enslave []string `json:"Enslave"`
}

type LinkInfo

type LinkInfo struct {
	Index            int                     `json:"Index"`
	Mtu              int                     `json:"MTU"`
	TxQLen           int                     `json:"TxQLen"`
	Name             string                  `json:"Name"`
	AlternativeNames string                  `json:"AlternativeNames"`
	HardwareAddr     string                  `json:"HardwareAddr"`
	Flags            string                  `json:"Flags"`
	RawFlags         uint32                  `json:"RawFlags"`
	ParentIndex      int                     `json:"ParentIndex"`
	MasterIndex      int                     `json:"MasterIndex"`
	Namespace        string                  `json:"Namespace"`
	Alias            string                  `json:"Alias"`
	Statistics       *netlink.LinkStatistics `json:"Statistics"`

	Promisc int `json:"Promisc"`
	Xdp     struct {
		Fd       int  `json:"Fd"`
		Attached bool `json:"Attached"`
		Flags    int  `json:"Flags"`
		ProgID   int  `json:"ProgId"`
	} `json:"Xdp"`
	EncapType   string `json:"EncapType"`
	Protinfo    string `json:"Protinfo"`
	OperState   string `json:"OperState"`
	NetNsID     int    `json:"NetNsID"`
	NumTxQueues int    `json:"NumTxQueues"`
	NumRxQueues int    `json:"NumRxQueues"`
	GSOMaxSize  uint32 `json:"GSOMaxSize"`
	GSOMaxSegs  uint32 `json:"GSOMaxSegs"`
	Group       uint32 `json:"Group"`
	Slave       string `json:"Slave"`
}
func AcquireLinks() ([]LinkInfo, error)

Jump to

Keyboard shortcuts

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