memcache Ubunutu

49 views
Skip to first unread message

carlbe...@gmail.com

unread,
Aug 1, 2008, 1:52:57 AM8/1/08
to memcached
Hi,

I just installed memcache on Ubuntu 8.04. I used the following
command to install it:

sudo apt-get install php5-memcache

It installed fine but when I attempt to use it I get the following
error:

Fatal error: Class 'Memcache' not found in /var/www/ie/test.php on
line 2


This is the code on line 2:

$memcache = new Memcache;


I looked through the various php.ini files but I did not find anything
on memcache. Does anyone know what I have to do to get memcache to
work.

Thanks,

Carl



http://www.gaihosa.com
http://ex500.net46.net

Mike Panchenko

unread,
Aug 1, 2008, 2:57:11 AM8/1/08
to memc...@googlegroups.com
Did you try an apache restart?

sudo /etc/init.d/apache2 restart

Hopefully that'll load up the extension and get you on your way :)

Cheers.

Mike.

Joseph Engo

unread,
Aug 1, 2008, 3:38:25 AM8/1/08
to memc...@googlegroups.com
Make sure you have a extension=memcache.so in your /etc/php.ini

---
http://linkped.com - Get that link I sent ya ?


carlbe...@gmail.com

unread,
Aug 1, 2008, 7:46:56 AM8/1/08
to memcached
Thanks,


That did the trick and I didn't have to reset apache either.
On Aug 1, 3:38 am, Joseph Engo <dev.toas...@gmail.com> wrote:
> Make sure you have a extension=memcache.so in your /etc/php.ini
>
> On Jul 31, 2008, at 10:52 PM, carlberna...@gmail.com wrote:
>
>
>
>
>
> > Hi,
>
> > I just installed memcache on Ubuntu 8.04.  I used the following
> > command to install it:
>
> > sudo apt-get install php5-memcache
>
> > It installed fine but when I attempt to use it I get the following
> > error:
>
> > Fatal error: Class 'Memcache' not found in /var/www/ie/test.php on
> > line 2
>
> > This is the code on line 2:
>
> > $memcache = new Memcache;
>
> > I looked through the various php.ini files but I did not find anything
> > on memcache.  Does anyone know what I have to do to get memcache to
> > work.
>
> > Thanks,
>
> > Carl
>
> >http://www.gaihosa.com
> >http://ex500.net46.net
>
> ---http://linkped.com- Get that link I sent ya ?

Paul Scott

unread,
Aug 1, 2008, 7:44:01 AM8/1/08
to memc...@googlegroups.com

On Thu, 2008-07-31 at 22:52 -0700, carlbe...@gmail.com wrote:

> I looked through the various php.ini files but I did not find anything
> on memcache. Does anyone know what I have to do to get memcache to
> work.

That just means that you haven't added the memcached extension to your
php.ini file:

extension=memcached.so

then restart apache and check again.

--Paul

Reply all
Reply to author
Forward
0 new messages