back to article How to get the latest Linux kernel on your Ubuntu box

For significant subcomponents of Ubuntu – and its derivatives – you don't need to wait for the next release to appear. You can upgrade major parts on the fly. Here at Vulture Towers, we are working on a review of a machine with a 12th-generation Intel chip, and that's caused issues in some Linux distros. Back in 2021, we …

  1. fishman

    Latest Kernal

    I'm running Linux kernel 6.1.13 on Linux Mint 20. I grab the sources from the Linux kernel archive and compile it. I started doing it years ago when my wifi chipset was dropping the connection - using the latest and greatest kernel fixed it. Then later I moved to a new CPU with GPUs that weren't supported by the stock kernel.

    I've got it set up such that it takes just a few minutes to set it up to compile, and then just a single command to install it once the compile has finished.

    I usually take the current stable kernel but wait until it has received a number of revisions. I have never had any problems even though I've done this dozens of times.

    1. Altrux

      Re: Latest Kernal

      I stopped doing this years ago, after finding the process way too much faff, and it becoming impossible to build a kernel that would even boot, on Ubuntu. I'm now running Liquorix, which works fine, but perhaps what I might try next is custom-building, using their config as a starting point and stripping out more unnecessary stuff. Interesting that the vmlinuz image, and the modules dir, are much smaller with the Liquorix kernel, compared to the 'canned' Ubuntu kernels.

      Would love to see how quickly a kernel compiles on my 12-thread Ryzen, compared with the old single-core Athlon 64 I used to use, way back in the day!

    2. VoiceOfTruth

      Re: Latest Kernal

      -> I'm running Linux kernel 6.1.13 on Linux Mint 20. I grab the sources from the Linux kernel archive and compile it. I started doing it years ago when my wifi chipset was dropping the connection - using the latest and greatest kernel fixed it. Then later I moved to a new CPU with GPUs that weren't supported by the stock kernel.

      And that is why there will never be a "year of the Linux desktop".

      Grandma to Eddie, her grandson: Eddie, my wifi doesn't work. It keeps dropping the connection.

      Eddie to Grandma: Have you tried getting the latest kernel sources and seeing if there is a fix? You will have to use ethernet or another machine then copy the source to your laptop, plus install build-essentials to get started.

      Grandma to Eddie: What the eff are you talking about? I'm too old for this. You told me Linux is better than Windows.

      1. Adair Silver badge

        Re: Latest Kernal

        VOT - Presumably you under the mistaken impression that this is SOP for anyone using Linux?

        1. desht

          Re: Latest Kernal

          Of course he isn't. Facetious lazy regurgitated troll attempts like this have been bleedin' obvious for years.

      2. Lars
        Happy

        Re: Latest Kernal

        @VoiceOfTruth

        Lets look at the bright side, all that happened was that Windows was delegated to a desktop OS and a just about server OS.

        Meanwhile Linux will run on the smallest and biggest hardware there is, and on old and new desktops too.

        And "Linux on the desktop" become super democratic, it's not up to OEMs and computer shops but fully up to us.

        We, and we alone, decided the year of Linux on the desktop.

        And lets be honest with grandma and grandpa they will have exactly the same problems fixing anything on Windows too, and in fact I have found that there is a million things that can go crazy with a Windows screen just by accident (or a cat stepping across the keyboard), less so with Linux.

        About 10 years ago I found a linux desktop on display in a computer shop and decided to hang around for a while. Eventually one guy came, looked at me, and said - "that is called Linux but it's for experts only, but we have something much more suitable for you, Sir, and it's called Windows, please follow me.".

        We had a longer more honest discussion later, and he was a Linux user at home, but he told me they didn't really want to sell any Linux because they were afraid they would have to spend lots of time explaining things to customers.

        And that Windows was so much easier. If a problem, the first you would ask was if it was already more than two years old and the warranty gone - and look at what we have over here now.

        And you could always just shrug you shoulders and say - yes well it's Microsoft you know, so sorry, or suggest they leave it there or bring it in, and we will see if anything can be done, but it could be expensive and there is this base cost too always.

        And if somebody complains about graphics then just sell them a new "better" card.

        So lets stop worrying, and at the sound of "always look on the bright side of life".

        https://www.youtube.com/watch?v=ifLqzLEB3E0

      3. that one in the corner Silver badge

        Re: Latest Kernal

        > Grandma to Eddie, her grandson: Eddie, my wifi doesn't work. It keeps dropping the connection.

        Eddie to Grandma: have you tried forcing Windows to re-install the driver? All you have to do is enable Administrator Tools on the Start menu, then use them to open Hardware Management, look down the list to find your WiFi adapter, right-click and disable it, not forgetting to delete the driver or it'll just pick up the same one again, ha ha, then right-click again and

        Grandpa to Eddie, loudly: What are you prattling on about, boy? Stop upsetting your Grandma, get your arse over here and fix this! You know by now not to try to fix Windows over the phone. <slams phone down>

      4. fishman

        Re: Latest Kernal

        If I was running Windows and the current version of Windows didn't properly support my hardware my only choice would have been to buy new hardware. At least with Linux I have other options.

      5. Liam Proven (Written by Reg staff) Silver badge

        Re: Latest Kernal

        [Author here]

        > And that is why there will never be a "year of the Linux desktop".

        Welcome back, o pseudonymous Voice of Truth. We missed you.

        BTW the year of Linux on the desktop was 2016 when Linux laptops outsold Macs for the first time in the USA:

        https://www.theverge.com/2016/5/19/11711714/chromebooks-outsold-macs-us-idc-figures

        They outsold Macs worldwide by 2020:

        https://www.laptopmag.com/news/chromebooks-outsold-macbooks-in-2020-thats-why-google-is-launching-50-more-this-year

        Links picked from top Google hits, not intended as endorsement of any other sites. I am sure they are fine.

        When Linux outsells macOS, on x86 hardware, that for me is when it arrived. YMMV.

        Of course if one factored in Android it was a decade earlier when Android phones first outsold PCs, but Android is not a normal Linux distro. ChromeOS is and it's trivially easy to install and run ordinary Linux apps on it, even on ChromeOS Flex, the free edition for ordinary x86 PCs.

        I run Firefox and DOSemu on mine, because I am awkward like that. Works a treat.

        Hope that helps. Have a nice day.

      6. Grogan Silver badge

        Re: Latest Kernal

        Ignoramus... the difference is that you CAN fix it, before your distributor does.

        1. MrZoolook

          Re: Latest Kernal

          Hard to fix it if the fix involves connecting to the internet, and the problem is you need a network card driver.

          Say what you like about Windows, but I've never had it 'helpfully' tell me I need to download a network card driver before. Unlike a few times I tried some Linux distros.

          1. Adair Silver badge

            Re: Latest Kernal

            I must have been doing it wrong all these years—that's never happened to me. So, which anecdotal evidence represents the general experience?

          2. jake Silver badge

            Re: Latest Kernal

            "Hard to fix it if the fix involves connecting to the internet, and the problem is you need a network card driver."

            Just make sure every new computer comes with a dial-up modem. Real Linux distributions still come with minicom. Simply dial into your home network, login, and bob's yer Auntie. Not "hard" at all. Quite easy, in fact ... and has saved my butt more times than I can count.

    3. jake Silver badge

      Re: Latest Kernal

      Or, if you run Slackware's -current:

      Kernel 6.1.15 as of Saturday.

      KDE 5.27 since February 15th.

      Both available using slackpkg in the usual manner.

      1. keithpeter Silver badge
        Windows

        Re: Latest Kernal

        Perhaps worth mentioning that Mr Volkerding's configs are generally pretty useful as a starting point for those who wish to experiment.

        Icon: I'm usually OK with defaults

    4. Grogan Silver badge

      Re: Latest Kernal

      I just look at the commits and changelogs, and decide whether I need any of the fixes etc. I pretty much always use the latest kernel series (i.e. 6.2.x currently), but may skip any point releases that don't interest me. I mean, sometimes not one lick of code change would be in code paths I use. Other times, it's a specific set of conditions I'd never hit, to run afoul of a bug that's just been fixed. Some of it isn't even for our arch, too.

  2. Anonymous Coward
    Anonymous Coward

    Let One Hundred Flowers Bloom: Mao Tse Tung...................NOT!!!

    Please....give us all a break......there are FAR TOO MANY Linux choices out there:

    - Link: https://distrowatch.com/

    This El Reg commentard happens to like Fedora/XFCE.......currently somewhere around Linux 6.1.11......give or take.

    ....RedHat Retail from RH5.1 to RH9....and then Fedora from FC5 to F37....they all were (and currently are) good enough to suit anyone!!

    ....Except for the abomination called GNOME...............hence XFCE being used here at White Hat Mansions.................

    1. keithpeter Silver badge
      Pint

      Re: Let One Hundred Flowers Bloom: Mao Tse Tung...................NOT!!!

      @ac

      The article was about mainline kernels and presumably aimed at the small cohort of people who have very recent hardware and who therefore need to take advantage of recent updates from within the Ubuntu ecosystem.

      Thanks.

    2. DrSunshine0104

      Re: Let One Hundred Flowers Bloom: Mao Tse Tung...................NOT!!!

      People might take you more seriously if you didn't write a post like a feces-smeared, loon with a pinboard and yarn.

      Did you have a thesis you want to share? What you wrote is nonsensical screed. This is for IT professionals or enthusiasts not whatever you are... 4chan slob or whatever.

      1. Anonymous Coward
        Anonymous Coward

        Re: Let One Hundred Flowers Bloom: Mao Tse Tung...................NOT!!!

        Dear DrSunshine0104:

        Did you have anything to say about Linux, or Ubuntu, or even about the Linux kernel?

        Sincerely:

        AC

    3. Dr Paul Taylor

      Re: Let One Hundred Flowers Bloom: Mao Tse Tung...................NOT!!!

      "Hundred Flowers" was in fact a campaign to flush out dissidents, so that they could be eliminated.

      See, for example, https://alphahistory.com/chineserevolution/hundred-flowers-campaign/

  3. This post has been deleted by its author

  4. Tom7

    Why do instructions of this sort always include `sudo apt update` when `add-apt-repository` has, for some years now, done this automatically?

    1. Liam Proven (Written by Reg staff) Silver badge

      [Author here]

      > `add-apt-repository` has, for some years now, done this automatically

      You know what, that _is_ a good point.

      It's automatic when adding a PPA. It isn't when adding other sorts of repos, but even so, I continue to include it from force of habit. I will try to stop doing so.

      Thanks for the feedback.

  5. Ken Hagan Gold badge

    No mention of LTS?

    It is probably worth noting that the 6.1 kernel is LTS and so there is likely to be support, in terms of bug fixes for issues you might have, even if not from Ubuntu themselves.

    In fact, if you find yourself with a Linux distro running an older kernel and you feel a need for an upgrade, probably your first port of call should be the latest LTS rather than just the latest.

  6. Updraft102

    No need for PPAs or third party tools

    Just use the OEM kernel in the regular Ubuntu (updates) repo. No need to add any PPA or use any third party installer (though I do use Mainline for testing sometimes too, nothing wrong with it!).

    Look for linux-oem-22.04c in the Jammy repo. The Ubuntu OEM kernel is what my Dell XPS 13 "Developer's Edition" came with preinstalled (though with focal). It's just an Ubuntu kernel (with the usual Ubuntu modifications, AFAIK) based on a newer mainline kernel, perhaps with some vendor-specific modules (for various vendors) added by Ubuntu before the modules are able to be upstreamed. If you are not using a device that matches those modules, they are irrelevant to you anyway, and what you are left with is a newer Ubuntu kernel.

  7. Updraft102

    "At least one Ubuntu remix, Tuxedo OS, already has it."

    KDE Neon also.

  8. that one in the corner Silver badge

    Off topic, but still Ubuntu and kernels

    Is it normal for an official Ubuntu flavour, after a fresh install, to be unable to recompile its kernel due to little things like there not even being a compiler installed?

    It just came as a surprise, when attempting to create a VirtualBox VM from the current stable Lubuntu ISO on Sunday [1], that the Guest Additions failed to install for that reason.

    (Turned put that the easiest (fewest commands to type on a Sunday) way was to create the VM using plain Ubuntu, letting VirtualBox do an unattended install, then manually install the lubuntu meta-package followed by uninstalling all the Gnome packages (gnome* fitw), and reboot)

    [1] for reasons

    1. Liam Proven (Written by Reg staff) Silver badge

      Re: Off topic, but still Ubuntu and kernels

      [Author here]

      > unable to recompile its kernel due to little things like there not even being a compiler installed

      Yes, it is. So, before installing anything requiring kernel modules -- such as the VirtualBox Guest Additions -- be sure to install the `dkms` package *first*. Dynamic Kernel Module Services support also installs the kernel headers and the `build-essential` tools necessary for compiling kernel modules.

      1. Ken Hagan Gold badge

        Re: Off topic, but still Ubuntu and kernels

        Debian is the same. I don't know about other "families", but perhaps someone will chip in.

        I imagine that it is odd for a real Linux installation not to have had stuff like build-essential added, but a compiler isn't an essential part of an operating system, so I suppose a principle of minimalism applies.

        1. that one in the corner Silver badge

          Re: Off topic, but still Ubuntu and kernels

          I've been installing Devuan, but the nice friendly installer (not being sarcastic, I like it - with one proviso, see below) means it is easy to get (what I expect as) the basics installed without having to remember the names of the packages to add asap.

          > but a compiler isn't an essential part of an operating system

          Well, my reservation about the Devuan installer is that there isn't a box to uncheck that'll stop all the "productivity programs" being installed in the first place! So I have a list of packages to *remove* as soon as is convenient, such as the wordprocessor, which is never going to be touched. It is all horses for courses, but I (clearly) don't believe a WP is an essential part of an operating system, yet there it is, every time!

          > Debian is the same

          I thought Debian, from which Devuan inherited the installer, was the same wrt ease of getting the compiler in at the start. Will have to check against an up to date Debian, but the installer on Devuan looked very familiar from the (g)olden days pre-systemd of Debian.

      2. that one in the corner Silver badge

        Re: Off topic, but still Ubuntu and kernels

        Ta.

  9. mickaroo

    To Upgrade or Not to Upgrade?

    That is the question...

    I'm never quite sure what to do with articles like this.

    Is it: If it ain't broke, don't fix it.

    Or is it: If it ain't broke, I'm not learning anything.

    1. wub

      Re: To Upgrade or Not to Upgrade?

      "Or is it: If it ain't broke, I'm not learning anything."

      That's a major reason I started playing with SOC based systems - there is still quite a bit that doesn't work, or work properly. Everything got so boring on the desktop - I may have been more frustrated back in the day, but debugging and fixing things that should have worked but didn't provided a lot of interest (won't say "fun"). I really enjoy that feeling when I finally convince something to do what it should have done all along! I think this is why my wife likes gardening.

  10. Steve Graham

    I've been compiling kernels from source for years now. Just because I like things lightweight and efficient. Obviously, distro kernels have to allow for a variety of hardware, mostly through modules, I suppose, but I can tweak other things as well. It's a very long time since I've produced a kernel which won't boot. In fact, I think the last time was when I forgot to include the drivers for the brand new SATA technology that had arrived.

    I admit I enjoy tinkering too. I'm currently playing with an AMD-based 2007 laptop (came with Windows 7) and kernel 6.2.0, and the only thing not working yet is the ethernet. It seems to be the same chip as the wifi, which is working.

  11. Dr_Bingley

    Glad to hear the mainline kernel works again. A few months ago new kernels failed to build, which is why I switched to Xanmod (which works fine, by the way). Normally I just stick with the kernel my distro came with, but I needed kernel 6.1+ for some of my hardware.

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon

Other stories you might like