How safe is it to install Fedora RPMs in CentOS 5? Does it depend on the version of the Fedora RPM or is it generally better to steer clear?
3 Answers
I recommend to use Fedora EPEL instead:
"Extra Packages for Enterprise Linux (EPEL) is a volunteer-based community effort from the Fedora project to create a repository of high-quality add-on packages for Red Hat Enterprise (RHEL) and its compatible spinoffs such as CentOS or Scientific Linux. Fedora is the upstream of RHEL and add-on packages for EPEL are sourced from the Fedora repository primarily and built against RHEL."
The binary RPMs of the latest Fedora release are built against much newer libraries and are therefore often not compatible with the older libraries of CentOS. If you want to try Fedora RPMs anyway (and if there is no EPEL alternative) I would get the Fedora Source RPM and try to recompile on CentOS (but often is will be difficult because of dependencies).
- 3,955
- 23
- 20
It's generally better to stay clear, and I don't think that answer will surprise you. Fedora RPM's can have dependencies on versions of software that do not exist on CentOS. For example, the Python 2.6 ABI is not available on CentOS - no matter what version - but is the default on Fedora.
Apart from this, it is also very possible that Fedora RPM's will use macros in RPM pre- and postscripts that are unavailable on CentOS or try to do stuff in those scripts that is not possible on CentOS.
That said, it is not impossible to use Fedora RPM's on CentOS. You might just be lucky. :-)
What is probably safer, is to rebuild the Fedora source RPM's on your CentOS machine: if the RPM's will build on the CentOS machine, my guess would be that you would be pretty safe. Of course, the RPM's then have become normal CentOS RPM's and not Fedora RPM's anymore...
- 10,269
- 2
- 32
- 47
I agree with wzzrd in that it is usually safest to steer clear of Fedora RPMs. I would check out the third-party RPM repositories like RPMforge and EPEL to see if the goodie you want has been repackaged by someone else already.
However: I have had reasonable success in installing fedora-equivalent RPMs from SRPMs into CentOS. What I mean by fedora-equivalent: you know that RHEL-4 was based on Fedora Core 3; similarly, RHEL-5 is based on FC-6. So you can take .SRPMs from FC-6 and then attempt to build and install them on CentOS-5 with a reasonable expectation of success.
Sometimes you can build and install SRPMs from the later FC releases, however you can quickly get into version drift for core libraries. You should generally NOT upgrade a CentOS RPM to its later FC equivalent unless you (a) know what you are doing and (b) don't mind cleaning up a big mess. This can spiral out of control REALLY QUICKLY and I recommend doing a dry-run in a throw-away VM before trying to do it on a live system.
- 14,223
- 6
- 46
- 77