[Pkg-ceph-commits] [ceph] 09/85: d/p/fix-systemd-escaping.patch: Ensure that leading '/' is stripped from block device paths when escaping for use in systemd unit names.

Gaudenz Steinlin gaudenz at moszumanska.debian.org
Mon Dec 26 20:47:22 UTC 2016


This is an automated email from the git hooks/post-receive script.

gaudenz pushed a commit to branch jewel
in repository ceph.

commit 14cd1208da7f68a87242a9bfe335b742c6d5feee
Author: James Page <james.page at ubuntu.com>
Date:   Tue Feb 9 11:04:03 2016 +0000

    d/p/fix-systemd-escaping.patch: Ensure that leading '/' is stripped from block device paths when escaping for use in systemd unit names.
    
    (cherry picked from commit 7def0e9c8b92914785337bb77bc4b20617ebc66d)
---
 debian/patches/fix-systemd-escaping.patch | 16 ++++++++++++++++
 debian/patches/series                     |  1 +
 2 files changed, 17 insertions(+)

diff --git a/debian/patches/fix-systemd-escaping.patch b/debian/patches/fix-systemd-escaping.patch
new file mode 100644
index 0000000..29d2764
--- /dev/null
+++ b/debian/patches/fix-systemd-escaping.patch
@@ -0,0 +1,16 @@
+Description: Ensure that leading / is stripped from device paths
+Author: James Page <james.page at ubuntu.com>
+Bug: http://tracker.ceph.com/issues/14706
+Forwarded: no
+
+--- a/src/ceph-disk
++++ b/src/ceph-disk
+@@ -2998,7 +2998,7 @@ def main_trigger(args):
+     LOG.debug("main_trigger: " + str(args))
+     if is_systemd() and not args.sync:
+         # http://www.freedesktop.org/software/systemd/man/systemd-escape.html
+-        escaped_dev = args.dev.replace('-', '\\x2d')
++        escaped_dev = args.dev[1:].replace('-', '\\x2d')
+         service='ceph-disk@{dev}.service'.format(dev=escaped_dev)
+         LOG.info('systemd detected, triggering %s' % service)
+         command(
diff --git a/debian/patches/series b/debian/patches/series
index c230ae0..eb26730 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -17,3 +17,4 @@ ceph-osd-prestart-path.patch
 fix-argparse-defaults.patch
 fix-cycles-arch.patch
 pybind-flags.patch
+fix-systemd-escaping.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ceph/ceph.git



More information about the Pkg-ceph-commits mailing list