Mar 3, 2025

Open vSwitch Setup: A Step-by-Step Guide

Learn how to install Open vSwitch on Ubuntu 20.04 with this step-by-step guide. Follow detailed instructions to set up and verify your OVS installation.

Author

Faiz Ahmed FarooquiPrincipal Technical Consultant.
Open vSwitch Setup: A Step-by-Step Guide

In this article, we aim to provide a comprehensive guide on how to install Open vSwitch on Ubuntu. Open vSwitch, or OVS, is an open-source virtual switch designed to enable network automation while supporting standard management interfaces and protocols. For this tutorial, we will be using the Ubuntu 20.04 OS release.

Before starting, ensure that you have root access or sudo privileges to follow through with these instructions.

Installation Steps:

Step 1: Download OVS Binaries

Start the process by downloading the Open vSwitch binaries. Click Here to download the required files.

Step 2: Extract Files

Use the following command to extract the downloaded tar file:

tar -xvf openvswitch-3.2.0.tar.gz

Ensure that you replace "openvswitch-3.2.0.tar.gz" with the name of your actual downloaded file.

Step 3: Build Open vSwitch

In the next step, navigate to the extracted binary directory and run the boot.sh script:

cd openvswitch-3.2.0
./boot.sh

Step 4: Run the configuration script

Now we run the configure script which should create the Makefile.

Copy

./configure

Execute the above command in your terminal. This will check for any dependencies that you might need to address.

Step 5: Make and Install

Once the configuration process runs without any errors, use the make and make install commands. These commands will compile and install OVS on your system.

make && make install

Please note, that compiling might take a bit of time - so be patient.

Step 6: Add Open vSwitch scripts to $PATH

The PATH environment variable is a colon-delimited list of directories that your shell searches through when you enter a command. To execute OVS binaries from anywhere in the system, you should add the path of the OVS scripts to your PATH variable.

First, check if the path to the Open vSwitch script directory is already included in your PATH:

grep -qxF ‘export PATH=$PATH:/usr/local/share/openvswitch/scripts;’ ~/.bashrc

If this command does not output anything, you can add the path to your .bashrc file with this command

echo ‘\nexport PATH=$$PATH:/usr/local/share/openvswitch/scripts;’ >> ~/.bashrc;

Step 7: Update the PATH variable

To load the updated PATH, run the following command in the terminal.

export PATH=$$PATH:/usr/local/share/openvswitch/scripts;

With this, your installation process should be complete.

Please note:

  • It is advisable to reboot the system at this point to ensure all the changes have taken effect.
  • While running any command, if you receive a "Permission Denied" error, try using "sudo" at the start of the command.

After you reboot, you should have a working Open vSwitch installation and will be ready to move forward and learn about how to configure and use it. Open vSwitch has a multitude of uses. With it, you can manage networking more efficiently and automate network tasks while utilizing standard management interfaces and protocols.

Verifying the Installation

To ensure that Open vSwitch has been installed correctly, you can use the ovs-vsctl command to check its version. Type the following command in your terminal:

ovs-vsctl --version

The command will display the version of Open vSwitch installed on your system if the installation process was successful.

For example:

ovs-vsctl (Open vSwitch) 3.2.0
Compiled Jun 20 2021 09:50:19

This tells you that v3.2.0 was installed successfully.

Conclusion

This guide walked you through the process of installing Open vSwitch on Ubuntu 20.04. By following the steps outlined above, you are now ready to deploy and test your virtual networking projects.

Open vSwitch is a powerful tool, and mastering its capabilities can be of great use to anyone seeking a career in networking or system administration. I hope this article helped guide you through the installation process.

Stay tuned for more educational articles on how to use Open vSwitch and other open-source projects.

Source: This blog is authored by Faiz Ahmed, Principal Technical Consultant at GeekyAnts. Originally published on Hashnode: Read here.

Subscribe to Our Newsletter

RELATED ARTICLES

More from the engineering frontline.

Dive deep into our research and insights on design, development, and the impact of various trends to businesses.
The Bug That Doesn't Show Up in Code Review: Why Your Flutter Web App Reloads on Safari
The Bug That Doesn't Show Up in Code Review: Why Your Flutter Web App Reloads on Safari
A real-world look at how oversized images can trigger Safari reloads and iOS crashes in Flutter apps and how smarter image decoding prevents them.
From Prompting to Process: What Changed When Flutter Shipped Agent Skills
From Prompting to Process: What Changed When Flutter Shipped Agent Skills
This blog explores how Flutter Agent Skills improve AI-assisted development by combining official framework workflows with project-specific guidance for more consistent development.
Why Everything Your AI Builds Looks the Same
Why Everything Your AI Builds Looks the Same
This blog explores why AI-generated interfaces often look alike and explains how design systems, product context, and reusable engineering practices help teams build distinctive, scalable
How We Built the Missing Bridge from Code to Figma
Technology

Jul 10, 2026

How We Built the Missing Bridge from Code to Figma
This blog explores how AI-generated React apps get turned into fully editable, designer-ready Figma files by reading React Fiber instead of the DOM.
Building a Resilient Hybrid-Cloud Network with WireGuard HA, Route-Based Failover, and Deep Observability
Technology

Jun 27, 2026

Building a Resilient Hybrid-Cloud Network with WireGuard HA, Route-Based Failover, and Deep Observability
A practical breakdown of building resilient AWS-to-on-premises connectivity with WireGuard HA, active-standby failover, and deep packet-forwarding observability.
We Built a 114-Second AWS-to-Azure Failover. Here’s What We Learned
Technology

Jun 19, 2026

We Built a 114-Second AWS-to-Azure Failover. Here’s What We Learned
A practical guide to building a 114-second multi-cloud disaster recovery failover between AWS and Azure — what we built, what broke, and what we learned.
Cloud-Native and Cloud-Agnostic Are Not Ideologies; They Are Business-Stage Decisions
Technology

Jun 12, 2026

Cloud-Native and Cloud-Agnostic Are Not Ideologies; They Are Business-Stage Decisions
This blog explains how organizations can balance speed, scalability, and operational flexibility as they grow from startup to enterprise scale.

The Right Conversation Can Save You Six Months.

Whether you’re navigating AI adoption, modernizing legacy systems, or scaling a product - we start by listening. No pitch deck. No template. A real conversation.