0

yum has three flags which are capable of 'modernizing' a package.

  • yum update – "may or may not" force the removal of obsolete packages.
  • yum upgrade – does not force the removal of obsolete packages
  • yum install – ?

I got the "may or may not" from this question:

In CentOS, what is the difference between yum update and yum upgrade?

What is the definitive behavior of "yum install" when I'm using it to bring software up to date?

1 Answers1

0

By default, the install sub-command installs the latest version of a package that yum can find in its repository list iff (if any only if) any version of the package is not already installed, i.e. it does not update an existing installed package with a newer version of the package even if it finds a newer version in its repos.

fpmurphy
  • 4,636
  • I believe this is false, at least on my aws ec2 instance I'm able to run yum install to update software. Are my settings not default? AWS instances definitely are not totally clean. – Lee Gildemeester Nov 09 '17 at 00:43
  • @LeeGildemeester. Could be. I do not have a AWS EC2 instance to test on at present. However yum install by itself should return an error and do nothing. Please provide an actual working example of using yum install to update a package. – fpmurphy Nov 09 '17 at 01:00