How do I install couchdb3 correctly in FreeBSD 14?

Hello,

I assume that I have come across a problem and I don't know what to do now.

As you know, I follow the instruction here. https://docs.couchdb.org/en/stable/install/freebsd.html

pkg install couchdb3

then

modify the local.ini file to add an admin user.

I start the couchdb3 service, however, I only see port 4369 is listening.

Generally speaking, we should see port 5984 is also listening.

# sockstat -4 |grep couchdb
couchdb epmd 884 3 tcp4 *:4369 *:*

Besides, I have install couchdb3 on AlmaLinux 8 and it runs well with the same method.

The current os is newly installed.

# freebsd-version
14.2-STABLE

Does the package here in FreeBSD has something wrong?
Or which step I did is wrong or missing?
I need some suggestions.
 
The current os is newly installed.

# freebsd-version
14.2-STABLE
Why did you go for -STABLE? Lack of understanding how the various versions relate to each other? I suggest installing a -RELEASE version.

Or which step I did is wrong or missing?
You should probably read the pkg-message that came with it, it has some additional instructions, you probably missed those. You can view the message again with pkg info -D couchdb3.
 
Why did you go for -STABLE? Lack of understanding how the various versions relate to each other? I suggest installing a -RELEASE version.


You should probably read the pkg-message that came with it, it has some additional instructions, you probably missed those. You can view the message again with pkg info -D couchdb3.

I am new to FreeBSD and didn't realize the difference between them at first sight. Now I get to know that the -RELEASE version is more stable than the -STABLE version as to FreeBSD and will consider it in the next time.

Code:
# pkg info -D couchdb3
couchdb3-3.4.2:
On install:
If this is the first time you are installing couchdb3, you will need
to add a default administrator, and initialise the database node.

If you are upgrading an existing couchdb3 installation < 2.0, you will
need to replicate your databases across with HTTP, and manually apply
any security objects and local.ini settings.

If you are upgrading from 2.0 and newer,  you can simply re-use the
existing database and views directory, amending your local.ini file
accordingly:

[couchdb]
uuid = ....
database_dir = /var/db/couchdb/data
view_index_dir = /var/db/couchdb/views

In both cases, make sure your javascript functions are compliant with
modern JS, as the SpiderMonkey 60 engine is more strict than its
predecessors used in older CouchDB versions.

For a single node setup, append an inital administrator username and
password to the [admins] section of your local.ini, and a [log] section:

[admins]
admin = passwd
[log]
# http://docs.couchdb.org/en/latest/config/logging.html
level = err
include_sasl = true
writer = syslog
syslog_host = localhost

Amend /usr/local/etc/couchdb3/vm.args as required, at least altering the cookie.

Then, start Apache CouchDB, and run the following commands once the
database is started for the first time, amending admin:passwd to match
your choice above to initialise the default databases:

sudo service couchdb3 start

curl -X PUT http://admin:passwd@127.0.0.1:5984/_users
curl -X PUT http://admin:passwd@127.0.0.1:5984/_replicator
curl -X PUT http://admin:passwd@127.0.0.1:5984/_global_changes

Then use the admin interface at http://127.0.0.1:5984/_utils/# as usual.

For more information see
http://docs.couchdb.org/en/latest/setup/index.html

I should not miss something in the message which you can see. I have added an initial admin user and alter the cookie in vm.args, in which I have make it default in AlmaLinux 8 and make no changes. Start the couchdb3 service but I don't see the port 5984 is listening. As a consequence, the following steps show timeout results and are impossible to set up.
 
Back
Top