18

When I run lsb_release on Debian 8, following error is appeared:

No LSB modules are available.

Is there any missing file causes this problem?

Reza Fallahpour
  • 336
  • 1
  • 2
  • 7

4 Answers4

28

As the error message says lsb_release command is installed but lsb module isn't. Use this command to solve the problem:

apt-get install lsb-core

I suggest to use lsb_release -a instead of lsb_release. It shows more useful output.

SuB
  • 651
  • 5
  • 12
  • 1
    This doesn't work on my debian stretch. Any other ideas? – QILIN LU Jul 02 '18 at 15:45
  • 1
    What is the problem? you can't install lsb-core or running ip causes errors? – SuB Jul 05 '18 at 09:28
  • 2
    @SuB On Stretch `lsb-compat` is installed instead as replacement for `lsb-core` and after this is installed it changes nothing. `lsb_release -a` still outputs `No LSB modules are available.` (together with the excepted useful output, so it is not really a problem but still irritating). – kayahr Jul 06 '18 at 12:20
  • On Ubuntu 18 `lsb_release -cs` worked, then it stopped oddly. I installed `lsb-core` and it works like a butterfly, ty. – JREAM Jul 29 '18 at 21:37
10

I just moved to Debian 11, Bullseye and, in order to check the release, you have to type

lsb_release -cs

lsb-core in Bullseye does not exist.

Denis Pitzalis
  • 200
  • 1
  • 7
  • 1
    `lsb_release -r` still works, too, if all you want is the release *number*, or `lsb_release -a` if you want it all. But none of this has anything to do with the OP's question. – Rob Cranfill Nov 11 '21 at 05:59
2

Debian discontinued support for the Linux Standard Base in 2015. See Debian and LSB.

If you don't want to see the message No LSB modules are available,
a workaround is to use the flags -cdir instead of -a :

lsb_release -cdir
Henke
  • 255
  • 3
  • 13
0

While building a container image based on Debian 11 (bullseye) I had to install the lsb_release command using:

apt-get -y install lsb-release

since, as Denis Pitzalis pointed out, the lsb-core package does not exist for 11

dvanrensburg
  • 101
  • 1