471,311 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,311 software developers and data experts.

PHP on command line issues: Function registration failed - duplicate name

I just upgraded to PHP 4.4.2 on my Slackware 10.2 system. And
Apache/mySQL/PHP all work great through a browser. No errors.
But when I try to run a PHP script through the command line, which I
need to do, I get blocks of errors like:

root@slackserve:/var/www/htdocs# php ./phptest.php
PHP Warning: Unknown(): Unable to load dynamic library
'/usr/lib/php/extensions/mysql.so' - libmysqlclient.so.14: cannot open
shared object file: No such file or directory in Unknown on line 0
PHP Warning: Function registration failed - duplicate name -
textdomain in Unknown on line 0
PHP Warning: Function registration failed - duplicate name - gettext
in Unknown on line 0
PHP Warning: Function registration failed - duplicate name - _ in
Unknown on line 0
PHP Warning: Function registration failed - duplicate name - dgettext
in Unknown on line 0
PHP Warning: Function registration failed - duplicate name - dcgettext
in Unknown on line 0
PHP Warning: Function registration failed - duplicate name -
bindtextdomain in Unknown on line 0
PHP Warning: Function registration failed - duplicate name - ngettext
in Unknown on line 0
PHP Warning: Function registration failed - duplicate name - dngettext
in Unknown on line 0
PHP Warning: Function registration failed - duplicate name -
dcngettext in Unknown on line 0
PHP Warning: Function registration failed - duplicate name -
bind_textdomain_codeset in Unknown on line 0
PHP Warning: gettext: Unable to register functions, unable to load in
Unknown on line 0

Even so, it WILL actually spit out the proper data at the end. So, it's
technically working, but preceded by all these errors.
mysql.so is in the extensions dir just fine. And php.ini have no
references in it anywhere to any of these other items mentioned.

Any pointers on what I should look into here?
Thanks!
-Liam

Mar 14 '06 #1
2 7481
Looks like both the MySQL and gettext extensions were compiled
statically into the PHP binary. Those errors probably are triggered too
when Apache starts--you just don't see them. Edit php.ini and comment
out these two extensions. Then check phpinfo() through your browser to
see if they're still active.

Mar 15 '06 #2

Chung Leong wrote:
Looks like both the MySQL and gettext extensions were compiled
statically into the PHP binary. Those errors probably are triggered too
when Apache starts--you just don't see them. Edit php.ini and comment
out these two extensions. Then check phpinfo() through your browser to
see if they're still active.


Oh dear, that's it.
I wouldn't have expected that that was the problem and removing the
lines the fix. Counter-intuitive.
Thanks for the help!
-Liam

Mar 15 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

9 posts views Thread by shank | last post: by
10 posts views Thread by Marek Zawadzki | last post: by
2 posts views Thread by =?Utf-8?B?UmFtb24gR2VuZQ==?= | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.