• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1820
  • Last Modified:

PHP Warning: Function registration failed - duplicate name

Hello,
I recently upgraded Apache and PHP and things went great (well, not great, but things are back to working now!)  I went to my httpd-error.log just to make sure nothing crazy was going on.  I found some errors when Apache is restarted:

[Tue Apr 11 15:42:05 2006] [notice] SIGHUP received.  Attempting to restart
PHP Warning:  Function registration failed - duplicate name - xml_parser_create in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_parser_create_ns in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_object in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_element_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_character_data_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_processing_instruction_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_default_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_unparsed_entity_decl_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_notation_decl_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_external_entity_ref_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_start_namespace_decl_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_set_end_namespace_decl_handler in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_parse in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_parse_into_struct in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_get_error_code in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_error_string in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_get_current_line_number in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_get_current_column_number in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_get_current_byte_index in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_parser_free in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_parser_set_option in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - xml_parser_get_option in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - utf8_encode in Unknown on line 0
PHP Warning:  Function registration failed - duplicate name - utf8_decode in Unknown on line 0
PHP Warning:  xml:  Unable to register functions, unable to load in Unknown on line 0
[Tue Apr 11 15:42:06 2006] [notice] Apache/1.3.34 (Unix) PHP/4.4.2 configured -- resuming normal operations
[Tue Apr 11 15:42:06 2006] [notice] Accept mutex: flock (Default: flock)


I have read that this is due to statically linked modules into php but also using dynamic extensions.  I checked my php.ini file and there are no extra extensions (see php.ini snip file below)
http://www.faqts.com/knowledge_base/view.phtml/aid/18591/fid/68

;;;;;;;;;;;;;;;;;;;;;;
; Dynamic Extensions ;
;;;;;;;;;;;;;;;;;;;;;;
;
; If you wish to have an extension loaded automatically, use the following
; syntax:
;
;   extension=modulename.extension
;
; For example, on Windows:
;
;   extension=msql.dll
;
; ... or under UNIX:
;
;   extension=msql.so
zend_extension="/usr/local/lib/php/20020429/xdebug.so"
xdebug.remote_enable=On
xdebug.remote_handler="gdb"
xdebug.remote_host="localhost"
xdebug.output_dir="/var/log/xdebug/"

zend_extension="/usr/local/lib/php/20020429/eaccelerator.so"
eaccelerator.shm_size="32"
eaccelerator.cache_dir="/tmp/eaccelerator"
eaccelerator.enable="1"
eaccelerator.optimizer="1"
eaccelerator.check_mtime="1"
eaccelerator.debug="0"
eaccelerator.filter=""
eaccelerator.shm_max="0"
eaccelerator.shm_ttl="3600"
eaccelerator.shm_prune_period="0"
eaccelerator.shm_only="0"
eaccelerator.compress="1"
eaccelerator.compress_level="9"
eaccelerator.allowed_admin_path="/usr/local/www/data-dist/tools/"
;
; Note that it should be the name of the module only; no directory information
; needs to go here.  Specify the location of the extension with the
; extension_dir directive above.

Here is some additional system info if it helps:
PHP version = 4.4.2 apache
Webserver = Apache/1.3.34 (Unix) PHP/4.4.2
Database = mysqlt 4.1.12, lock.system=flock
Toolkits = Exif, Thumbnail, ArchiveUpload, Ffmpeg, NetPBM, ImageMagick, Gd
Operating system = FreeBSD localhost.localdomain 5.4-RELEASE FreeBSD 5.4-RELEASE #0: Sun May 8 10:21:06 UTC 2005 root@harlow.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386

Thanks a ton for any assistance!
0
tomtomtom123
Asked:
tomtomtom123
1 Solution
 
ixtiCommented:
IMHO the problem is in xml extansion.
Try to comment line with extension like "extension=php_xmlrpc.dll" or to re-upload this extension.
0
 
tomtomtom123Author Commented:
Thanks so much for helping out with this.  I verified that the xmlrpc.dll extension was already commented out (under windows extensions).  I did recently upgrade php_xml and went to check.  Seems that I have two different packages installed:

  php4-xml-4.3.11_1
  php4-xml-4.4.2_1

So, I tried to remove the older version, and it said it relied on php4-extensions.  I removed the newer version, removed php4-extensions, removed the older version and then reinstalled php4-extensions with dependencies.  Now, everything is up and happy.  Awarding the points for getting my mind on track.

Thanks!
0

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now