Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CouchDB replication unauthorized error #4127

Closed
billoty opened this issue Jul 21, 2022 · 3 comments · Fixed by #4457
Closed

CouchDB replication unauthorized error #4127

billoty opened this issue Jul 21, 2022 · 3 comments · Fixed by #4457

Comments

@billoty
Copy link

billoty commented Jul 21, 2022

Description

Passing through the introduction in docs and some problems with authorization occurs.

{"error":"unauthorized","reason":"unauthorized to access or create database http://127.0.0.1:5984/albums/"}

Steps to Reproduce

In chapter 1.7.4 execute the post request:

curl -vX POST http://admin:password@127.0.0.1:5984/_replicate \
     -d '{"source":"http://127.0.0.1:5984/albums","target":"http://127.0.0.1:5984/albums-replica"}' \
     -H "Content-Type: application/json"

after creating a target database.

Expected Behaviour

CouchDB returns JSON with

"ok": true

Your Environment

  • CouchDB version used: 3.2.2
  • Browser name and version: curl 7.68.0
  • Operating system and version: Ubuntu 20.04.3
@nickva
Copy link
Contributor

nickva commented Jul 21, 2022

Thanks for your report @billoty. It seems that section of the documentation hasn't been updated since we switched to requiring an admin password to be set up by default. Try to add admin:password for the source and target endpoint url and it should work.

@ryuusama09
Copy link

hi @nickva , I would like to work on this issue if it is still open

@nickva
Copy link
Contributor

nickva commented Sep 23, 2022

@ryuusama09 thanks for wanting to take a look!

The main task would be to go through the replication (and possibly other docs) in the src/docs folder and see if there are any tutorial URL links without a username and password, and update them to have a user name and password like adm:pass, admin:password or similar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants