Live data from Hacker News

Stable Linux mainline builds for Ubuntu

stgraber.org

21–30 of 59 posts

Re: Stable Linux mainline builds for Ubuntu

#21
post #17

Coming from windows, I’m a little confused how this works, is he reinstalling Linux/Ubuntu every week on all his machines? Or is it possible to “upgrade in place” just the kernel and leave your files/data alone, if the latter, is there a good guide for how to do that and for a homelabber would that be a good idea to avoid security bugs?

> Or is it possible to “upgrade in place” just the kernel and leave your files/data alone

Yeah. I've never heard of reinstalling the OS just to get a newer kernel.

> is there a good guide for how to do that

I think it's best to continue to use your distro's package manager to handle actually installing that kernel, so the instructions would all be distro-specific. Some distros make working with a custom kernel easier than others.

> for a homelabber would that be a good idea to avoid security bugs?

Depends on your distro. I would expect major ones and enterprise-oriented ones to do a good job of backporting security fixes to the older kernels they run. If they do a really good job of this, it might even be more secure on the whole.

But yeah, just using the latest stable kernel is probably the simplest way to ensure that you have the latest security fixes. (It'll also ensure you have the latest undiscovered security bugs. ;)

Re: Stable Linux mainline builds for Ubuntu

#23
post #4

If I wanted to keep Secureboot enabled, would signing with a MOK and enrolling that key be sufficient?

You say that as though it's easy. I've yet to find an explanation that's shorter than a book.

The Debian wiki explanation[1] is technical, but it's definitely shorter than a book, and if you're running your own kernels it shouldn't be too difficult.

It gives you the "here, run these commands" version if that's what you want.

[1] https://wiki.debian.org/SecureBoot#MOK_-_Machine_Owner_Key

Re: Stable Linux mainline builds for Ubuntu

#24
post #17

Coming from windows, I’m a little confused how this works, is he reinstalling Linux/Ubuntu every week on all his machines? Or is it possible to “upgrade in place” just the kernel and leave your files/data alone, if the latter, is there a good guide for how to do that and for a homelabber would that be a good idea to avoid security bugs?

As the other replies to this state, yes it's standard practise to update a kernel by installing the newer one without having to re-install or update all the other packages. Kernel updates are handled the same as any other package update but with the only difference being that a system reboot is required. (There's also the possibility of performing live kernel patching so that a reboot isn't needed, but that's typically a paid for service with enterprise linux).

Also, you can have many kernels installed concurrently and select which one to boot from at the GRUB boot screen. This is mostly used when you update the kernel and suddenly find on rebooting that something has gone wrong (e.g. necessary drivers not included in the initial ram disk - initrd), so you can reboot and select the previous working kernel to boot the system and resolve whatever issue you had.

Re: Stable Linux mainline builds for Ubuntu

#26

I think he means stable rather than mainline? I run the stable kernel, which I build myself. There is still the occasional regression. About a year ago it had a regression in the Intel graphics driver which broke graphics for my Haswell chip. A patch was available but this wasn't merged for months. Luckily Gentoo makes it super easy to apply custom patches so I did. IMO if you want to run a stable or mainline kernel…

[deleted]

Re: Stable Linux mainline builds for Ubuntu

#27

checking your github repo tels me that: This branch is 2273 commits ahead, 14587 commits behind torvalds:master. ????

I was also confused since to my understanding "mainline" is usually the release candidates, i.e. Linus's master branch. Here "(stable) mainline" appears to mean the latest stable release without distribution-specific patches, what I'd call a "vanilla kernel".

"Mainline kernels" also gets used to refer to kernels built from Linus's repo in general, as a way to distinguish them from kernels built from the OS vendor's / hardware vendor's branch.

For example when people talk about phones or tablets having mainline support, they mean that Linus's tree has all the drivers etc for that hardware and using the hardware vendor's arbitrary kernel drop isn't needed. They don't necessarily mean that the support is only in master and not in a stable branch. Eg https://mainline.space/ https://not.mainline.space/

Re: Stable Linux mainline builds for Ubuntu

#29
post #4

If I wanted to keep Secureboot enabled, would signing with a MOK and enrolling that key be sufficient?

You say that as though it's easy. I've yet to find an explanation that's shorter than a book.

Seconded.

Step 0: deploy your own PKI, install certificates on your motherboard firmware, sign your kernel, sign your modules.

Step 0.5: Sign your DKMSs from Broadcom, Nvidia, and Intel.

Step 0.75: Re-sign everything because you missed a step.

Re: Stable Linux mainline builds for Ubuntu

#30
post #18
post #17

Coming from windows, I’m a little confused how this works, is he reinstalling Linux/Ubuntu every week on all his machines? Or is it possible to “upgrade in place” just the kernel and leave your files/data alone, if the latter, is there a good guide for how to do that and for a homelabber would that be a good idea to avoid security bugs?

Installing kernel in Ubuntu is simply, given that you already have a kernel deb, a single line "apt-get install". You can create your own package apt repo or use the one provided by the author https://github.com/zabbly/linux#installation Be aware that upgrading kernel usually mess with graphics driver, especially for Nvidia. In the best case you'll have to unload and reload the Nvidia driver, in the worst case your d…

In the _most common_ case (with nvidia), your graphics stops working entirely and you spend (at least) an hour in a virtual console trying to undo what you did. Fun times.
Post reply on HN