Results 1 to 7 of 7

Thread: php-memcache SuSE 11.1

  1. #1

    Default php-memcache SuSE 11.1

    How do I get the php module for memcache to work in SuSE 11.1 ? I have added the repo and YaST installed php-5mod_memcache but can't get the apache server to use it.

  2. #2
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: php-memcache SuSE 11.1

    First thing to check is that it is being loaded by PHP. Put this PHP script on your webserver and view it:

    <?php
    phpinfo();
    ?>

    If memcache is not listed as a loaded module, you need to enable it. But do the test first.

    Naturally you need to restart Apache after installing the module.

  3. #3

    Default Re: php-memcache SuSE 11.1

    I have looked at the phpinfo and the module is not listed there. How do I enable it ?

  4. #4
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: php-memcache SuSE 11.1

    Ok, what you need to do is put a file in /etc/php5/conf.d/memcache.ini. It should contain one line:

    extension=memcache.so

    This is assuming the loadable object file is in /usr/lib/php5/extensions (lib64 for 64-bit) and called memcache.so. You can check what was installed from the package with

    rpm -ql php5-memcache

    All this assumes that the memcache package was built for the same version of PHP that you are running. If it wasn't, then all this probably doesn't work. If it was a package for a different distro or even a different version of openSUSE, no way.

    I have a bad feeling about this because normally the ini file is contained in the package and should enable the loadable object when the package is installed.

    After adding that ini file, restart Apache and look at phpinfo again.

  5. #5

    Default Re: php-memcache SuSE 11.1

    Ahh right. The repo I added has installed apache2-mod_memcache rather than the php5-memcache module which I actually can't seem to find anywhere.

  6. #6
    Join Date
    Jun 2008
    Location
    UTC+10
    Posts
    9,686
    Blog Entries
    4

    Default Re: php-memcache SuSE 11.1

    Do a package search at software.opensuse.org

  7. #7

    Default Re: php-memcache SuSE 11.1

    nice one, thanks ken. Had to update the php core files but got it installed now.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •