Hot answers tagged

77

Have you tried this? $ yum list installed bind


60

It seems like somehow yum cached data and the rpm database got out of sync with each other I guess. Try running the next commands: su -c 'yum clean all && rpm --rebuilddb' su -c 'package-cleanup --problems' Then run: su -c 'yum erase zarafa*' Edit #1: Try running the next command: # su -c 'yum --setopt=tsflags=noscripts remove zarafa*' If that ...


59

The rpm command has the --nodeps option that you can use. A challenge is that rpm by itself is not aware of yum repositories. The following command will install or update the package, ignoring dependencies, but automatically looking up the download URL from your repositories with repoquery which is in package yum-utils. rpm -Uvh --nodeps $(repoquery --...


39

Ansible yum module already provides a solution for this problem. The path to the local rpm file on the server can be passed to the name parameter. From the Ansible yum module documentation: You can also pass a url or a local path to a rpm file. To operate on several packages this can accept a comma separated list of packages or (as of 2.0) a list of ...


35

This is an old question, but it is still one the first results in google search, so I'd like post the solution that got my problem solved. 1) create a new file /etc/yum.repos.d/city-fan.repo 2) Paste the following contents: [CityFan] name=City Fan Repo baseurl=http://www.city-fan.org/ftp/contrib/yum-repo/rhel$releasever/$basearch/ enabled=1 gpgcheck=0 3) ...


27

As in dpkg/1.17.2, it implements --verify option, according to this debian bug report. Note this is a relatively new change to dpkg. Date: Thu, 05 Dec 2013 04:56:31 +0100 line in the dpkg v1.17.2 package shows this. Here is a brief description of --verify action quoted from the man page of dpkg. -V, --verify [package-name...] Verifies the ...


25

Yes, you have to have an active RHEL subscription to download packages from RHEL's repositories. If your machine has never been subscribed, or the subscription is expired, you will not be able to use any of the repositories provided by RHEL. Red Hat states, in relevant part: If you choose to let all your subscriptions expire and have no other active ...


25

You don't need to do any of this; RPM has a query format argument which will let you specify exactly the data you want to receive. It will even output without line endings if you don't specify them. For instance: rpm --queryformat "%{NAME} %{VERSION} %{RELEASE} %{ARCH}" -q coreutils rpm --queryformat "The version of %{NAME} is %{VERSION}\n" -q coreutils ...


23

A quick overview of architecture names for x86 systems: i386: The 80386 CPU has historically been the bare minimum for running Linux on a PC-compatible system. Consequently, a package for "i386" is designed for maximum compatibility and can run on any x86-like system; a system that describes itself as "i386" is either ancient or exotic, and can only be ...


21

1 is the RPM epoch number. It overrides the normal comparison order on version checking. So, if there is some odd reason why you as a packager want to mark a lower version number as an upgrade, you can tag it with an Epoch number. yum info xorg-x11-xauth Name : xorg-x11-xauth Arch : x86_64 Epoch : 1 Version : 1.0.9 Release : 1....


21

In RHEL 5 and previous versions, yum install only accepted package names from enabled repositories, and did not accept paths to local RPMs; you had to use yum localinstall to install these. In RHEL 6 and later, yum install accepts both package names and local filenames, so localinstall is no longer necesary, but it's included for backward compatibility. In ...


19

There's a much easier way of issuing this query: rpm -qa | grep bind or rpm -q bind. The former is best if you're not completely sure of the package name.


18

This kind of error is likely caused by a scriptlet. When removing a package, RPM would run the "preuninstall" before removing a package, and the "postuninstall" after removing it. If the "preuninstall" fails, the package will not be removed. You can check the scriptlets of your package with rpm -q --scripts postgresql93-server. For example, the postgresql92-...


17

The haproxy package has been removed from EPEL because it is now included with RHEL 6.4 (and will be in derivative distributions after they build 6.4). Red Hat Enterprise Linux 6.4 introduces the haproxy package as a Technology Preview. If you need it now, you can obtain Red Hat's 6.4 SRPM and rebuild it on your system (the same way CentOS will shortly). ...


17

# rpm -qp --scripts getpagespeed-extras-release-7-1.el7.gps.noarch.rpm warning: getpagespeed-extras-release-7-1.el7.gps.noarch.rpm: Header V4 RSA/SHA1 Signature, key ID 222b0e83: NOKEY postinstall scriptlet (using /bin/sh): curl -s -m 3 https://www.getpagespeed.com/SCM/release-post-install.php 2>/dev/null | bash >/dev/null 2>&1 https://www....


16

I've been told the official way to do what I'm seeking is in Python: from rpmUtils.miscutils import splitFilename (n, v, r, e, a) = splitFilename(filename) I've written a short Python program that does what I need. I will offer the script to the rpmdev project for inclusion.


16

It seems your libgcc.x86_64 has a different version than the libgcc.i686 you are trying to install (4.4.7-3 vs. 4.4.7-4). Try to update the x86_64 lib together with the installation of the i686-lib: yum install libgcc.x86_64 libgcc.i686


16

You discovered the rpm's scripts run a script from the Internet, and that script currently redirects to what might be malware. Although, I'm not finding much of a payload that does anything. rpm cannot completely track what happened because it is running an arbitrary script. gpgcheck will not help you, both the getpagespeed-extras-7-6.el7.gps.noarch.rpm ...


15

An alternative is to add the CentOS repository to your yum configs. CentOS is in large part a derivative of RHEL. As such, most of its packages are compatible with RHEL. Michael Cutler wrote a guide for installing CentOS packages on RHEL. Briefly: # find out the release (version) of your RHEL # ex: 5.0, 6.0, 6.3 lsb_release -r cat /etc/issue # create a ...


15

Actually the yum module can install an RPM directly from a given URL: - name: Remote RPM install with yum yum: name=http://example.com/some_package.rpm


15

What you would need to do is: wget https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm If you still get an SSL warning try: wget --no-check-certificate https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm Then you can rpm -Uvh webtatic-release.rpm Which should show up here: ll /etc/yum.repos.d


14

This is now possible as of RPM 4.13. https://rpm.org/user_doc/boolean_dependencies.html It can be just simple as: Requires: (pkgA >= 3.2 or pkgB)


13

It is possible to download the packages of an RPM which is already installed using the --downloadonly switch. I am not sure why yum doesn't check this setting before checking whether the package is already installed, but I guess it could be caused by the underlying architecture of the tool. Anyway, all you need to do is to tell yum to reinstall the package: ...


13

You have installed the repository that makes PostgreSQL packages available (check /etc/yum.repos.d). Now you can do yum update and actually install the DB with yum install postgresql96-server.


12

In this case, use the i386 (or 32-bit) package.


12

For rpm you must specify where to get the file with the new version of the package. yum, which is a more intelligent management system, try to find a new version of the package in their repositories, will look for the package dependencies, will look for the fastest repository mirror (and make a lot of other pleasantrie)


11

# # Install yumdownloader # yum install yum-utils # # search modified files (in this case: from pam_ldap) # rpm -V pam_ldap S.5....T. c /etc/pam_ldap.conf # # make tmp-dir and download rpm # mkdir Temp cd Temp yumdownloader pam_ldap # # extract rpm to current folder # rpm2cpio pam_ldap-185-11.el6.x86_64.rpm | cpio -idmv # # check diff # diff etc/...


11

Parsing the results of this command is the most complete answer. You'll need to know the exact package name. yum info bind Loaded plugins: refresh-packagekit, rhnplugin This system is receiving updates from RHN Classic or RHN Satellite. Installed Packages Name : bind Arch : x86_64 Epoch : 32 Version : 9.8.2 Release : 0.17.rc1....


10

This question is a bit old, but in case other people find it in search there is a more correct way to do this that does also allow the creation of an SRPM. In the prep section, instead of using the setup macro, you should instead just type out yourself what you want it to do, namely copying the source directory from SOURCES to BUILD, instead of unpacking an ...


10

Pick your method. Roll your own repo and keep this updated to the last version you want. Use a tool like Puppet. Use a distributed shell to issue the update commands. Use one machine as master and script a tool that reads the package list on the master and uses this on the others.


Only top voted, non community-wiki answers of a minimum length are eligible