We obviously have a different way of helping others. I prefer the polite way.
well⦠english is not my language, but I help everyday people in english⦠I helped Jim and Iām quite sure I was not unpoliteā¦
moreover, Jim seems grown enough to defend himself.
anyway, as usual, youāre free to think what you want and welcome when you express your thoughts
I had totally missed this answer, where thereās the right information.
Now I have a doubt⦠the information is in the dnf.conf or somewhere (cause of SME/NS)?
Iām at work and canāt verify by myself, now
The option is inside /etc/yum.conf and itās called installonly_limit
.
Becuse learning is always the best way to improve our knowlege:
Finally to clean to system⦠I had to install yun-utils
# yum install yum-utils
and clean up
# package-cleanup --oldkernels --count=2
@Jim you can also make a custom template for yum.conf file in order not to delete old kernels by your own.
Iām curious to know why this parameter donāt workā¦
This e-smith layer⦠Letās talk about it
It works!
it Indeed keeps 5 kernels
But I put it at 2ā¦
And NS keep 6 Kernels
Jim
cat /etc/yum.conf
installonly_limit=5
[root@host1 etc]# ll /boot | grep -c vmli
5
The option doesnāt clean up old kernels on a running system, but it will be used by yum only when a new kernel is installed.
Example:
- installonly_limit = 2
- you have 5 kernels installed
- CentOS releases a new kernel, and you execute
yum update
- at the end of the process you will have only 2 kernels installed
When I found this parameter, I was thinking exactly as you describe @giacomoā¦
But the reality is different, to be clear, see the exact timeline:
- I had 5 kernels, and the installonly_limit = 5 ( before I
changed )
- I change installonly_limit = 2 ⦠And waited ( still with 5
kernels )
- Past thuesday or friday, thereās a kernel update⦠I expected
to see only 2 kernels, but I found 6 kernels.!!! :OMG:
Whatās happened?
Now I had two kernel because I made a manual cleanup.
When thereās an update by the CenterSoftware, the parameter installonly_limit = 2 seem to be ignoredā¦
It seems youāre right, from man yum.conf
installonly_limit Number of packages listed in installonlypkgs to keep installed at the same time. Setting to 0 disables this
feature. Default is ā3ā. Note that this functionality used to be in the āinstallonlynā plugin, where this option was altered via
tokeep. Note that as of version 3.2.24, yum will now look in the yumdb for a installonly attribute on installed packages. If
that attribute is ākeepā, then they will never be removed.
What can be do to improve?
-Itās a bug in the softwarecenter?
-A missing feature?
- a plugin that not work as expected?
- an e-smith surprise (@nas
)?
installonly_limit=2
Iāl try to test this
Today, thereās a kernel updateā¦
I setup to have only two kernelsā¦
But it seem thatās wrong yet.
Edit Whatās happen?
In the yum.comf the installonly_limit=5
Thereās something that erase my yum.conf to erame my value.
I would like to know what.
Is there a way to fix this?
Itā a template.
To create a template custom:
mkdir -p /etc/e-smith/templates-custom/etc/yum.conf/
cp /etc/e-smith/templates/etc/yum.conf/10base /etc/e-smith/templates-custom/etc/yum.conf/
Edit the file and execute:
expand-template /etc/yum.conf