Attachment Lookup#
Workflows → ALAttachment Lookups
The AttachmentLookup workflow searches all selected nodes for an interface configured with a certain IP address. This is useful for debugging purposes, for example when looking for the node with a particular system IP.
Note
This workflow only looks for interfaces that are configured with the IP address. If you want to look for nodes that have a route toward a particular IP address (for example, both sides of a point-to-point link), use the RouteLookup workflow instead.
The workflow input must contain the IP address that a lookup is requested for, and an optional list of nodes to perform the lookup on. If neither the nodeSelectors nor nodes property is specified, the workflow runs on all nodes.
By default, the workflow queries the interfaces of the DefaultRouter. A different router can be specified by using the networkInstance property.
Warning
This workflow does not rely on EDA to do the lookup: it investigates the routing tables on the nodes directly. Currently, only SR Linux nodes are supported. Other operating systems are silently skipped.
Dependencies#
The AttachmentLookup workflow has no dependencies.
Referenced resources#
The AttachmentLookup workflow has no references to any other EDA resources.
Examples#
Example execution
The workflow correctly identified spine-2 as the owner of IP 11.0.0.4
apiVersion: routing.eda.nokia.com/v1
kind: AttachmentLookup
metadata:
annotations:
workflows.core.eda.nokia.com/id: '29'
workflows.core.eda.nokia.com/root-workflow-group: routing.eda.nokia.com
workflows.core.eda.nokia.com/root-workflow-kind: AttachmentLookup
workflows.core.eda.nokia.com/root-workflow-name: attachmentlookup-b9be2e94-0175-425a-bc60-abfd97cc4af1
workflows.core.eda.nokia.com/root-workflow-namespace: eda
workflows.core.eda.nokia.com/root-workflow-version: v1
workflows.core.eda.nokia.com/state: Completed
workflows.core.eda.nokia.com/username: admin
name: attachmentlookup-b9be2e94-0175-425a-bc60-abfd97cc4af1
namespace: eda
spec:
address: 11.0.0.4
nodes:
- leaf-1
- leaf-2
- spine-1
- spine-2
status:
found: true
results:
- interface: system0
networkInstance: default
node: spine-2
workflowStatus:
stages:
- name: Initializing
state: Completed
- name: performing-lookup
state: Completed
state: Completed
Custom Resource Definition#
To browse the Custom Resource Definition go to crd.eda.dev.
AttachmentLookup
SPEC
This workflow is used to look up attachments (where an address is attached in the network) on a set of nodes. It takes an address, and an optional list of nodes (or node selectors - a list of label expressions) to perform the lookup on, and returns the matching attachments, including the node, network instance, prefix, interface, and next hop group ID.
-
Address to perform a lookup for. This is a standard IPv4 or IPv6 address, excluding mask or prefix length, e.g. 12.0.0.1.
-
Network Instance is the locally named network instance to use for the lookup. Can be omitted if the default network instance is to be used.
-
NodeSelectors is a list of node selectors to execute lookups on. This is a list of label expressions, e.g. ["eda.nokia.com/role=leaf", "eda.nokia.com/region=us-west"].
-
Nodes is a list of node names to execute lookups on.
STATUS
AttachmentLookupStatus defines the observed state of AttachmentLookup