How to Install or Upgrade to Kernel 4.15 in CentOS 7

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Get your own self-hosted blog with a Free Domain at ($3.95/month).
  4. Become a Supporter - Make a contribution via PayPal
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Gabriel Cánepa

Gabriel Cánepa is a GNU/Linux sysadmin and web developer from Villa Mercedes, San Luis, Argentina. He works for a worldwide leading consumer product company and takes great pleasure in using FOSS tools to increase productivity in all areas of his daily work.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

39 Responses

  1. phil reklai says:

    Hi,

    I have successfully upgraded my kernel version from 3.10 to 4.14 using your instructions but the problem is now I get these errors every-time I boot my centos 7 server.

    Any idea how to fix this?.

    14:05
    wdat_wdt wdat_wdt: can’t request region for resource [mem 0x8d6c4b98-0x8d6c4b9c] kernel
    14:05
    ACPI Exception: AE_NOT_EXIST, Evaluating _PMC (20170728/power_meter-755) kernel
    14:05
    ACPI Error: Method parse/execution failed \_SB.PMI0._PMC, AE_NOT_EXIST (20170728/psparse-550) kernel
    14:05
    ACPI Error: Method parse/execution failed \_SB.PMI0._GHL, AE_NOT_EXIST (20170728/psparse-550) kernel
    14:05
    ACPI Error: Region IPMI (ID=7) has no handler (20170728/exfldio-299) kernel
    14:05
    ACPI Error: No handler for Region [SYSI] (ffff88016b161048) [IPMI] (20170728/evregion-166) kernel

    • Ravi Saive says:

      @Phil,

      Check in /var/log/messages for these errors, and it’s related to ACPI buffer size. The solution is to blacklist the acpi_power_meter kernel module. The driver doesn’t work due to the incorrect buffer size.

      # echo "blacklist acpi_power_meter" >> /etc/modprobe.d/hwmon.conf
      

      This is also caused by a missing kernel module, which was not supported by kernel package version 3.0.x before. After updating the Kernel, the required modules will not be loaded automatically, so you need to load it manually using the following commands:

      # modprobe ipmi_si
      # modprobe acpi_ipmi
      
      • phil reklai says:

        @Ravi

        Thank you very much for your help. the error was gone but now it got replace by this error:

        i2c i2c-0: sendbytes: NAK bailout.

        any idea how to fix that?

        • Ravi Saive says:

          @Phil,

          It seems your hardware isn’t supported by new kernel module or seems a bug in kernel version you have.

  2. baijianpeng says:

    At first, I must say this is a wonderful tutorial! I followed those steps and then successfully upgraded my CentOS 7.4 kernel to 4.15.12.

    However, I met new issue now:

    After I run “yum update -y” , I noticed that the old kernel 3.3.10 was also updated and now it is moved to the top one position on the list of booting options on the first screen when I rebooting my server, and that option is selected by default.

    That is to say, now my server will reboot with updated kernel 3.3.10 instead of the new one 4.15.12 if I don’t do anything.

    Why the sequence of boot options will change after “yum update” ?

    How can I configure to “always boot with Kernel 4.15.12 no matter which position it is placed on the list”?

    Thank you.

    • Ravi Saive says:

      @Baijanpeng,

      You can change the default boot option and set the new kernel as default, just follow the Step 3: Set Default Kernel Version in GRUB in the article.

      • baijianpeng says:

        I surely had done that step. My point is: the “yum update” command will CHANGE the sequence of boot options. So you don’t know which option will be selected by default after next “update” command.

        How can we configure the “grub” to ALWAYS boot with specific version of Kernel?

        Thank you.

        • Ravi Saive says:

          @Baijianpeng,

          Yes, once kernel update the boot sequence change automatically, so to boot into default kernel you need to configure grub as explained in the article.

          • baijianpeng says:

            Did you really understand my question?

            In your article, you said: ” GRUB_DEFAULT=0. This means that the first kernel in the GRUB initial screen will be used as default.” , so, which “value” should I use to let certain kernel version will be selected by default no matter it is the first or not?

          • Ravi Saive says:

            @Baiianpeng,

            Yeah go it, you want to set certain kernel version permanently. For this first you need to list all available kernel images added to GRUB2 by running the following command.

            $ grep '^menuentry' /boot/grub2/grub.cfg
            

            Now verify the GRUB menu entry for the kernel that you want to use. Every menu entry is allocated by GRUB2 a numeric value starting from 0 in an increasing order. That means, the first menu entry allocated 0, the second entry allocated 1, etc.

            To set different kernel version, open /etc/default/grub file and set GRUB_DEFAULT to the numeric entry value for the kernel that you want to use as default.

  3. famo says:

    Thanks a lot, is there a way for installing it without needing to network ?

  4. Shoby says:

    There is need to update kernel headers as well to same version as kernel.

  5. David says:

    Now what to do if this does not work, followed your instructions and the system would not boot with the new kernel

  6. Taryel Kazimov says:

    Hi, what is difference between rpm -Uvh & rpm -ivh for kernel upgrade?

  7. Mario says:

    Who supports this if you upgrade rehl or centos to 4.14?

    • Gabriel A. Cánepa says:

      @Mario,
      If you’re on RHEL, you can always go to Red Hat for support – although it would be a pretty good idea to engage them right from the start. As for CentOS, you’re basically on your own – except for the support you may get from the community.

  8. Krishna says:

    Hello,

    Kindly help me have situations, I have an dedicated server with CentOS 7 x64 bit. Last day I have updated the both OS and kernel ( CentOS 7 to 7.4 x64 bit.

    Situation 1: OS not booting from new kernel 3.10.0-693.5.2.e17.x86_64 (Getting black dead screen) but working fine on old kernel 3.10.0-229.e17.x86_64 .
    situation 2: I have downloaded the latest CentOS 7.4 x64 bit and tried to fresh installation on the server but this also not working (Getting black dead screen).

    Screenshot : http://prntscr.com/ha0qgo

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *