This is a thin layer over MicroOVN, to allow MicroOVN to be used within the charm ecosystem.
This is to be deployed alongside microcluster-token-distributor for cluster management.
An example deployment looks something like this:
juju deploy microovn -n 3
juju deploy microcluster-token-distributor
juju relate microovn microcluster-token-distributorThis will give you 3 MicroOVN nodes, that should set up a stable cluster using the microcluster-token-distributor.
The charm initializes every node with a YAML preseed for microovn init,
using the local addresses selected by Juju for these bindings:
cluster: MicroOVN cluster/quorum communication and OVN database endpoints.data: GENEVE tunnel encapsulation between chassis.
For example, with existing Juju spaces named management and underlay:
juju deploy microovn -n 3 --bind "cluster=management data=underlay"
juju deploy microcluster-token-distributor
juju relate microovn:cluster microcluster-token-distributorNo space setup is needed for the basic deployment above. Without --bind,
Juju supplies addresses from the model’s default space (normally alpha).
On a single-network machine, cluster and GENEVE traffic use the same local
address. You do not need to create spaces or configure IP addresses manually.
Bindings without an explicit space inherit the application’s default. To use
one network for both purposes, bind both endpoints to that space, or set the
application default with --bind management. Binding only cluster does not
change the default used by data, and vice versa.
The bootstrap node and joining nodes use the same binding rules, including when multiple MicroOVN applications share a token distributor. Bind each application to mutually reachable cluster networks and mutually reachable data networks, with a compatible address family for each purpose. Subnets may differ across nodes when routing connects them. The charm uses Juju’s selected bind address, including IPv6, rather than choosing an interface by name or assuming that the first NIC is the underlay. Missing or unusable binding addresses block initialization instead of falling back to another network.
Set bindings before relating the token distributor. These addresses are initialization settings: changing a space binding or upgrading an existing cluster does not migrate its running cluster or tunnel addresses. Preseed support is required in the selected MicroOVN snap revision.
MicroOVN supports a couple of useful relations:
ovsdb: which exposes the connection strings for the ovs northbound and southbound databases.tls-certificates: which integrates with a certificate provider and then adds the application certificate provided into the chain for the certificates it issues to the MicroOVN units allowing for other applications to properly interface with it.cos-agent: which exchanges information on several observability-related data streams at once.
This charm integrates with the Canonical Observability Stack (COS) using the Opentelemtry Collector.
Prerequisites:
- A machine model for MicroOVN and Grafana Agent.
- A Kubernetes model with COS Lite deployed. See COS Lite documentation for details.
Steps:
- Deploy OpenTelemetry Collector in the machine model:
juju deploy opentelemetry-collector --channel=2/stable- Relate MicroOVN to OpenTelemetry Collector:
juju relate microovn opentelemetry-collector- Connect OpenTelemetry Collector to COS Lite:
# In the COS model
juju offer prometheus-k8s:receive-remote-write prom-remote-write
juju offer loki-k8s:logging loki-logging
# In the machine model
juju consume <controller>/cos.prom-remote-write
juju consume <controller>/cos.loki-logging
juju relate opentelemetry-collector prom-remote-write
juju relate opentelemetry-collector loki-loggingAlert rules are packaged in src/prometheus_alert_rules/alerts.yaml:
| Alert | Summary |
|---|---|
MicroOVNExporterDown | OVN metrics endpoint missing for 5 minutes. |
OvnControllerSouthboundDisconnected | ovn-controller disconnected from SB DB. |
OvnNorthdNoActiveInstance | No or multiple active ovn-northd instances detected. |
OvnNorthdNBConnectionDown | ovn-northd disconnected from NB DB. |
OvnNorthdSBConnectionDown | ovn-northd disconnected from SB DB. |
OvnNBDBNoLeader | Northbound DB has no leader. |
OvnNBDBMultipleLeaders | Northbound DB reports multiple leaders. |
OvnSBDBNoLeader | Southbound DB has no leader. |
OvnSBDBMultipleLeaders | Southbound DB reports multiple leaders. |
OvnDBClusterLogBacklog | DB cluster has unapplied/uncommitted log entries. |
OvnNorthdTransactionErrors | ovn-northd reported transaction errors in last 10m. |
OvnControllerTransactionErrors | ovn-controller reported transaction errors in last 10m. |
OvnControllerTransactionIncomplete | ovn-controller reported incomplete transactions in last 10m. |
OvsVswitchdFileDescriptorsHigh | ovs-vswitchd using >90% of file descriptors. |
Dashboards are packaged in src/dashboards/:
| Dashboard | Grafana name | Summary |
|---|---|---|
central-north-daemon.json | OVN Central / North Daemon | OVN Northd health: DB connections, active/standby status, build info, and transaction error/incomplete rates. |
central-northbound-db.json | OVN Central / Northbound DB | OVN Northbound DB cluster health: build/cluster info, leader/role, log status, connections, DB size, sessions, and monitors. |
central-southbound-db.json | OVN Central / Southbound DB | OVN Southbound DB cluster health: build/cluster info, leader/role, log status, connections, DB size, sessions, and monitors. |
host-controller.json | OVN Host / Controller | OVN controller health: SB connectivity, build info, integration bridge flows/ports, and transaction/error counters. |
host-ovs.json | OVS / Host Network | OVS datapath and bridge health: bridges, ports, flows, datapath stats, and vswitchd process metrics. |
- Contributing
- See the Juju SDK documentation for more information about developing and improving charms.