I am running a website with 2 servers for site code (in PHP) and 1 server as load balancer. All 3 also run couchbase instances as part of a single cluster.

In PHP code, I use buchets couchbase as follows:
$cluster = new \CouchbaseCluster('http://127.0.0.1:8091');
$greyloftWebbucket = $cluster->openBucket('some_bucket');
$query = \CouchbaseViewQuery::from('abcd', 'pqrs');
This layout works fine when all couchbase instances are running. When any of them is closed and I try to access the buckets, I get the following error randomly:
[2015-07-17 13:46:08] production.ERROR: exception 'CouchbaseException' with message 'Generic network failure. Enable detailed error codes (via LCB_CNTL_DETAILED_ERRCODES, or via `detailed_errcodes` in the connection string) and/or enable logging to get more information' in [CouchbaseNative]/CouchbaseBucket.class.php:282
Stack trace:
That is, once the page loads correctly and shows the contents of the bucket, and then once shows me the above errors. It doesn’t matter if I can directly access the load balancer or any of the servers.
, autofailover enabled , 1 couchbase. 3 LCB_LOGLEVEL=5
? Couchbase PHP SDK - ? .
Update:
,
$cluster = new \CouchbaseCluster('http://127.0.0.1:8091?detailed_errcodes=1');
. - ( ):
CouchbaseException in CouchbaseBucket.class.php line 74: The remote host refused the connection. Is the service up?
. Couchbase:
Failed over 'ns_1@<ip_address>': ok
Node ('ns_1@<ip_address>') was automatically failovered.
, SDK node. ? ?