I know Ubuntu is based on Debian but I would like to find out if I am running debian or ubuntu.


uname -a

Result:Linux test #1 SMP Tue Nov 10 16:29:17 UTC 2009 x86_64 GNU/Linux


cat /proc/version

Result:Linux version ([email protected]) (gcc version 4.3.3 (Ubuntu 4.3.3-5ubuntu4) ) #1 SMP Tue Nov 10 16:29:17 UTC 2009


lsb_release -a


Distributor ID: Debian
Description:    Debian GNU/Linux 5.0.10 (lenny)
Release:        5.0.10
Codename:       lenny

So What is it Debian or ubuntu?


cat /etc/issue:


Debian GNU/Linux 5.0 (So I can conclusively say it is debian)

  • Ubuntu 4.3.3
    – Ramhound
    Apr 14, 2014 at 15:15
  • 1
    @Ramhound No, there is no Ubuntu 4.3.3. That bit means the kernel was built with Ubuntu's version of GCC 4.3.3.
    – tgies
    Apr 14, 2014 at 19:08
  • 1
    I know that. Which begs the question why was Debian compiled with the Ubuntu version of gcc ( my guess it wasn't )
    – Ramhound
    Apr 14, 2014 at 19:41

1 Answer 1


You should trust lsb_release since both Debian and Ubuntu claim to be LSB compliant. In your example you are running Debian with an Ubuntu-compiled kernel (according to your /proc/version), that's why you see information about both distributions.

  • My bad, the Ubuntu part in the output of /proc/version refers to gcc not the kernel itself.
    – yorodm
    Apr 14, 2014 at 15:51
  • 1
    @Ramhound: It isn't. If you check uname's output, the kernel version states it was made by Linode so it is them who are using Ubuntu tagged gcc's to do their work. Although my best guess is that the server is running under some virtualization technology like OpenVZ.
    – yorodm
    Apr 14, 2014 at 16:38
  • 1
    I am inclined to agree with you that it is gcc compiled via ubuntu. However the distribution is actually Debian. The initial answer although it has upvotes, doesn't really have much backing and surely a ubuntu lsb_release will show ubuntu and not debian
    – tread
    Apr 14, 2014 at 18:50
  • If I run your test on one of my own servers I get Ubuntu Precise Pangolin running kernel Linux version 2.6.32-19-pve (root@maui) (gcc version 4.4.5 (Debian 4.4.5-8) ) #1 SMP Wed May 15 07:32:52 CEST 2013. This is a Ubuntu OpenVZ container running under Proxmox.
    – yorodm
    Apr 14, 2014 at 18:56

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