Documentation ¶
Index ¶
- func BannedCPUs(node corev1.Node) (banned cpuset.CPUSet, err error)
- func ExecCommandOnMachineConfigDaemon(node *corev1.Node, command []string) ([]byte, error)
- func ExecCommandOnNode(cmd []string, node *corev1.Node) (string, error)
- func GetByCpuAllocatable(nodesList []corev1.Node, cpuQty int) []corev1.Node
- func GetByLabels(nodeLabels map[string]string) ([]corev1.Node, error)
- func GetByName(nodeName string) (*corev1.Node, error)
- func GetByRole(role string) ([]corev1.Node, error)
- func GetBySelector(selector labels.Selector) ([]corev1.Node, error)
- func GetDefaultSmpAffinitySet(node *corev1.Node) (cpuset.CPUSet, error)
- func GetKubeletConfig(node *corev1.Node) (*kubeletconfigv1beta1.KubeletConfiguration, error)
- func GetMachineConfigDaemonByNode(node *corev1.Node) (*corev1.Pod, error)
- func GetNonPerformancesWorkers(nodeSelectorLabels map[string]string) ([]corev1.Node, error)
- func GetNumaNodes(node *corev1.Node) (map[int][]int, error)
- func GetOnlineCPUsSet(node *corev1.Node) (cpuset.CPUSet, error)
- func GetSMTLevel(cpuID int, node *corev1.Node) int
- func HasPreemptRTKernel(node *corev1.Node) error
- func MatchingOptionalSelector(toFilter []corev1.Node) ([]corev1.Node, error)
- func TunedForNode(node *corev1.Node, sno bool) *corev1.Pod
- type NodeCPU
- type NumaNodes
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExecCommandOnMachineConfigDaemon ¶
ExecCommandOnMachineConfigDaemon returns the output of the command execution on the machine-config-daemon pod that runs on the specified node
func ExecCommandOnNode ¶
ExecCommandOnNode executes given command on given node and returns the result
func GetByCpuAllocatable ¶
func GetByLabels ¶
GetByLabels returns all nodes with the specified labels
func GetBySelector ¶
GetBySelector returns all nodes with the specified selector
func GetDefaultSmpAffinitySet ¶
GetDefaultSmpAffinitySet returns the default smp affinity mask for the node
func GetKubeletConfig ¶
func GetKubeletConfig(node *corev1.Node) (*kubeletconfigv1beta1.KubeletConfiguration, error)
GetKubeletConfig returns KubeletConfiguration loaded from the node /etc/kubernetes/kubelet.conf
func GetMachineConfigDaemonByNode ¶
GetMachineConfigDaemonByNode returns the machine-config-daemon pod that runs on the specified node
func GetNonPerformancesWorkers ¶
GetNonPerformancesWorkers returns list of nodes with non matching perfomance profile labels
func GetNumaNodes ¶
GetNumaNodes returns the number of numa nodes and the associated cpus as list on the node
func GetOnlineCPUsSet ¶
GetOnlineCPUsSet returns the list of online (being scheduled) CPUs on the node
func GetSMTLevel ¶
GetSMTLevel returns the SMT level on the node using the given cpuID as target Use a random cpuID from the return value of GetOnlineCPUsSet if not sure
func HasPreemptRTKernel ¶
HasPreemptRTKernel returns no error if the node booted with PREEMPT RT kernel
func MatchingOptionalSelector ¶
MatchingOptionalSelector filter the given slice with only the nodes matching the optional selector. If no selector is set, it returns the same list. The NODES_SELECTOR must be set with a labelselector expression. For example: NODES_SELECTOR="sctp=true" Inspired from: https://github.com/fedepaol/sriov-network-operator/blob/master/test/util/nodes/nodes.go