Portal Home > Knowledgebase > Articles Database > How to update CentOS kernel?


How to update CentOS kernel?




Posted by Divvy, 02-14-2012, 02:04 PM
Can someone teach me? I found this tutorial, can I use exactly commands? http://www.webhostingtalk.com/showthread.php?t=519660 Only need to run this? And after this? Thank you!

Posted by KnownHost-Jonathan, 02-14-2012, 02:07 PM
You should have no issues by following that guide! Is your server by any chance managed?

Posted by Host Ultra, 02-14-2012, 02:12 PM
You probably shouldn't modify the yum.conf to that. Not sure why whoever wrote the tutorial did it that way. Just run yum update kernel reboot You can also run "yum update" to update all the packages on your server which you should definitely do regularly to patch security issues.

Posted by Divvy, 02-14-2012, 02:17 PM
Thank you guys! My server is unmanaged When I run cat /etc/yum.conf I notice this: distroverpkg=redhat-release Is not better to have distroverpkg=centos-release? Or doesn't matter? Thank you once again

Posted by Host Ultra, 02-14-2012, 02:36 PM
No its supposed to be redhat-release

Posted by Divvy, 02-14-2012, 07:47 PM
Thank you mate! Btw, what is the difference by running: yum update -y and yum update kernel Thank you

Posted by Mr. Obvious, 02-14-2012, 08:24 PM
The OP's yum.conf looks that way, because cPanel modifies it so that yum update doesn't update packages that cPanel manages. layer0 said in his tutorial that it should look "something" like this, he never said to modify it to his. Basically, he says to make sure "kernel*" isn't in the list of excludes, otherwise yum won't update it. Reading comprehension is hard.

Posted by Mr. Obvious, 02-14-2012, 08:28 PM
yum update -y checks all of the packages installed (that aren't excluded in yum.conf) and updates them. -y forces the install, by automatically saying "yes" to all dialogs. yum update kernel updates just that specific item.

Posted by Divvy, 02-14-2012, 09:07 PM
Thank you

Posted by net, 02-14-2012, 09:22 PM
Moved > Hosting Security and Technology.

Posted by Eli L, 03-12-2012, 08:41 PM
I have a similar question. When I try to update my kernel, yum updates it but when I reboot the kernel never changes. I have the kernel installed: But this is my kernel: Heres my grub list if it matters: So how do I get the newest kernel to be used?

Posted by Infinitnet, 03-12-2012, 10:02 PM
Check /etc/grub.conf and try: update-grub

Posted by Eli L, 03-12-2012, 10:52 PM
I have the grub.conf in my last post. And centos doesnt have an update-grub.

Posted by twikamltd, 03-13-2012, 12:37 AM
Strange, it's set to boot from the newest one by the look of it, check the boot log and see if there's a reason it's skipping over the first 2 in the list, which it might if they failed for any reason.

Posted by TeamHC, 03-13-2012, 02:11 AM
Yes it redhat release only. cat /etc/redhat-release will give you an idea.

Posted by Eli L, 03-13-2012, 10:53 PM
I looked at my dmesg (boot.log is empty) and the only kernel related thing is the first line which says the kernel: Any ideas for this? Would it be safe to uninstall the old kernels so only the newest is left or would that leave the possibility for and unbootable server?

Posted by larwilliams, 03-14-2012, 01:09 AM
What version of CentOS are you using? cat /etc/redhat-release via SSH should answer the question. If you are running version 5.8, you may be able to resolve this simply by running yum upgrade to ensure you have all the latest updates, then reboot

Posted by Eli L, 03-14-2012, 03:34 AM
I already ran yum upgrade which downloaded the latest kernel that the system wont boot into.

Posted by Eli L, 04-18-2012, 05:22 PM
Thought I would update this thread. The problem was due to a failed RAID1 array on my system. Once the array was fixed and synced the new kernel started working. More info: https://www.centos.org/modules/newbb...topic_id=36377



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read