Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 673554 - sys-cluster/ceph - three issues with ceph.initrd-r10
Summary: sys-cluster/ceph - three issues with ceph.initrd-r10
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All All
: Normal normal
Assignee: Patrick McLean
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-12-22 05:49 UTC by Michael Uleysky
Modified: 2019-02-01 02:38 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
patch that should fix named issues (ceph.initd-r10-fixes.patch,955 bytes, patch)
2019-01-04 01:16 UTC, Patrick McLean
Details | Diff
bashisms-shellcheck-misc.patch (ceph.initd-r10-fixes.patch,3.11 KB, patch)
2019-01-05 00:56 UTC, Patrick McLean
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Uleysky 2018-12-22 05:49:51 UTC
1) Variable logdir declared in line 52, but not used. Instead, variable log_dir is used in lines 94 and 95.
2) If log_file=/dev/null, then after checkpath in line 95 the directory /dev will belong to the user ceph
3) Setting variables stout, stderr in the /etc/conf.d/ceph doesn't work

Reproducible: Always
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2018-12-22 12:35:29 UTC
4) Uses bashisms:

    for arg_name in std{out,err} respawn_{delay,max,period}; do
Comment 2 Patrick McLean gentoo-dev 2019-01-04 01:16:05 UTC
Created attachment 559760 [details, diff]
patch that should fix named issues

Does this patch fix all the issues you mentioned?
Comment 3 Michael Uleysky 2019-01-04 02:26:50 UTC
Except issue 3. Variables defined in the /etc/conf.d/ceph are ignored. I just checked, rename the configuration file /etc/ceph/ceph.conf
Comment 4 Patrick McLean gentoo-dev 2019-01-04 18:28:18 UTC
What is the exact path to the init script that you are using?
Comment 5 Michael Uleysky 2019-01-05 00:17:40 UTC
/etc/init.d/ceph-mon.{1,2,3}, /etc/init.d/ceph-mds.{1,2,3}, /etc/init.d/ceph-osd.{1..25}. mon and mds on 3 servers, osd on cluster. All scripts are symlinks on /etc/init.d/ceph. Config is /etc/conf.d/ceph
Comment 6 Patrick McLean gentoo-dev 2019-01-05 00:56:26 UTC
Created attachment 559888 [details, diff]
bashisms-shellcheck-misc.patch

This patch should get rid of all bashisms (according to shellcheck) and makes sure it loads /etc/conf.d/ceph properly
Comment 7 Michael Uleysky 2019-01-05 01:07:31 UTC
Partially work.
I restart ceph service after changing /etc/conf.d/ceph and got an error "sourcex: command not found". I restart the service a second time - all ok. I am changing the config again, service restarting with same error. Second time (config not changed) - all ok. Thus, after changing the configuration file, you need to restart the service twice.
Comment 8 Patrick McLean gentoo-dev 2019-01-05 02:35:10 UTC
Try replacing the sourcex line with this

_CONFD_FILE="${RC_SERVICE%/*}/../conf.d/${RC_SVCNAME%-*}"
if [ -r "${_CONFD_FILE}" ]; then
    . "${_CONFD_FILE}" || exit 1
fi
Comment 9 Michael Uleysky 2019-01-05 02:43:13 UTC
It works, thanks
Comment 10 Larry the Git Cow gentoo-dev 2019-01-08 00:13:28 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=030c87d27bca481566a44e7f8a891da41a46fcc6

commit 030c87d27bca481566a44e7f8a891da41a46fcc6
Author:     Patrick McLean <patrick.mclean@sony.com>
AuthorDate: 2019-01-08 00:12:48 +0000
Commit:     Patrick McLean <chutzpah@gentoo.org>
CommitDate: 2019-01-08 00:13:17 +0000

    sys-cluster/ceph: Version bump to 13.2.4
    
    Also update init script to resolve bug #673554
    
    Bug: https://bugs.gentoo.org/673554
    Copyright: Sony Interactive Entertainment Inc.
    Package-Manager: Portage-2.3.54, Repoman-2.3.12
    Signed-off-by: Patrick McLean <chutzpah@gentoo.org>

 sys-cluster/ceph/Manifest             |   1 +
 sys-cluster/ceph/ceph-13.2.4.ebuild   | 335 ++++++++++++++++++++++++++++++++++
 sys-cluster/ceph/files/ceph.initd-r11 | 115 ++++++++++++
 3 files changed, 451 insertions(+)
Comment 11 James R Larrowe 2019-01-28 00:00:01 UTC
Should this be marked as fixed? It looks like it was resolved.
Comment 12 Michael Uleysky 2019-01-28 01:35:06 UTC
I think, yes. All works now, at least for me.
Comment 13 Larry the Git Cow gentoo-dev 2019-02-01 02:38:50 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0afc615336e2d750f096f687b56bf47a887136a8

commit 0afc615336e2d750f096f687b56bf47a887136a8
Author:     Patrick McLean <patrick.mclean@sony.com>
AuthorDate: 2019-02-01 02:38:20 +0000
Commit:     Patrick McLean <chutzpah@gentoo.org>
CommitDate: 2019-02-01 02:38:41 +0000

    sys-cluster/ceph: Version bump to 12.2.11
    
    Also pick up new init script (bug #673554)
    
    Closes: https://bugs.gentoo.org/673554
    Copyright: Sony Interactive Entertainment Inc.
    Package-Manager: Portage-2.3.59, Repoman-2.3.12
    Signed-off-by: Patrick McLean <chutzpah@gentoo.org>

 sys-cluster/ceph/Manifest            |   1 +
 sys-cluster/ceph/ceph-12.2.11.ebuild | 310 +++++++++++++++++++++++++++++++++++
 2 files changed, 311 insertions(+)