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?

4 Answers 4

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.

4
  • 1
    This doesn't work on my debian stretch. Any other ideas?
    – QILIN LU
    Jul 2, 2018 at 15:45
  • 1
    What is the problem? you can't install lsb-core or running ip causes errors?
    – SuB
    Jul 5, 2018 at 9: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 6, 2018 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, 2018 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.

1
  • 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. Nov 11, 2021 at 5: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
1
  • lsb_release -cdir still shows mentioned message on my Debian 12, only workaround for me is to use 2>/dev/null. Anyway, hanks for the link. Feb 2 at 15:43
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

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .