You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Mark Richter <mr...@solarflare.com> on 2018/05/16 21:28:49 UTC

Error 500 when trying to create a new user

We have been using couchdb 2.1.1 as our back end database for several months now. We set up new RedHat or CentOS 7.4+ system installations using a bash script I wrote. We require a secure password for the admin user, and compaction is enabled in our local.ini.

Sometime in the last few weeks, installations using the same script now fails to function on new CentOS VMs as we cannot add a new user to the _users database. The operation generates an error 500 and no other explanation. Even the example in the CouchDB online manual (section 1.6) fails (password x'd out):

[solarflare@localhost ~]$ cat newcdbusr
#!/bin/bash

curl -X PUT http://admin:xxxxxxxx@localhost:5984/_users/org.couchdb.user:jan
-H "Accept: application/json"
-H "Content-Type: application/json"
-d '{"name": "jan", "password": "apple", "roles": [], "type": "user"}'

[solarflare@localhost ~]$ ./newcdbusr
{"error":"unknown_error","reason":"undefined"}
[solarflare@localhost ~]$

I went back and used an older CentOS minimal build (1618 I think, vs 1708 and 1804) that had been working for a long time, but that one also fails now. the installation script installs a series of packages that our software requires, along with erlang and couchdb (from the RH yum repos).

I have a gist of a diff between our local.ini and the distribution version at https://gist.github.com/sf-mrichter/e0a3d9207d3a74d1d1a1fdeb1c0039eb 2<https://gist.github.com/sf-mrichter/e0a3d9207d3a74d1d1a1fdeb1c0039eb> if that helps.

The last time I tried this, I noticed that httpd was not running, but even after 'sudo sytemctl restart httpd' and verifying that it is running, the couchdb user add fails (same error).

I just tried a fresh installation on a minimal CentOS 7.4 VM and only installed CouchDB from the couchdb repo, enabled and started couchdb, created the three main databases (_users, _replicator and _global_changes) and it still fails to add a new user, even with no admin password or any other changes to the default installation local.ini file.

I'm not a couchdb expert, so any pointers would be most appreciated.

Thanks!

The information contained in this message is confidential and is intended for the addressee(s) only. If you have received this message in error, please notify the sender immediately and delete the message. Unless you are an addressee (or authorized to receive for an addressee), you may not use, copy or disclose to anyone this message or any information contained in this message. The unauthorized use, disclosure, copying or alteration of this message is strictly prohibited.

RE: Error 500 when trying to create a new user

Posted by Mark Richter <mr...@solarflare.com>.
Yes, that's it.  Many thanks!

-----Original Message-----
From: Joan Touzet <wo...@apache.org>
Sent: Wednesday, May 16, 2018 9:19 PM
To: user@couchdb.apache.org
Subject: Re: Error 500 when trying to create a new user

This may be an instance of #1293:

https://github.com/apache/couchdb/issues/1293

Can you try down-levelling to js-1.8.5-19 and see if that fixes your problem?

We will have a fix for this with the next binary release of CouchDB, which is Real Soon Now.

-Joan

----- Original Message -----
From: "Mark Richter" <mr...@solarflare.com>
To: user@couchdb.apache.org
Sent: Wednesday, May 16, 2018 5:28:49 PM
Subject: Error 500 when trying to create a new user

We have been using couchdb 2.1.1 as our back end database for several months now. We set up new RedHat or CentOS 7.4+ system installations using a bash script I wrote. We require a secure password for the admin user, and compaction is enabled in our local.ini.

Sometime in the last few weeks, installations using the same script now fails to function on new CentOS VMs as we cannot add a new user to the _users database. The operation generates an error 500 and no other explanation. Even the example in the CouchDB online manual (section 1.6) fails (password x'd out):

[solarflare@localhost ~]$ cat newcdbusr
#!/bin/bash

curl -X PUT http://admin:xxxxxxxx@localhost:5984/_users/org.couchdb.user:jan
-H "Accept: application/json"
-H "Content-Type: application/json"
-d '{"name": "jan", "password": "apple", "roles": [], "type": "user"}'

[solarflare@localhost ~]$ ./newcdbusr
{"error":"unknown_error","reason":"undefined"}
[solarflare@localhost ~]$

I went back and used an older CentOS minimal build (1618 I think, vs 1708 and 1804) that had been working for a long time, but that one also fails now. the installation script installs a series of packages that our software requires, along with erlang and couchdb (from the RH yum repos).

I have a gist of a diff between our local.ini and the distribution version at https://gist.github.com/sf-mrichter/e0a3d9207d3a74d1d1a1fdeb1c0039eb 2<https://gist.github.com/sf-mrichter/e0a3d9207d3a74d1d1a1fdeb1c0039eb> if that helps.

The last time I tried this, I noticed that httpd was not running, but even after 'sudo sytemctl restart httpd' and verifying that it is running, the couchdb user add fails (same error).

I just tried a fresh installation on a minimal CentOS 7.4 VM and only installed CouchDB from the couchdb repo, enabled and started couchdb, created the three main databases (_users, _replicator and _global_changes) and it still fails to add a new user, even with no admin password or any other changes to the default installation local.ini file.

I'm not a couchdb expert, so any pointers would be most appreciated.

Thanks!

The information contained in this message is confidential and is intended for the addressee(s) only. If you have received this message in error, please notify the sender immediately and delete the message. Unless you are an addressee (or authorized to receive for an addressee), you may not use, copy or disclose to anyone this message or any information contained in this message. The unauthorized use, disclosure, copying or alteration of this message is strictly prohibited.
The information contained in this message is confidential and is intended for the addressee(s) only. If you have received this message in error, please notify the sender immediately and delete the message. Unless you are an addressee (or authorized to receive for an addressee), you may not use, copy or disclose to anyone this message or any information contained in this message. The unauthorized use, disclosure, copying or alteration of this message is strictly prohibited.

Re: Error 500 when trying to create a new user

Posted by Joan Touzet <wo...@apache.org>.
This may be an instance of #1293:

https://github.com/apache/couchdb/issues/1293

Can you try down-levelling to js-1.8.5-19 and see if that fixes your problem?

We will have a fix for this with the next binary release of CouchDB, which is Real Soon Now.

-Joan

----- Original Message -----
From: "Mark Richter" <mr...@solarflare.com>
To: user@couchdb.apache.org
Sent: Wednesday, May 16, 2018 5:28:49 PM
Subject: Error 500 when trying to create a new user

We have been using couchdb 2.1.1 as our back end database for several months now. We set up new RedHat or CentOS 7.4+ system installations using a bash script I wrote. We require a secure password for the admin user, and compaction is enabled in our local.ini.

Sometime in the last few weeks, installations using the same script now fails to function on new CentOS VMs as we cannot add a new user to the _users database. The operation generates an error 500 and no other explanation. Even the example in the CouchDB online manual (section 1.6) fails (password x'd out):

[solarflare@localhost ~]$ cat newcdbusr
#!/bin/bash

curl -X PUT http://admin:xxxxxxxx@localhost:5984/_users/org.couchdb.user:jan
-H "Accept: application/json"
-H "Content-Type: application/json"
-d '{"name": "jan", "password": "apple", "roles": [], "type": "user"}'

[solarflare@localhost ~]$ ./newcdbusr
{"error":"unknown_error","reason":"undefined"}
[solarflare@localhost ~]$

I went back and used an older CentOS minimal build (1618 I think, vs 1708 and 1804) that had been working for a long time, but that one also fails now. the installation script installs a series of packages that our software requires, along with erlang and couchdb (from the RH yum repos).

I have a gist of a diff between our local.ini and the distribution version at https://gist.github.com/sf-mrichter/e0a3d9207d3a74d1d1a1fdeb1c0039eb 2<https://gist.github.com/sf-mrichter/e0a3d9207d3a74d1d1a1fdeb1c0039eb> if that helps.

The last time I tried this, I noticed that httpd was not running, but even after 'sudo sytemctl restart httpd' and verifying that it is running, the couchdb user add fails (same error).

I just tried a fresh installation on a minimal CentOS 7.4 VM and only installed CouchDB from the couchdb repo, enabled and started couchdb, created the three main databases (_users, _replicator and _global_changes) and it still fails to add a new user, even with no admin password or any other changes to the default installation local.ini file.

I'm not a couchdb expert, so any pointers would be most appreciated.

Thanks!

The information contained in this message is confidential and is intended for the addressee(s) only. If you have received this message in error, please notify the sender immediately and delete the message. Unless you are an addressee (or authorized to receive for an addressee), you may not use, copy or disclose to anyone this message or any information contained in this message. The unauthorized use, disclosure, copying or alteration of this message is strictly prohibited.