SG Community RebuildChannels returned error

Hi all,

a SG Community Edition v2.8.4, started to panic and crashing with the following error:

2024-06-07T16:49:05.413Z [DBG] Import+: Created new rev ID for doc “” / “3-ff3bcf3b1595d2e734bbf640ac1c9d51”
2024-06-07T16:49:51.653Z [WRN] Error when querying index using statement: [SELECT meta(<bucket>).xattrs.sync.access.role:User as value FROM <bucket> USE INDEX (sg_access_x1) WHERE any op in object_pairs(meta(<bucket>).xattrs.sync.access) satisfies op.name = $userName end;] parameters: [map[userName:role:User]] error:[12008] Error performing bulk get operation - cause: {2 errors, starting with dial tcp 172.18.2.3:11210: connect: cannot assign requested address} – base.(*CouchbaseBucketGoCB).Query() at bucket_n1ql.go:78
2024-06-07T16:49:51.653Z [WRN] QueryAccess returned error: [12008] Error performing bulk get operation - cause: {2 errors, starting with dial tcp 172.18.2.3:11210: connect: cannot assign requested address} – db.(*DatabaseContext).ComputeSequenceChannelsForPrincipal() at crud.go:2111
2024-06-07T16:49:51.653Z [WRN] channelComputer.ComputeChannelsForPrincipal returned error for &{Name
:User ExplicitChannels
: Channels_: Sequence_:1 PreviousChannels_: vbNo: cas:0}: [12008] Error performing bulk get operation - cause: {2 errors, starting with dial tcp 172.18.2.3:11210: connect: cannot assign requested address} – auth.(*Authenticator).rebuildChannels() at auth.go:174
2024-06-07T16:49:51.654Z [WRN] RebuildChannels returned error: [12008] Error performing bulk get operation - cause: {2 errors, starting with dial tcp 172.18.2.3:11210: connect: cannot assign requested address} – auth.(*Authenticator).getPrincipal.func1() at auth.go:117

What could be the problem?
Is there any issue related to that version?
Is there any resolution?

The query wants to get documents from that address, but cannot connect to it. So either it has the wrong address, or the data node that is supposed to be at that address is not running, or it cannot reach that address.

But the SG connects to the bucket and check for the indexes.
Then when it tries to import the first document, I get that error.

Shouldn’t be related to connection issues.

https://www.google.com/search?q="cannot+assign+requested+address"

https://issues.couchbase.com/issues/?jql=text%20~%20"\"cannot%20assign%20requested%20address\"%2011210"

Also - see the warning at the bottom of this page - Access() | Couchbase Docs

Hi all,
as a followup, we resolved the issue upgrading to the SG 3.1.7 and changing the SyncFunction in order to reduce the users related channels from 15K+ to 15 channels.

Huge improvement.