Chris Kenward
asked on
phpMyAdmin - needs php-mbcrypt and php-common
I've just added phpMyAdmin to one of my CentOS servers. The server is running version 5.5
I've installed phpMyAdmin version : 3.3.8.1
In the docs the package says it needs extension php-mbstring but when I try to install this using YUM I get the following error:
[root@trent phpMyAdmin]# yum install php-mbstring
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
* addons: anorien.csc.warwick.ac.uk
* base: anorien.csc.warwick.ac.uk
* extras: mirrors.manchester.icecolo .com
* updates: mirrors.manchester.icecolo .com
84 packages excluded due to repository priority protections
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-mbstring.i386 0:5.1.6-27.el5_5.3 set to be updated
--> Processing Dependency: php-common = 5.1.6-27.el5_5.3 for package: php-mbstring
--> Finished Dependency Resolution
php-mbstring-5.1.6-27.el5_ 5.3.i386 from updates has depsolving problems
--> Missing Dependency: php-common = 5.1.6-27.el5_5.3 is needed by package php-mbstring-5.1.6-27.el5_ 5.3.i386 (updates)
Error: Missing Dependency: php-common = 5.1.6-27.el5_5.3 is needed by package php-mbstring-5.1.6-27.el5_ 5.3.i386 (updates)
You could try using --skip-broken to work around the problem
You could try running: package-cleanup --problems
package-cleanup --dupes
rpm -Va --nofiles --nodigest
If I then try and install php-common I get the following:
[root@trent phpMyAdmin]# yum install php-common
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
* addons: anorien.csc.warwick.ac.uk
* base: anorien.csc.warwick.ac.uk
* extras: mirrors.manchester.icecolo .com
* updates: mirrors.manchester.icecolo .com
84 packages excluded due to repository priority protections
Setting up Install Process
Package matching php-common-5.1.6-27.el5_5. 3.i386 already installed. Checking for update.
Nothing to do
Stumped. How on earth do I get around this? This is a live server, running about twenty databases and php, so I have to be very careful that whatever I do, it doesn't affect anything running on the server. Is there a way to get these packages either installed or, if they are at the wrong level, reinstalled, without screwing up my MySQL or PHP installation on this server?
Any help gratefully received.
Cheers
Chris
I've installed phpMyAdmin version : 3.3.8.1
In the docs the package says it needs extension php-mbstring but when I try to install this using YUM I get the following error:
[root@trent phpMyAdmin]# yum install php-mbstring
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
* addons: anorien.csc.warwick.ac.uk
* base: anorien.csc.warwick.ac.uk
* extras: mirrors.manchester.icecolo
* updates: mirrors.manchester.icecolo
84 packages excluded due to repository priority protections
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-mbstring.i386 0:5.1.6-27.el5_5.3 set to be updated
--> Processing Dependency: php-common = 5.1.6-27.el5_5.3 for package: php-mbstring
--> Finished Dependency Resolution
php-mbstring-5.1.6-27.el5_
--> Missing Dependency: php-common = 5.1.6-27.el5_5.3 is needed by package php-mbstring-5.1.6-27.el5_
Error: Missing Dependency: php-common = 5.1.6-27.el5_5.3 is needed by package php-mbstring-5.1.6-27.el5_
You could try using --skip-broken to work around the problem
You could try running: package-cleanup --problems
package-cleanup --dupes
rpm -Va --nofiles --nodigest
If I then try and install php-common I get the following:
[root@trent phpMyAdmin]# yum install php-common
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
* addons: anorien.csc.warwick.ac.uk
* base: anorien.csc.warwick.ac.uk
* extras: mirrors.manchester.icecolo
* updates: mirrors.manchester.icecolo
84 packages excluded due to repository priority protections
Setting up Install Process
Package matching php-common-5.1.6-27.el5_5.
Nothing to do
Stumped. How on earth do I get around this? This is a live server, running about twenty databases and php, so I have to be very careful that whatever I do, it doesn't affect anything running on the server. Is there a way to get these packages either installed or, if they are at the wrong level, reinstalled, without screwing up my MySQL or PHP installation on this server?
Any help gratefully received.
Cheers
Chris
You might try a "yum clean all" and "yum update" then try installing php-mbstring with "yum install php-mbstring".
If that doesn't do it, perhaps rebuilding your rpm database would be worth a try.
1) make a quick & dirty backup your rpm stuffs
cd /var/lib
tar cvzpf rpm.tgz rpm/
2) cleanup & rebuild the rpm database
rm -f /var/lib/rpm/__db*
rpm -vv –rebuilddb
3) try installing php-mbstring again
If the rebuild barfs you can unpack the backup that we made to restore the rpm directory to its previous state.
ASKER
@babblo :
Yeah sorry - it was php-mcrypt that is needed for phpMyAdmin. If I try to install that one I get the same sort of error - as follows:
Package php-mcrypt-5.1.6-15.el5.ce ntos.1.i38 6 already installed and latest version
So why isn't phpMyAdmin recognising that these items are installed?
@jraidan :
Going to try that now and will let you know what happens. As long as it doesn't upset my MySQL and PHP installations I'll be happy. I read somewhere that installing one of these extensions could under some circumstances screw up the php installation.... OOPS?
Cheers
Chris
Yeah sorry - it was php-mcrypt that is needed for phpMyAdmin. If I try to install that one I get the same sort of error - as follows:
Package php-mcrypt-5.1.6-15.el5.ce
So why isn't phpMyAdmin recognising that these items are installed?
@jraidan :
Going to try that now and will let you know what happens. As long as it doesn't upset my MySQL and PHP installations I'll be happy. I read somewhere that installing one of these extensions could under some circumstances screw up the php installation.... OOPS?
Cheers
Chris
ASKER
@jraidan
If I do an update after "clean all" I get the following:
Loaded plugins: fastestmirror, priorities
Determining fastest mirrors
* addons: mirrors.dedipower.com
* base: mirrors.dedipower.com
* extras: mirror.bytemark.co.uk
* updates: mirrors.dedipower.com
addons | 951 B 00:00
addons/primary | 202 B 00:00
base | 2.1 kB 00:00
base/primary_db | 1.6 MB 00:01
extras | 2.1 kB 00:00
extras/primary_db | 188 kB 00:00
updates | 1.9 kB 00:00
updates/primary_db | 864 kB 00:00
utterramblings | 951 B 00:00
utterramblings/primary | 30 kB 00:00
utterramblings 103/103
84 packages excluded due to repository priority protections
Setting up Update Process
No Packages marked for Update
The line that concerns me is the one that says "84 packages...." Why is this happening?
Cheers
Chris
If I do an update after "clean all" I get the following:
Loaded plugins: fastestmirror, priorities
Determining fastest mirrors
* addons: mirrors.dedipower.com
* base: mirrors.dedipower.com
* extras: mirror.bytemark.co.uk
* updates: mirrors.dedipower.com
addons | 951 B 00:00
addons/primary | 202 B 00:00
base | 2.1 kB 00:00
base/primary_db | 1.6 MB 00:01
extras | 2.1 kB 00:00
extras/primary_db | 188 kB 00:00
updates | 1.9 kB 00:00
updates/primary_db | 864 kB 00:00
utterramblings | 951 B 00:00
utterramblings/primary | 30 kB 00:00
utterramblings 103/103
84 packages excluded due to repository priority protections
Setting up Update Process
No Packages marked for Update
The line that concerns me is the one that says "84 packages...." Why is this happening?
Cheers
Chris
Are you sure on the installed PHP version?
phpmyadmin v3 needs at least PHP v5.2
You can test with:
I had a similar problem using CentOS 5.5 distribution, and did resolve by adding an additional repo to my CentOS:
HTH, Patric
phpmyadmin v3 needs at least PHP v5.2
You can test with:
rpm -q php
orphp -v
I had a similar problem using CentOS 5.5 distribution, and did resolve by adding an additional repo to my CentOS:
[c5-testing]
name=CentOS-5 Testing
baseurl=http://dev.centos.org/centos/$releasever/testing/$basearch/
enabled=1
gpgcheck=1
gpgkey=http://dev.centos.org/centos/RPM-GPG-KEY-CentOS-testing
includepkgs=php*
HTH, Patric
ASKER
Hi Patric
Thx for the reply. I've done the things you suggest as follows:
rpm -q php gives:
php-5.2.14-jason.1
php -v gives :
PHP Warning: PHP Startup: mcrypt: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP compiled with module API=20060613, debug=0, thread-safety=0
These options need to match in Unknown on line 0
PHP 5.2.14 (cli) (built: Aug 27 2010 16:40:16)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
That error is a new one, probably only started today as I haven't seen that before...
Should I add the lines for the repo just as you've put them in?
Apologies - this is all pretty new to me! :(
Cheers
Chris
Thx for the reply. I've done the things you suggest as follows:
rpm -q php gives:
php-5.2.14-jason.1
php -v gives :
PHP Warning: PHP Startup: mcrypt: Unable to initialize module
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP compiled with module API=20060613, debug=0, thread-safety=0
These options need to match in Unknown on line 0
PHP 5.2.14 (cli) (built: Aug 27 2010 16:40:16)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
That error is a new one, probably only started today as I haven't seen that before...
Should I add the lines for the repo just as you've put them in?
Apologies - this is all pretty new to me! :(
Cheers
Chris
ASKER
Hi again, Patric
Just had a look in the CentOS-Base.repo file and this is what I found in the [updates] section. I notice that the line you have above is there but it's been commented out. Any clues?
[updates]
name=CentOS-$releasever - Updates
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates
#baseurl=http://mirror.centos.org/centos/$releasever/updates/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm -gpg/RPM-G PG-KEY-Cen tOS-5
priority=1
The "priority=1" was added today because I made some changes and the doc said to add this to all except the bottom one which was made priority=2. Hope this helps?
Cheers
Chris
Just had a look in the CentOS-Base.repo file and this is what I found in the [updates] section. I notice that the line you have above is there but it's been commented out. Any clues?
[updates]
name=CentOS-$releasever - Updates
mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates
#baseurl=http://mirror.centos.org/centos/$releasever/updates/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm
priority=1
The "priority=1" was added today because I made some changes and the doc said to add this to all except the bottom one which was made priority=2. Hope this helps?
Cheers
Chris
Chris,
to me it looks like you messed up by using a PHP rpm file that does not fit nicely into CentOS. After all, finding a correct rpm for a distribution can be hell of a job...
I would do the following:
1) create a new file
2) as root, try a
FYI, this is a list of packages related tp php, that I have on a CentOS 5.5 box, and a nicely installed phpmyadmin v3 (taken from /var/log/yum.log):
Good luck :)
Patric
to me it looks like you messed up by using a PHP rpm file that does not fit nicely into CentOS. After all, finding a correct rpm for a distribution can be hell of a job...
I would do the following:
1) create a new file
/etc/yum.repos.d/c5-testing.repo
and put my first post ([c5-testing]....) in it. - Please note that this is a completely different repo than "updates".2) as root, try a
yum upgrade php
If this fails, try uninstalling php with
rpm --erase php
, and then reinstall php with yum.FYI, this is a list of packages related tp php, that I have on a CentOS 5.5 box, and a nicely installed phpmyadmin v3 (taken from /var/log/yum.log):
php-common-5.2.10-1.el5.centos.i386
php-cli-5.2.10-1.el5.centos.i386
php-5.2.10-1.el5.centos.i386
php-ldap-5.2.10-1.el5.centos.i386
php-pdo-5.2.10-1.el5.centos.i386
php-mysql-5.2.10-1.el5.centos.i386
libmcrypt-2.5.8-4.el5.centos.i386
php-mcrypt-5.2.9-2.el5.centos.3.i386
php-mbstring-5.2.10-1.el5.centos.i386
Good luck :)
Patric
ASKER
Hi Patric
Can I erase PHP and reinstall while the server is live or will this screw up my customers webs and database access? Should I rather wait until late this evening?
All the best
Chris
Can I erase PHP and reinstall while the server is live or will this screw up my customers webs and database access? Should I rather wait until late this evening?
All the best
Chris
better wait, and better have a backup, as always.
If it it difficult to achieve this: why not use phpadmin v2?
If it it difficult to achieve this: why not use phpadmin v2?
ASKER
Hi Patric
When I try the yum upgrade php it loads the new repo but then exits with this:
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
* addons: mirrors.dedipower.com
* base: mirrors.dedipower.com
* extras: mirror.bytemark.co.uk
* updates: mirrors.dedipower.com
c5-testing | 1.9 kB 00:00
c5-testing/primary_db | 653 kB 00:01
Reducing Centos-5 Testing to included packages only
Finished
169 packages excluded due to repository priority protections
Setting up Upgrade Process
No Packages marked for Update
Do you think the "priority protections" I put into the base file would be the cause of this? Why did I have to put those priority=1 comments in and should I remove them?
Cheers
Chris
When I try the yum upgrade php it loads the new repo but then exits with this:
Loaded plugins: fastestmirror, priorities
Loading mirror speeds from cached hostfile
* addons: mirrors.dedipower.com
* base: mirrors.dedipower.com
* extras: mirror.bytemark.co.uk
* updates: mirrors.dedipower.com
c5-testing | 1.9 kB 00:00
c5-testing/primary_db | 653 kB 00:01
Reducing Centos-5 Testing to included packages only
Finished
169 packages excluded due to repository priority protections
Setting up Upgrade Process
No Packages marked for Update
Do you think the "priority protections" I put into the base file would be the cause of this? Why did I have to put those priority=1 comments in and should I remove them?
Cheers
Chris
ASKER
Hi Patric
Is v2 as secure and as good for maintenance stuff (backups, repairs etc.) as 3? Would the problem I'm having with the two different versions of the setup:
---
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP compiled with module API=20060613, debug=0, thread-safety=0
---
...continue to be a problem even if I revert to v2?
Cheers
Chris
Is v2 as secure and as good for maintenance stuff (backups, repairs etc.) as 3? Would the problem I'm having with the two different versions of the setup:
---
Module compiled with module API=20050922, debug=0, thread-safety=0
PHP compiled with module API=20060613, debug=0, thread-safety=0
---
...continue to be a problem even if I revert to v2?
Cheers
Chris
priority in yum:
priority=1 is the lowest priority for a repo to be selected. priority=99 (which is default value) is the highest priority here.
security in phpmyadmin v2:
Not sure on this, but honestly, most web hosters in Germany offer phpmyadmin v2 user interface to their webmaster users for backup, restore, and db administration.
I am not sure how to continue. You should either get rid of your installed php...-jason installation, or alternatively try to get all dependencies from the same source as the php packeage.
I am guessing that you used a rpm from "Utter Rambling repository". To add this repo to your yum config, follow these instructions:
http://www.jasonlitka.com/yum-repository/
In the same run, you should disable the other newly created repo "c5-testing" by changing the line enabled=1 into enabled =0.
After that, retray to reinstall php with
priority=1 is the lowest priority for a repo to be selected. priority=99 (which is default value) is the highest priority here.
security in phpmyadmin v2:
Not sure on this, but honestly, most web hosters in Germany offer phpmyadmin v2 user interface to their webmaster users for backup, restore, and db administration.
I am not sure how to continue. You should either get rid of your installed php...-jason installation, or alternatively try to get all dependencies from the same source as the php packeage.
I am guessing that you used a rpm from "Utter Rambling repository". To add this repo to your yum config, follow these instructions:
http://www.jasonlitka.com/yum-repository/
In the same run, you should disable the other newly created repo "c5-testing" by changing the line enabled=1 into enabled =0.
After that, retray to reinstall php with
yum reinstall php
- maybe this helps...
If the problem is just with phpMyAdmin, you don't need to reinstall all the software or fight with deps... forgot to "install" phpMyAdmin from RPM (yum) ...
You just need to download phpMyAdmin from the official site ( www.phpmyadmin.net/ ), uncompress the files, upload to the web server, point your browser where you has "installed" pma/setup and voilà!
Tell me if you need further information.
Have a nice day.
You just need to download phpMyAdmin from the official site ( www.phpmyadmin.net/ ), uncompress the files, upload to the web server, point your browser where you has "installed" pma/setup and voilà!
Tell me if you need further information.
Have a nice day.
ASKER
Hi Folks
I haven't run away - just busy - will get to try these things over the course of this weekend and then I'll get back to you with results.
Cheers
Chris
I haven't run away - just busy - will get to try these things over the course of this weekend and then I'll get back to you with results.
Cheers
Chris
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Hi small_student
Did that and it appeared to install fine. However, after reloading Apache I still get the error in the screen copy above.
Cheers
Chris
Did that and it appeared to install fine. However, after reloading Apache I still get the error in the screen copy above.
Cheers
Chris
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Hi small_student
WORKED! Great - so I now have phpMyAdmin working on the server, thanks. Will dish up needed points shortly. Question though - what do I do with the other repositories? Do I delete them or copy them back into the yum folder?
Thanks
Chris
WORKED! Great - so I now have phpMyAdmin working on the server, thanks. Will dish up needed points shortly. Question though - what do I do with the other repositories? Do I delete them or copy them back into the yum folder?
Thanks
Chris
You can copy them back. Never dish them you might need them a later point for instllation of other packages in the future.
[*] It's much better if you compile PHP by hand, so you have a php installation with just what you need. You can find a lot of step by step instructions about how to do that on the net.
Have a nice day!