Someone was performing an upgrade of a software running on our RHEL Server with
rpm -Uvh package_name.rpm
I'd like to use
yum -U package_name.rpm
Can this cause any problem or inconsistency?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.Sign up to join this community
If you just want to update specific packages with
yum then the correct command is:
yum update package.rpm
Of course, an important thing to note is exactly how the packages were installed and whether or not there are updates in the repos that
yum will use. If you can't confirm that the
--nodeps switch wasn't used then you may run into dependency issues at runtime when using the packages.
A better thing to do is to just use
yum to install the packages as it will pull the latest version along with dependencies.
rpm underneath. The only important difference is that
yum knows about repositories and can thus - if needed - decide to fetch packages from those repositories to install.
rpm does not, and will thus only install what you provide him.
yum syntax is different from
yum install package
yum update package