Couchbase-server.serviceを起動できません:デバイスCouchbase-server.serviceの読み込みに失敗しました。

Couchbase-server.serviceを起動できません:デバイスCouchbase-server.serviceの読み込みに失敗しました。

Couchbase Serverをインストールするためにこのコマンドを実行するとき

sudo rpm --install couchbase-server-community-4.0.0.centos7.x86_64.rpm

私のFedora 22では、次のエラーが発生します。

Couchbase-serverの起動(systemctl経由):Couchbase-server.serviceを起動できません。デバイスCouchbase-server.serviceの読み込みに失敗しました。そのファイルまたはディレクトリはありません。 [失敗]

Couchbaseサーバーを正常にインストールしました。

このエラーをどのように解決できますか?

ベストアンサー1

CentOS 7を使用して、次の内容で/lib/systemd/system/couchbase-server.serviceを作成して問題を解決しました。

# -*- mode: conf-unix; -*-
[Unit]
Description = Couchbase Server
Documentation = http://docs.couchbase.com
After = network.target remote-fs.target nss-lookup.target

[Service]
SyslogIdentifier = couchbase
User = couchbase
Type = forking
PIDFile=/opt/couchbase/var/lib/couchbase/couchbase-server.pid
WorkingDirectory = /opt/couchbase/var/lib/couchbase
LimitNOFILE = 40960
LimitCORE = unlimited
LimitMEMLOCK = unlimited
ExecStart = /opt/couchbase/bin/couchbase-server -noinput -detached > /opt/couchbase/var/lib/couchbase/logs/start.log 2>&1
ExecStop = /opt/couchbase/bin/couchbase-server -k

[Install]
WantedBy = multi-user.target

できるようにする:

systemctl daemon-reload && systemctl enable couchbase-server && systemctl restart couchbase-server

おすすめ記事