diff options
author | Jason Dillaman <dillaman@redhat.com> | 2016-03-18 19:54:35 +0100 |
---|---|---|
committer | Jason Dillaman <dillaman@redhat.com> | 2016-03-18 22:51:23 +0100 |
commit | 8a0e47281f4312beb9ddf5e68a0569951ff236e0 (patch) | |
tree | abb048d371d3e5844f228b475d2fac932a54fc4c /systemd | |
parent | os/filestore: fix warning (diff) | |
download | ceph-8a0e47281f4312beb9ddf5e68a0569951ff236e0.tar.xz ceph-8a0e47281f4312beb9ddf5e68a0569951ff236e0.zip |
systemd: new ceph-rbd-mirror scripts
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
Diffstat (limited to 'systemd')
-rw-r--r-- | systemd/Makefile.am | 2 | ||||
-rw-r--r-- | systemd/ceph-rbd-mirror.target | 5 | ||||
-rw-r--r-- | systemd/ceph-rbd-mirror@.service | 22 |
3 files changed, 29 insertions, 0 deletions
diff --git a/systemd/Makefile.am b/systemd/Makefile.am index 6d93c3cdea9..a6aecc9a26a 100644 --- a/systemd/Makefile.am +++ b/systemd/Makefile.am @@ -4,11 +4,13 @@ unitfiles = \ ceph-mon.target \ ceph-mds.target \ ceph-radosgw.target \ + ceph-rbd-mirror.target \ ceph-mds@.service \ ceph-mon@.service \ ceph-create-keys@.service \ ceph-osd@.service \ ceph-radosgw@.service \ + ceph-rbd-mirror@.service \ ceph-disk@.service \ rbdmap.service diff --git a/systemd/ceph-rbd-mirror.target b/systemd/ceph-rbd-mirror.target new file mode 100644 index 00000000000..7bd94e06e88 --- /dev/null +++ b/systemd/ceph-rbd-mirror.target @@ -0,0 +1,5 @@ +[Unit] +Description=ceph target allowing to start/stop all ceph-rbd-mirror@.service instances at once +PartOf=ceph.target +[Install] +WantedBy=multi-user.target ceph.target diff --git a/systemd/ceph-rbd-mirror@.service b/systemd/ceph-rbd-mirror@.service new file mode 100644 index 00000000000..4c2e2f060be --- /dev/null +++ b/systemd/ceph-rbd-mirror@.service @@ -0,0 +1,22 @@ +[Unit] +Description=Ceph rbd mirror daemon +After=network-online.target local-fs.target +Wants=network-online.target local-fs.target + +[Service] +LimitNOFILE=1048576 +LimitNPROC=1048576 +EnvironmentFile=-/etc/sysconfig/ceph +Environment=CLUSTER=ceph +ExecStart=/usr/bin/rbd-mirror -f --cluster ${CLUSTER} --id %i --setuser ceph --setgroup ceph +ExecReload=/bin/kill -HUP $MAINPID +PrivateDevices=yes +ProtectHome=true +ProtectSystem=full +PrivateTmp=true +Restart=on-failure +StartLimitInterval=30min +StartLimitBurst=3 + +[Install] +WantedBy=ceph-rbd-mirror.target |