apache / apache/couchdb

Couch DB | Replication Error | replication_auth_error

Open
#3,986 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Erlang
Stars
7k
Forks
1.1k
Avg merge
1d 16h
Merged PRs (30d)
9

Description

We are encountering below error in replicating "services" database
Version Details :

[root@couchstagedb1.bmi tmp]# curl http://admin:xxxxxx@couchstagedb1.bmi.expertcity.com:5984
{"couchdb":"Welcome","version":"3.1.1","git_sha":"ce596c65d","uuid":"xxxxxxxxxxxxxxxxxxx","features":["access-ready","partitioned","pluggable-storage-engines","reshard","scheduler"],"vendor":{"name":"The Apache Software Foundation"}}

Source standalone : couchstagedb1.bmi.expertcity.com
Target cluster: couchstagedb.aor.expertcity.com

[root@couchstagedb1.las ~]# /opt/ec/couchdb/couchdb_replication_restart.rb -u admin -p xxxxxx -t couchstagedb.aor.expertcity.com -c services -s
Replication is in error state the error is:
{replication_auth_error,
{session_request_failed,
"http://couchstagedb1.bmi.expertcity.com:5984/_session","admin",
req_timedout}}
Replication already running on couchstagedb.aor.expertcity.com for services from couchstagedb1.las.expertcity.com
Replication already running on couchstagedb.aor.expertcity.com for services from couchstagedb.ava.expertcity.com

Debug mode logs :

[error] 2022-04-04T10:21:59.915084Z couchdb@couchstagedb2.aor.expertcity.com <0.1089.0> -------- couch_replicator_httpc: auth plugin initialization failed "http://admin:*****@couchstagedb1.bmi.expertcity.com:5984/services/" {session_request_failed,"http://couchstagedb1.bmi.expertcity.com:5984/_session","admin",req_timedout}
[error] 2022-04-04T10:21:59.915268Z couchdb@couchstagedb2.aor.expertcity.com <0.1089.0> -------- throw:{replication_auth_error,{session_request_failed,"http://couchstagedb1.bmi.expertcity.com:5984/_session","admin",req_timedout}}: Replication bba30bcc7ff2d1566ee7413473142bce+continuous failed to start "http://admin:*****@couchstagedb1.bmi.expertcity.com:5984/services/" -> "http://admin:*****@couchstagedb.aor.expertcity.com:5984/services/" doc <<"shards/00000000-7fffffff/_replicator.1605555927">>:<<"services_couchstagedb1_bmi_expertcity_com">> stack:[{couch_replicator_httpc,setup,1,[{file,"src/couch_replicator_httpc.erl"},{line,59}]},{couch_replicator_api_wrap,db_open,3,[{file,"src/couch_replicator_api_wrap.erl"},{line,74}]}]

Please help

Contributor guide

Open the contributing guide

Research direction

Start with the replication error and the referenced entry points, src/couch_replicator_httpc.erl line 59 and src/couch_replicator_api_wrap.erl line 74. Investigate the timed-out _session request between the listed CouchDB hosts and define a reproducible failure and confirmed resolution before considering a code change.

Written by the indexing model from the issue text.

Assessment

Tech stack
erlang
Domain
databases, distributed-systems
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.