Didja see this one:

http://us3.php.net/manual/en/function.memcache-debug.php

Not, perhaps, the best answer, and maybe even not possible in your
environment, but it may be useful for development, if not production.

You could also check the getServerStats functions to see if their
stats provide any indication that the server is up/down.

And finally, I suspect that you could submit a patch to get a
memcache_error() function without TOO much effort...

On Sun, February 25, 2007 5:35 pm, Cabbar Duzayak wrote:
> Hi,
>
> Before I start, I am not sure whether I should have sent this to
> Memcached or PHP mailing list. So, for those who are subscribed to
> both, I apologize.
>
> I have started using the PHP extension at
> http://pecl.php.net/package/memcache for memcached. But, one problem I
> am having right now is that, php functions tells you nothing about
> errors.
>
> For example, when you call Memcache::get, it returns true or false,
> but when it returns false does this mean item is not found, or
> Memcached is down, or there is a cache corruption / compression error,
> etc. etc. And, this also is the case for Memcache::set, again when it
> returns false, you have no idea about what is going on. I tried
> turning debugging on, and this did not help much.
>
> As far as I can see, memcache internally sets error nos, but this
> extension completely ignores this information. And, I saw something
> like:
>
> "PHP Notice:  Memcache::get(): marked server 'localhost:11211' as
> failed" in my php logs for some of the requests (like 5-10 out of a
> thousand), but server was up, and everthing was normal, and the
> request right after this one succeeded.
>
> In summary, is it possible to get these errors from PHP somehow so
> that we can have an idea about what is going on and how we can handle
> them? Possibly with something like "mysql_error" or "mysql_errno"
> functions?
>
> Thanks in advance...
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


-- 
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some starving artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to