fencing

package
v1.78.1 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2026 License: Apache-2.0 Imports: 20 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

fencing

Hooks of fencing. Their owners are the owners of templates/fencing-agent. The hooks live in node-manager because their input is NodeGroup, Node and the pods of the agent.

Every path of nodeManager.internal.fencing.* has one writer. A hook that writes values runs in the queue /modules/node-manager and is listed in hooks/values_writers_queue_test.go.

  • node_group_modes writes internal.fencing.nodeGroups: the mode of every NodeGroup, as all consumers must read it. Watchdog becomes Slow. off, Notify and unknown values become Disabled. The NodeGroup object stays as the user wrote it.
  • migration_from_1_0 writes internal.fencing.migrationFrom10. The flag is true while a Node with the condition Ready=True has the label node-manager.deckhouse.io/fencing-enabled of fencing 1.0 or runs an agent pod without the node-manager.deckhouse.io/fencing-agent-version label. The traces on a Node that is not Ready do not count: fencing 1.0 can stop a node, and the node keeps the traces while it is off. The hook watches all Nodes, but its filter keeps only the name, the readiness and the label, so the other changes of a Node do not start it. The chart replaces all agents at once while the flag is set.
  • deprecated_settings publishes the metric d8_node_group_fencing_deprecated_settings{name,setting} for every NodeGroup that sets mode: Watchdog (setting="mode") or watchdog.timeout (setting="watchdog.timeout"). The series disappears when the user removes the setting.
  • memberlist_key keeps the Secret fencing-memberlist-key with the memberlist key of the agents. The hook does not write values, because the key must not be in them. It creates the Secret with a new key when no Secret exists and some node group runs an agent. If agents of the current version already work, the key was lost: the hook writes the regeneration time into the Secret annotation node-manager.deckhouse.io/fencing-key-regenerated-at and publishes it as d8_fencing_key_regenerated_timestamp_seconds on every run. The hook never changes an existing Secret. An administrator rotates the key by writing the new key into primary and the old key into secondary.
  • system_network publishes the metric d8_node_manager_system_network_not_found{network} while the SystemNetwork named in the ModuleConfig node-manager does not exist. The hook runs in the queue /modules/node-manager/fencing-system-network, because it writes only metrics. It runs every 30 seconds and when the ModuleConfig or the CRD systemnetworks.network.deckhouse.io changes. It reads the network with a direct GET, so it works while the CRD is absent. An empty name, an existing network and every edition except EE, FE and CSE remove the series. A missing object, group or version sets it. Any other error fails the hook and leaves the series as it is. The hook changes neither the settings nor the ConfigMap of the agents.
  • node_state_cleanup removes the condition Fencing and the annotations node-manager.deckhouse.io/fencing-profile and node-manager.deckhouse.io/fencing-cp-source from every Node when all node groups are Disabled and no agent pod is left in d8-cloud-instance-manager. Helm deletes the DaemonSets in the background, so the hook waits for the pods. Then no agent runs, and the state that the agents left on the Nodes must not show fencing as armed. The hook does not write values, so it runs in the queue /modules/node-manager/fencing-node-state. It does not touch the Nodes while some node group runs agents.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

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