Sync Gateway <--> Couchbase 502 errors

328 views
Skip to first unread message

Suresh Joshi

unread,
May 21, 2015, 7:17:24 PM5/21/15
to couc...@googlegroups.com

Hey all,

I have Couchbase and Sync Gateway sitting on the same server, and it's been working fine for a few days, but all of a sudden, some 502 errors were being spit out:

22:32:38.450345 ==== Couchbase Sync Gateway/1.0.4(34;04138fd) ====
22:32:38.450362 Opening db /db as bucket "app-data", pool "default", server <http://localhost:8091>
22:32:38.450448 Opening Couchbase database app-data on <http://localhost:8091>
22:32:38.451077 FATAL: Error opening database: 502 Unable to connect to server: Get http://localhost:8091/pools: dial tcp 127.0.0.1:8091: connection refused -- rest.RunServer() at config.go:415

Has anyone ever seen this before? I didn't touch either SG or CB, and it just stopped working at some point.

To fix it, I restarted both Couchbase and SG, and it just started working again...

Follow up: Are there any auto-reload services for SG or CB? 

Thanks!
-SJ


Laurent Doguin

unread,
May 27, 2015, 10:54:45 AM5/27/15
to couc...@googlegroups.com
Hi,

never saw that one before. Could you switch your Log level to debug? Also, are you using a LoadBalancer in the front?

Thanks
Laurent

Suresh Joshi

unread,
May 28, 2015, 8:50:29 AM5/28/15
to couc...@googlegroups.com
Hi, no, no load balancer. I'm using an nginx proxy, but that's it.

Unfortunately, I haven't been able to reproduce this, which sucks, because if it happened once, it'll happen again - but it might happen in production next time!

--
You received this message because you are subscribed to a topic in the Google Groups "Couchbase" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/couchbase/DB0Afd8XmtM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to couchbase+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Doru Chiulan

unread,
Jul 31, 2015, 6:48:52 PM7/31/15
to Couchbase
Happens for me too at random times.

I will enable the debugger and paste the logs.

21:47:13.161253 Enabling logging: [HTTP+ CRUD+ HTTP CRUD Access]

21:47:13.161291 ==== Couchbase Sync Gateway/1.0.3(81;fa9a6e7) ====

21:47:13.161310 Opening db /iserv_db as bucket "iServ", pool "default", server <http://localhost:8091>

21:47:13.161379 Opening Couchbase database iServ on <http://localhost:8091>

21:47:13.162083 FATAL: Error opening database: 502 Unable to connect to server: Get http://localhost:8091/pools: dial tcp 127.0.0.1:8091: connection refused -- rest.RunServer() at config.go:415

21:47:13.180277 Enabling logging: [HTTP+ CRUD+ HTTP CRUD Access]

21:47:13.180313 ==== Couchbase Sync Gateway/1.0.3(81;fa9a6e7) ====

21:47:13.180354 Opening db /iserv_db as bucket "iServ", pool "default", server <http://localhost:8091>

21:47:13.180402 Opening Couchbase database iServ on <http://localhost:8091>

21:47:13.180980 FATAL: Error opening database: 502 Unable to connect to server: Get http://localhost:8091/pools: dial tcp 127.0.0.1:8091: connection refused -- rest.RunServer() at config.go:415

Suresh Joshi

unread,
Sep 17, 2015, 11:25:55 PM9/17/15
to Couchbase
Just started to run into this one again too... No idea what's going on. Any solutions?
Reply all
Reply to author
Forward
0 new messages