Cbbackup fails across Docker containers

Hello.

cbbackup failed across Docker containers with: error: SASL auth socket error: 172.29.0.2:11210, user: bucket_A.

  1. Administrator password is correct
  2. bucket_A with or without password protection, same issue
  3. I see no way of specifying the bucket’s password in the documentation, which is what appears to be missing
  4. Verified that all Bash variables resolve to the correct names, ports
  5. The backups directory structure is created fine in the target volume, no data are written to it other than the initial SQLite3 CREATE statement and some metadata

Command:

docker run --rm --name nbak -ti -v "$targetDirectory:$backupsDirectory" couchbase/server \
    cbbackup  "http://$serverName:$port" "$backupsDirectory" -u "$adminUser" -p "$password" -v

Nebula-backups

Output

2017-09-05 18:56:36,913: mt cbbackup...
2017-09-05 18:56:36,913: mt  source : http://192.168.1.200:8091
2017-09-05 18:56:36,913: mt  sink   : /backups
2017-09-05 18:56:36,913: mt  opts   : {'username': '<xxx>', 'verbose': 1, 'dry_run': False, 'extra': {'max_retry': 10.0, 'rehash': 0.0, 'dcp_consumer_queue_length': 1000.0, 'data_only': 0.0, 'uncompress': 0.0, 'nmv_retry': 1.0, 'conflict_resolve': 1.0, 'cbb_max_mb': 100000.0, 'report': 5.0, 'mcd_compatible': 1.0, 'try_xwm': 1.0, 'backoff_cap': 10.0, 'batch_max_bytes': 400000.0, 'report_full': 2000.0, 'flow_control': 1.0, 'batch_max_size': 1000.0, 'seqno': 0.0, 'design_doc_only': 0.0, 'recv_min_bytes': 4096.0}, 'single_node': False, 'ssl': False, 'vbucket_list': None, 'threads': 4, 'mode': 'diff', 'key': None, 'password': '<xxx>', 'id': None, 'silent': False, 'bucket_source': None}
2017-09-05 18:56:36,924: mt bucket: bucket_A
2017-09-05 19:01:04,331: w0   source : http://192.168.1.200:8091(bucket_A@172.29.0.2:8091)
2017-09-05 19:01:04,331: w0   sink   : /backups(bucket_A@172.29.0.2:8091)
2017-09-05 19:01:04,331: w0          :                total |       last |    per sec
error: SASL auth socket error: 172.29.0.2:11210, user: bucket_A

Please advise, thanks in advance :alien::pray:t2:

1 Like

Hi @pr3d4t0r,

Is port 11210 open on Docker Server B? Also, can you confirm that it works when you are using a bucket without a password? I don’t see a way to specify a bucket password either, which makes me believe that isn’t the problem (you are supplying admin credentials, which should be enough to access the bucket).

@matthew.groves - Thanks – yes, the ports were open. Super weird.

Solution (?)

No idea why, today I came back to testing the backup scripts again – and they worked the first time around without additional changes. Same script, password, Couchbase Servers, containers – everything the same. The only change was a Docker upgrade in my workstation between when I first posted the help request here, and today.

I suspect I hit some weird networking bug in Docker that was preventing the outside connections. I can’t think of any other explanation as to why the same exact call worked today but failed a few days ago.

Thanks for your help to all!

1 Like