Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Kernel changes and masking
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1175

PostPosted: Sat Sep 05, 2020 9:53 am    Post subject: Kernel changes and masking Reply with quote

What resources are available for tracking important changes to the Linux kernel so I can know when it is important to proceed with an upgrade to the kernel?
As of now I sort of just been relying on the maintainers of gentoo's repository to tell me what kernel to be using. I use the gentoo-sources package fyi.
Would it work and still be a good practice to mask kernel source versions greater than or "above" my current one in use so that I can avoid unnecessarily downloading kernel source tree every time it is updated?
I only upgrade the kernel anyway when I have time to go through the manual steps for configuring and installing it, which is probably once a month.
Back to top
View user's profile Send private message
pietinger
Guru
Guru


Joined: 17 Oct 2006
Posts: 394
Location: Bavaria

PostPosted: Sat Sep 05, 2020 10:32 am    Post subject: Re: Kernel changes and masking Reply with quote

I also use gentoo-sources (unstable)

LIsLinuxIsSogood wrote:
Would it work and still be a good practice to mask kernel source versions greater than or "above" my current one in use so that I can avoid unnecessarily downloading kernel source tree every time it is updated?

Imho NO, it is not a good practice. Yes, some downloads will be unnecessary, but I can see immediately if there was an update. If after my daily "emerge --sync" I see a new kernel version, I visit:

LIsLinuxIsSogood wrote:
What resources are available for tracking important changes to the Linux kernel so I can know when it is important to proceed with an upgrade to the kernel?


https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

klicking on Branch "linux-5.8.y" and read the headlines of the comitted messages. Today I see there is nothing which affects my kernel config and therefore I will not update to the new version immediately. Maybe the next version.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 46684
Location: 56N 3W

PostPosted: Sat Sep 05, 2020 11:01 am    Post subject: Reply with quote

LIsLinuxIsSogood,

There are two options to consider.

a) you hardware is well supported in the gentoo-sources stable kernel.
Keep using the stable kernel. It gets all the important updates.
When a new stable e.g 4.19.x to 5.4.x comes out, move to it. The .x versions are all important to somebody. You need se read the changelog to decide if you are affected.
It may be faster to update anyway.

b) You have new shiny hardware that does not quite work with the newest kernel you can get plus patches that have not get into the kernel yet.
You need testing gentoo-sources or newer Don't expect improvements every step. Just occasionally things go backward too.

In short, if the stable kernel is good enough, use it but don't mask version mask anything. You will miss things that way.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Sat Sep 05, 2020 1:45 pm    Post subject: Reply with quote

If running an unstable version, say ACCEPT_KEYWORDS="~amd64" in make.conf, does "sys-kernel/gentoo-sources amd64" in package.accept_keywords do anything? My understanding was that it only unmasked unstable keywords.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 46684
Location: 56N 3W

PostPosted: Sat Sep 05, 2020 2:02 pm    Post subject: Reply with quote

Tony0945,

You need
Code:
sys-kernel/gentoo-sources -~amd64


ACCEPT_KEYWORDS="~amd64" expands to ACCEPT_KEYWORDS="amd64 ~amd64" so as you say, sys-kernel/gentoo-sources amd64 does nothing as it already covered by make.conf.
Not ~amd64 is what's needed.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Sat Sep 05, 2020 2:33 pm    Post subject: Reply with quote

NeddySeagoon wrote:
You need
Code:
sys-kernel/gentoo-sources -~amd64
...

Ah! I learned something new! Thank You!
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1175

PostPosted: Sun Sep 06, 2020 7:15 am    Post subject: Reply with quote

So I gather from the last few messages it would be okay and encouraged to use unstable packages for the rest of the system, but stable for kernel? This is counter to what I was generally assuming in terms of mixing stable and experimental branches, but I guess if it is for the kernel specifically it may not be a problem?
Back to top
View user's profile Send private message
pietinger
Guru
Guru


Joined: 17 Oct 2006
Posts: 394
Location: Bavaria

PostPosted: Sun Sep 06, 2020 7:20 am    Post subject: Reply with quote

LIsLinuxIsSogood wrote:
[...] it would be okay [...] to use unstable packages for the rest of the system, but stable for kernel?[...]

Its okay. I have the same revers: An unstable kernel within a stable system. Mixing stable with unstable is sometimes a must, because all games are unstable in gentoo. Therefore my xboard and stockfish is also unstable.
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1175

PostPosted: Sun Sep 06, 2020 7:34 am    Post subject: Reply with quote

Well now I am not sure whether or not to downgrade the kernel and if so then how to do so? I tried the scenario of inserting the use flag for sys-kernel/gentoo sources -~amd64 but running the emerge --changed-use or emerge -N does not downgrade automatically. Suggestions?
Back to top
View user's profile Send private message
pietinger
Guru
Guru


Joined: 17 Oct 2006
Posts: 394
Location: Bavaria

PostPosted: Sun Sep 06, 2020 7:35 am    Post subject: Reply with quote

LIsLinuxIsSogood wrote:
Well now I am not sure whether or not to downgrade the kernel [...]

Why do you want to downgrade your kernel ?
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1175

PostPosted: Sun Sep 06, 2020 7:48 am    Post subject: Reply with quote

Good point :D
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 46684
Location: 56N 3W

PostPosted: Sun Sep 06, 2020 10:09 am    Post subject: Reply with quote

LIsLinuxIsSogood,

The mixing branches works both ways A few testing packages on a stable system is the common case. That's the well known package.accept_keywords ~arch
Less common is a few stable packages on an ~arch system. That's package.accept_keywords -~arch.

Its possible that you had the now stable kernel installed in /usr/src before you added
Code:
sys-kernel/gentoo-sources -~amd64
to your package.accept_keywords/ from the days when it wan the best testing kernel.

Kernel sources are special, portage only installs them to /usr/src. Its up to you to build them.

Sort out what happened or you will get in a mess in the future. Your testing kernel will become unmaintained and get removed. Possibly due to security updates.
Half a switch, like you appear to have done is worse than not switching at all.

Either move to a stable LTS (Long Term Support) kernel or don't.
LTS kernels got security fixes with patch version bumps.
Testing kernels get security fixes rolled in with all the other functionality additions.
Follow one or the other properly.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Sun Sep 06, 2020 3:04 pm    Post subject: Reply with quote

NeddySeagoon wrote:
Either move to a stable LTS (Long Term Support) kernel or don't.
LTS kernels got security fixes with patch version bumps.
Testing kernels get security fixes rolled in with all the other functionality additions.
Follow one or the other properly.

For reference, I'm on LTS stable 5.4 on all my 64-bit systems and 4.4 on my only 32-bit system.
I was on testing kernel for my Ryzen system when it was still relatively new. I even had to patch it to get lm-sensors to work.
Now it's mature and I removed the keyword from gentoo-sources. My general rule is "stable for system code, testing for applications" because that gives me the applications that upstream calls stable. Sometimes there are problems and I mask specific versions. As noted many times by NeddySeagoon, these mixed systems are not recommended because sometimes something at the bottom or middle layer causes conflicts.

4.4 seems to run better on the ancient system and I certainly don't need new drivers.

Keyword gentoo-sources as suggested. Then "emerge -a1v gentoo-sources". Then "eselect kernel <stable version number>". You probably have to run "eselect kernel list" first unless you have an eidetic memory. Then follow your build procedure. And, if you still run grub, update the grub menu.
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1175

PostPosted: Mon Sep 07, 2020 9:12 am    Post subject: Reply with quote

I am currently using an unstable kernel, 5.8.3, and I do want to avoid updating the kernel as often as it seems the latest unstable sources are "pushed" in the repo -- that process being tedious and time consuming. SO, I've made the accept_keyword change and downloaded the lower version of kernel 5.4.60. I am considering the downgrade just so I can keep up with the latest stable kernel version, but I could also keep running 5.8.3. However it is conceivable that 5.4.60 as a stable kernel is safer and more reliable than staying with this later kernel version that in its x.x.3 revision as opposed to the x.x.60 for the 5.4 would end up becoming outdated quickly putting me back in the same position I am now of upgrading again and again. I bet by the time 5.8 is available as stable it would be far beyond 5.8.3 so I guess I should not risk keeping 5.8.3 and downgrade to 5.4.60.
Back to top
View user's profile Send private message
asturm
Developer
Developer


Joined: 05 Apr 2007
Posts: 7972
Location: Austria

PostPosted: Mon Sep 07, 2020 9:32 am    Post subject: Reply with quote

Only LTS kernels are stabilised so 5.8 will never be stable. But if it works for you now, why change? By now there's already 5.8.7 available which by definition has received numerous fixes over 5.8.3.
_________________
backend.cpp:92:2: warning: #warning TODO - this error message is about as useful as a cooling unit in the arctic
Back to top
View user's profile Send private message
DespLock
n00b
n00b


Joined: 27 Jul 2020
Posts: 23

PostPosted: Mon Sep 07, 2020 9:51 am    Post subject: Reply with quote

Another way to do this: emerge a special kernel version:
emerge --noreplace sys-kernel/gentoo-sources:5.8.3

Then remove gentoo-sources from world (file):
emerge --deselect gentoo-sources
emerge --depclean

After that you can install newer versions like above.


Last edited by DespLock on Mon Sep 07, 2020 10:04 am; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 46684
Location: 56N 3W

PostPosted: Mon Sep 07, 2020 10:03 am    Post subject: Reply with quote

LIsLinuxIsSogood,

Once 5.9.x is out, there will be no more changes to 5.8.
Either track LTS or testing but don't stay on 5.8 now with the intent to track LTS 'one day'.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Mon Sep 07, 2020 3:48 pm    Post subject: Reply with quote

NeddySeagoon wrote:
LIsLinuxIsSogood,

Once 5.9.x is out, there will be no more changes to 5.8.
Either track LTS or testing but don't stay on 5.8 now with the intent to track LTS 'one day'.

A possible compromise? In package.accept_keywords put lines:
Code:

sys-kernel/gentoo-sources -~amd64
=sys-kernel/gentoo-sources-5.8.3  ~amd64

Would that work to enable anything in the stable branch and also the one unstable he has now?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 46684
Location: 56N 3W

PostPosted: Mon Sep 07, 2020 4:49 pm    Post subject: Reply with quote

Tony0945,

Yes. The problem is that LIsLinuxIsSogood will stay on gentoo-sources-5.8.3 long after its forgotten, until there is a newer LTS kernel.
gentoo-sources-5.8.3 is already forgotten. 5.8.7 is out.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
pietinger
Guru
Guru


Joined: 17 Oct 2006
Posts: 394
Location: Bavaria

PostPosted: Mon Sep 07, 2020 5:11 pm    Post subject: Reply with quote

LIsLinuxIsSogood,

you want to avoid too many updates of your kernel. You can do this with a stable (today: 5.4.x) and an unstable kernel (today: 5.8.7), BUT ...

... dont believe a stable kernel has less updates than the unstable ones (think of 5.4.60 - in words: sixty). This is because every bug found in newer unstable kernels wil be BACKPORTED to the actual LTS-kernel. And for security reasons you should update your stable LTS-kernel ALSO when a new version is out ...

so, you dont win (or loose) something with your decission for a stable kernel.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Mon Sep 07, 2020 5:16 pm    Post subject: Reply with quote

pietinger,

What you win is avoiding the weekly build of a new kernel.
Back to top
View user's profile Send private message
pietinger
Guru
Guru


Joined: 17 Oct 2006
Posts: 394
Location: Bavaria

PostPosted: Mon Sep 07, 2020 5:20 pm    Post subject: Reply with quote

Tony0945 wrote:
What you win is avoiding the weekly build of a new kernel.

Tony,
yes you are right, IF I would build ervery version. But I am still on 5.8.6 and before I had 5.8.4 and 5.8.1 ... its my decission when I update to a new version ... and I beleive in the same time there where the same numbers of new LTS-versions ...
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1175

PostPosted: Thu Sep 10, 2020 8:55 am    Post subject: Reply with quote

Not to deter from discussions about stable vs unstable, but now that I downgraded the kernel, and I decided I want to keep the latest version in my /boot folder since I know it works. When running grub-mkconfig I believe the default entry is set to the highest version number of the kernel found, which unfortunately is not the one I want. I would read all the grub documentation to figure it out myself, but I am also not one to shy away from recommended solutions. So what is a way to instruct grub to either remove or block the 5.8.3 kernel or else to prioritize the lower kernels in the boot loader's menu entry order? thank you in advance for your suggestions.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Thu Sep 10, 2020 1:38 pm    Post subject: Reply with quote

LIsLinuxIsSogood,

If you were running rEFInd, all you would have to do is run "touch <full pathname of desired boot kernel>" and it would become the latest. I suppose you could do that with grub:2 also, running your grub command afterward.
Back to top
View user's profile Send private message
Tony0945
Advocate
Advocate


Joined: 25 Jul 2006
Posts: 4267
Location: Illinois, USA

PostPosted: Thu Sep 10, 2020 1:47 pm    Post subject: Reply with quote

pietinger wrote:
IF I would build every version.

So I gather you do not have "sys-kernel/gentoo-sources" in your world file. Or you put specific versions in world. Or just mask higher versions until the spirit moves you to change. That's okay too. I had assumed that gentoo-sources was updating on the release schedule. Tilde (I really dislike "unstable") version come out much more often than stabilizations occur. I just switched in the last few days from 5.4.48 to 5.4.60 as 5.4.60 became stable, skipping eleven builds. There wasn't even much to it. I took the default "no" foe each new config item. My hardware is already supported except for lm-sensors which shows fans at zero ROM (I can see them running) and claims my CPU is frozen.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum