couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bogdan Andu <>
Subject CouchDB 2.0 start/stop dilemma
Date Wed, 12 Oct 2016 10:14:10 GMT

I see Couch 2.0 comes with a free style start / stop mechanism
and the user is encouraged to use runit or whatever mechanism
he already has on his system.

I do not want to use runit when I have modern systems like centos 7 or f
edora 24 server editions that have systemd to start/stop couchdb 2.0 using
a command like this:
$ sudo systemctl status couchdb20

Couch 2.0 does not make use of a pid file anymore .
A pid file is usefull even for systemd-managed services

Anyway I wrote a simple couchdb20.service unit file in systemd for this

the status shows:
$ sudo systemctl status couchdb20
● couchdb20.service - Apache CouchDB Server 2.0
   Loaded: loaded (/usr/lib/systemd/system/couchdb20.service; disabled;
vendor preset: disabled)
   Active: active (running) since Wed 2016-10-12 12:24:20 EEST; 37min ago
  Process: 7950 ExecStart=/home/andu/couchdb2.0/bin/couchdb (code=exited,
 Main PID: 7956 (beam.smp)
    Tasks: 28 (limit: 512)
   CGroup: /system.slice/couchdb20.service
           ├─7956 /home/andu/couchdb2.0/bin/../erts-7.3.1/bin/beam.smp -K
true -A 16 -Bd -- -root /home/andu/couchdb2.0/bin/.. -progname couchdb --
-home /var/couchdb -- -boot /home/andu/couchdb2.0/bin/../releas
           ├─7982 sh -s disksup
           ├─7986 inet_gethost 4
           └─7987 inet_gethost 4

Oct 12 12:24:20 nosql systemd[1]: Starting Apache CouchDB Server 2.0...
Oct 12 12:24:20 nosql systemd[1]: Started Apache CouchDB Server 2.0.

The script appears to work correctly.
All processes a cleanly-shutdown when stopped.

Do you think this is a sane approach to manage couch 2.0 ?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message