Php startup: unable to load dynamic library tidy so

18 Replies

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    checkBest Answer

    What flavor are you running?

    On CentOS, it is as simple as running:

    #yum install php-tidy

    Was this post helpful? thumb_up thumb_down

  • BMoore

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    you sure its not

    yum install php5-tidy ?

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    BMoore wrote:

    you sure its not

    yum install php5-tidy ?

    On CentOS 5.9 [which is what I am running] it is php-tidy.  Could be that it gets changed under CentOS6 [I will find out soon as the upgrades start in the next couple weeks].   Ubuntu looks like it is php5-tidy.

    Was this post helpful? thumb_up thumb_down

  • Sorry I should of mentioned it's Red Hat Enterprise 6.1. I have tried yum install php-tidy which worked so thanks for the replies. I have another problem now where php -m does not show the module as being loaded, any ideas?

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    I know this is a dumb question, but did you restart your web services to reload php after installing?

    Was this post helpful? thumb_up thumb_down

  • Don't worry it's not a dumb question, I have learned from working in IT that you have to ask dumb questions lol.

    I have tried restarting the service, the server, removing php and re-installing along with Tidy but no luck.

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    Do you have a tidy.ini file in your /etc/php.d directory?

    And if you do, did you take out the 'extension=tidy.so' line from your php.ini file?

    Was this post helpful? thumb_up thumb_down

  • Yeah already tried that :S

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    And there is a tidy.so file in /usr/lib/php/modules ?

    And, since I'm sure there is since you installed it, you are looking for tidy and not php-tidy in the results of  php -m?

    Anything in the php errors log?  [Mine is named /var/log/php.errors.log which is, I believe, non-standard]

    Was this post helpful? thumb_up thumb_down

  • Just had a look and there isn't a tidy.so file in Modules. Tried find / -name tidy* but got no results back for tidy.so?

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    This is weird if there were no errors when installing via yum.

    Is this a 64 bit machine?  The tidy.so file would then be in /usr/lib64/php/modules.

    Was php installed initially through yum?  Or manually compiled? 

    Was this post helpful? thumb_up thumb_down

  • I installed from Yum. Yeah it's a 64bit machine and the file is not in the lib64 version of the directory either. I have tried uninstalling and reinstalling through yum but no luck. I setup a test VM with CentOS and it worked fine :s Just don't get why it's not working on Red Hat 6.

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    If you do:

    BASH

    yum list installed | grep php
    

    Does anything weird come back?  Like multiple versions, different repositories, etc.?   is php-tidy.x86_64 listed?

    Was this post helpful? thumb_up thumb_down

  • Here are the results I get. Also the output of php -m

    [root@localhost rhel-x86_64-server-6]# yum list installed | grep php
    php.x86_64                               5.3.3-22.el6                         @rhel-x86_64-server-6
    php-cli.x86_64                           5.3.3-22.el6                         @rhel-x86_64-server-6
    php-common.x86_64                        5.3.3-22.el6                         @rhel-x86_64-server-6

    [root@localhost rhel-x86_64-server-6]# yum list installed | grep tidy
    libtidy.x86_64                           0.99.0-19.20070615.1.el6             @rhel-x86_64-server-6
    tidy.x86_64                              0.99.0-19.20070615.1.el6             @rhel-x86_64-server-6

    [root@localhost bin]# php -m
    PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/tidy.so' - /usr/lib64/php/modules/tidy.so: cannot dynamically load executable in Unknown on line 0
    [PHP Modules]
    bz2
    calendar
    Core
    ctype
    curl
    date
    ereg
    exif
    fileinfo
    filter
    ftp
    gettext
    gmp
    hash
    iconv
    json
    libxml
    openssl
    pcntl
    pcre
    Phar
    readline
    Reflection
    session
    shmop
    SimpleXML
    sockets
    SPL
    standard
    tokenizer
    xml
    zip
    zlib

    Was this post helpful? thumb_up thumb_down

  • I have now got this working thanks for your help donges. When I installed via CentOS tidy.x86_64 and php-tidy.x86_64 were installed but Red Hat could not find the php-tidy.x86_64 rpm and I had to add the EPEL repository, then I managed to install php-tidy.x86_64 and it worked. Think there was a bit of stupidity on my part here and should have figured this out sooner.

    Thanks for the help.

    Was this post helpful? thumb_up thumb_down

  • donges

    This person is a verified professional.

    Verify your account to enable IT peers to see that you are a professional.

    datil

    Excellent!  Glad it got sorted and is working.

    Was this post helpful? thumb_up thumb_down

  • May you explain how you install php-tidy?
    I have you same problem, but I cannot get your solution in details.

    "I had to add the EPEL repository, then I managed to install php-tidy.x86_64 and it worked"

    What should I do?

    Thanks

    Was this post helpful? thumb_up thumb_down

  • for ubuntu :

          sudo apt-get install php5-tidy

    the restart the server

         sudo service apache2 restart

    Was this post helpful? thumb_up thumb_down

Chủ Đề