Install new kernel while keeping the old kernel with YUM and RPM, how?

How can you accomplish this?
If I understand it correctly, with RPM it works like this:
rpm -ivh kernelpackage.rpm -> it installs a new kernel while keeping the old kernel in case the new kernel fails to boot. This is the prefered option.
rpm -Uvh kernelpackage.rpm -> it installs a new kernel and it deletes the old kernel. This is *NOT* recommended to do.
With YUM:
yum install kernel
yum update kernel
in BOTH cases, I notice in my lab at home that the old kernel is kept and the new one is added and the system boots from it.
If this is the case, then what is the difference between both YUM commands?
If I understand it correctly, with RPM it works like this:
rpm -ivh kernelpackage.rpm -> it installs a new kernel while keeping the old kernel in case the new kernel fails to boot. This is the prefered option.
rpm -Uvh kernelpackage.rpm -> it installs a new kernel and it deletes the old kernel. This is *NOT* recommended to do.
With YUM:
yum install kernel
yum update kernel
in BOTH cases, I notice in my lab at home that the old kernel is kept and the new one is added and the system boots from it.
If this is the case, then what is the difference between both YUM commands?
Comments
Excellent answer, thanks hiddenknight!
Also remember that some 3rd party software will need to re-installed as well. Example of this is VMWare Tools if the server is a VM.
"Its easier to deceive the masses then to convince the masses that they have been deceived."
-unknown
Using vSphere 5.0 I still have this problem with our RHEL vms. VMtools need to be reinstalled anytime we patch them.
I also recommend only using YUM as RPM is going the way of the dodo. The only use for RPM in my opinion is querying config files for a package...but even then, after working with RHEL or CentOS for a while you will become familiar with the locations of them.
Yup, going thru right now with a script to update all of the VMWare Tools. I also have to do this for the software for Oracle ASM/Grid too.
Also YUM is going to be deprecated here in the near future:
https://fedoraproject.org/wiki/Changes/ReplaceYumWithDNF
"Its easier to deceive the masses then to convince the masses that they have been deceived."
-unknown
Good to know. We're still using RHEL 5/6 so I don't think we'll be seeing it for a couple years.
https://dougvitale.wordpress.com/2011/12/21/deprecated-linux-networking-commands-and-their-replacements/
I can say this, at least Linux world moves faster on this Vs Microsoft Windows.
"Its easier to deceive the masses then to convince the masses that they have been deceived."
-unknown
On RHEL/CentOS 7, skip VMtools and yum install open-vm-tools. yum install open-vm-tools-desktop if you have GUI desktop.
OVT is officially supported and the KB article can be found at http://kb.vmware.com/kb/2073803
For RHEL/CentOS 5/6, I will try the VMware Tools Operating System Specific Packages (OSPs) site at https://www.vmware.com/support/packages
The vSphere 5.X doc is at https://packages.vmware.com/tools/docs/manuals/osp-esxi-51-install-guide.pdf
For example, RHEL 6 RPMs are at https://packages.vmware.com/tools/esx/latest/rhel6/x86_64/index.html
I am lazy... so whenever there is a way to automate.....