0

Suppose I have a particular release of Ubuntu (say Ubuntu 12.04.5 LTS - Precise Pangolin). The kernel it uses is 3.13.0-32-generic x86_64. Where exactly does this version number come from? It is clearly not mainline kernel version 3.13. By looking at /usr/include/linux/version.h in 12.04.5 I found LINUX_VERSION_CODE 197199 that translates to 3.2.79, which looks more plausible, but there is also mainline v3.2.79-precise which seems to correspond to v3.2.79. Is this equivalent to 12.04.5s 3.13.0-32 kernel?

How can I find out the exact mainline kernel, a particular version of Ubuntu is based on? I'm interested in finding out how to get to this 3.13.0-32 using the exact mainline kernel commit it uses.

  • 4
    Possible duplicate of List of Ubuntu Versions with Corresponding Linux Kernel Version – N0rbert Sep 5 '18 at 19:10
  • "how to get to this 3.13.0-32 using the exact mainline kernel commit it uses" doesn't make sense, since Canonical backports patches (and may even have out-of-tree patches), so there's no way to get from the kernel commit to that number. Also: linux/version.h is from linux-libc-dev, so it may or may not have any relation to the kernel you're actually using. – muru Sep 7 '18 at 8:31
1

From John Ford's comment to an answer in NObert's link, the mapping you want is Ubuntu kernel to mainline map
According to that, your 3.13.0-32 Ubuntu kernel is mainline 3.13.11.4

  • so ignore LINUX_VERSION_CODE 197199 in /usr/include/linux/version.h? The closest I could find in the kernel git is v3.13.11 omitting the 4. – Kuravi H Sep 6 '18 at 16:00
0

uname -a or uname -r might be what you are looking for. See also this question and the man page for uname.

  • I think this is a typo, you must be referring to uname – Kuravi H Sep 6 '18 at 16:13
  • Oh yes. Supposed to be uname. I think my spellcheck changed it. – John P Sep 6 '18 at 21:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.