You may get a dependency error on php-api like the following error when you try to install the packages php-mcrypt or php-mhash from the EPEL repository.
# yum install php-mcrypt ... Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package php-mcrypt.x86_64 0:5.1.6-5.el5 will be installed --> Processing Dependency: php-api = 20041225 for package: php-mcrypt-5.1.6-5.el5.x86_64 --> Finished Dependency Resolution Error: Package: php-mcrypt-5.1.6-5.el5.x86_64 (epel) Requires: php-api = 20041225 Installed: php-common-5.3.3-3.el6_2.8.x86_64 (@updates) php-api = 20090626 Available: php-common-5.3.3-3.el6_1.3.x86_64 (base) php-api = 20090626 Available: php-common-5.3.3-3.el6_2.5.x86_64 (updates) php-api = 20090626 Available: php-common-5.3.3-3.el6_2.6.x86_64 (updates) php-api = 20090626 You could try using --skip-broken to work around the problem You could try running: rpm -Va --nofiles --nodigest
The php-api dependency only existed on CentOS 5 and does not exist on CentOS 6. Chances are, you added the EPEL release package for CentOS 5 on your system instead of the one for CentOS 6.
# rpm -qa | grep epel-release epel-release-5-4.noarch
Remove it and install the proper package for CentOS 6.
# yum remove epel-release # rpm -ivh "http://be.mirror.eurid.eu/epel/6/i386/epel-release-6-7.noarch.rpm" # yum clean all # yum install php-mcrypt