Baeldung Pro – Linux – NPI EA (cat = Baeldung on Linux)
announcement - icon

Learn through the super-clean Baeldung Pro experience:

>> Membership and Baeldung Pro.

No ads, dark-mode and 6 months free of IntelliJ Idea Ultimate to start with.

Partner – Orkes – NPI EA (tag=Kubernetes)
announcement - icon

Modern software architecture is often broken. Slow delivery leads to missed opportunities, innovation is stalled due to architectural complexities, and engineering resources are exceedingly expensive.

Orkes is the leading workflow orchestration platform built to enable teams to transform the way they develop, connect, and deploy applications, microservices, AI agents, and more.

With Orkes Conductor managed through Orkes Cloud, developers can focus on building mission critical applications without worrying about infrastructure maintenance to meet goals and, simply put, taking new products live faster and reducing total cost of ownership.

Try a 14-Day Free Trial of Orkes Conductor today.

1. Overview

Resetting network configurations should be an easy task. Typically, applying a netplan in supported environments after configuring a static IP address or DHCP usually works without a hitch. However, when we get unexpected warnings, the situation may look confusing.

Specifically, after upgrading to Ubuntu 22.04 or later, netplan might warn that ovsdb-server.service isn’t running.

In this tutorial, we’ll explore what ovsdb-server.service is, whether we can ignore this warning, and how to resolve it when necessary.

2. What Is ovsdb-server.service?

ovsdb-server.service is a systemd service related to Open vSwitch (OVS) that provides Remote Procedure Call (RPC) interfaces to one or more OVS databases (OVSDBs). This lets other components interact with and manage configurations stored in these databases.

So, what’s Open vSwitch? It’s an open-source virtual switch for managing network traffic in virtualized environments. We can use OVS as an alternative to traditional Linux bridges, bonds, and VLAN interfaces.

OVS is widely used in data centers and cloud platforms to handle complex networking setups for virtual machines (VMs) or containers. It’s like a virtual version of a physical network switch, but much more flexible and programmable.

Without ovsdb-server.service, systems using OVS might face connectivity issues because networking features won’t operate correctly.

3. The Warning

Let’s see what the problem looks like when applying a netplan:

$ sudo netplan apply
WARNING:root:Cannot call Open vSwitch: ovsdb-server.service is not running.

We notice here that netplan is simply warning us that ovsdb-server.service isn’t functioning. A warning isn’t the same as an error.

4. Ignore the Warning

If the warning doesn’t affect the network functionality, we can consider it benign.

Many users have reported that their networks function correctly despite this warning. However, it doesn’t hurt to test and verify that network services are functioning as expected.

Nevertheless, ignoring the warning may not be suitable for Ubuntu systems that rely on the networking features of OVS. Separately, production environments might have requirements that necessitate diagnosis.

5. Address the Warning

Of course, we can install Open vSwitch just to stop netplan from complaining about ovsdb-server.service. While that’s a reasonable option, fixing this becomes more urgent if netplan fails to apply changes or crashes when ovsdb-server.service isn’t running.

To get rid of the warning, let’s use the apt command to update the package index, and then install Open vSwitch:

$ sudo apt update && sudo apt install openvswitch-switch

After installing OVS, let’s make sure the service is operating correctly using the systemctl status command:

$ sudo systemctl status ovsdb-server.service
● ovsdb-server.service - Open vSwitch Database Unit
     Loaded: loaded (/lib/systemd/system/ovsdb-server.service; static)
     Active: active (running) since Sun 2024-12-01 11:19:47 CET; 11s ago
   Main PID: 4352 (ovsdb-server)
      Tasks: 1 (limit: 3790)
     Memory: 2.4M
        CPU: 64ms
     CGroup: /system.slice/ovsdb-server.service
             └─4352 ovsdb-server /etc/openvswitch/conf.db -vconsole:emer -vsysl>

The output above shows that ovsdb-server.service is loaded and active, exactly as intended.

If we install OVS but ovsdb-server.service isn’t running, we can start or restart it using systemctl:

$ sudo systemctl start ovsdb-server.service

Once we confirm the service is active, all that remains is to apply the netplan configuration and ensure the warning is gone:

$ sudo netplan apply

At this point, we should see no warnings related to ovsdb-server.service.

6. Conclusion

In this article, we explored ovsdb-server.service, its role in Open vSwitch, and how to address the not running warning when applying a netplan.

In conclusion, not all warnings need immediate action if they don’t affect the Linux system functionality. The same goes for ovsdb-server.service. If the missing service doesn’t cause netplan crashes or connectivity issues, we should be able to safely ignore the warning.