lsb_release command not found

In this troubleshooting guide we learn how to fix lsb_release command not found error message

Introduction

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

lsb_release: command not found

or when using sudo you get the following error message

sudo: lsb_release: command not found

Solutions to lsb_release: command not found

How To Fix lsb_release: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu lsb_release is provided by lsb-release package.

lsb-release is:

The Linux Standard Base (http://www.linuxbase.org/) is a standard core system that third-party applications written for Linux can depend upon.

The lsb-release command is a simple tool to help identify the Linux distribution being used and its compliance with the Linux Standard Base. LSB conformance will not be reported unless the required metapackages are installed.

While it is intended for use by LSB packages, this command may also be useful for programmatically distinguishing between a pure Debian installation and derived distributions.

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

sudo apt-get -y install lsb-release

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

You can also use apt command to install lsb-release.

sudo apt -y install lsb-release

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

sudo aptitude install lsb-release

Summary

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