xvfb-run command not found

In this troubleshooting guide we learn how to fix xvfb-run command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

xvfb-run: command not found

or when using sudo you get the following error message

sudo: xvfb-run: command not found

Solutions to xvfb-run: command not found

How To Fix xvfb-run: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu xvfb-run is provided by xvfb package.

xvfb is:

Xvfb provides an X server that can run on machines with no display hardware and no physical input devices. It emulates a dumb framebuffer using virtual memory. The primary use of this server was intended to be server testing, but other novel uses for it have been found, including testing clients against unusual depths and screen configurations, doing batch processing with Xvfb as a background rendering engine, load testing, as an aid to porting the X server to a new platform, and providing an unobtrusive way to run applications that don’t really need an X server but insist on having one anyway.

This package also contains a convenience script called xvfb-run which simplifies the automated execution of X clients in a virtual server environment. This convenience script requires the use of the xauth program.

More information about X.Org can be found at: URL:https://www.x.org

This package is built from the X.org xserver module.

To fix this problem, we can install more using the command below.

sudo apt-get -y install xvfb

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install xvfb.

sudo apt -y install xvfb

Or if you have aptitude installed you can use the following command.

sudo aptitude install xvfb

Summary

In this tutorial we learn how to fix xvfb-run command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.