forked from ceph/ceph
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request ceph#42913 from yaarith/update-sudoers-smartctl
rpm, debian: move smartmontools and nvme-cli to ceph-base Reviewed-by: Ken Dreyer <[email protected]> Reviewed-by: Deepika Upadhyay <[email protected]>
- Loading branch information
Showing
6 changed files
with
13 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -456,6 +456,12 @@ Requires: gperftools-libs >= 2.6.1 | |
%endif | ||
%if 0%{?weak_deps} | ||
Recommends: chrony | ||
Recommends: nvme-cli | ||
%if 0%{?suse_version} | ||
Requires: smartmontools | ||
%else | ||
Recommends: smartmontools | ||
%endif | ||
%endif | ||
%description base | ||
Base is the package that includes all the files shared amongst ceph servers | ||
|
@@ -524,14 +530,6 @@ Group: System/Filesystems | |
%endif | ||
Provides: ceph-test:/usr/bin/ceph-monstore-tool | ||
Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} | ||
%if 0%{?weak_deps} | ||
Recommends: nvme-cli | ||
%if 0%{?suse_version} | ||
Requires: smartmontools | ||
%else | ||
Recommends: smartmontools | ||
%endif | ||
%endif | ||
%if 0%{with jaeger} | ||
Requires: libjaeger = %{_epoch_prefix}%{version}-%{release} | ||
%endif | ||
|
@@ -804,15 +802,6 @@ Requires: sudo | |
Requires: libstoragemgmt | ||
Requires: python%{python3_pkgversion}-ceph-common = %{_epoch_prefix}%{version}-%{release} | ||
Requires: python%{python3_pkgversion}-setuptools | ||
|
||
%if 0%{?weak_deps} | ||
Recommends: nvme-cli | ||
%if 0%{?suse_version} | ||
Requires: smartmontools | ||
%else | ||
Recommends: smartmontools | ||
%endif | ||
%endif | ||
%description osd | ||
ceph-osd is the object storage daemon for the Ceph distributed file | ||
system. It is responsible for storing objects on a local file system | ||
|
@@ -1419,7 +1408,7 @@ ln -sf %{_sbindir}/mount.ceph %{buildroot}/sbin/mount.ceph | |
install -m 0644 -D udev/50-rbd.rules %{buildroot}%{_udevrulesdir}/50-rbd.rules | ||
|
||
# sudoers.d | ||
install -m 0440 -D sudoers.d/ceph-osd-smartctl %{buildroot}%{_sysconfdir}/sudoers.d/ceph-osd-smartctl | ||
install -m 0440 -D sudoers.d/ceph-smartctl %{buildroot}%{_sysconfdir}/sudoers.d/ceph-smartctl | ||
|
||
%if 0%{?rhel} >= 8 | ||
pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{_bindir}/* | ||
|
@@ -1516,6 +1505,7 @@ rm -rf %{buildroot} | |
%attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-mgr | ||
%attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rbd | ||
%attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rbd-mirror | ||
%{_sysconfdir}/sudoers.d/ceph-smartctl | ||
|
||
%post base | ||
/sbin/ldconfig | ||
|
@@ -2102,7 +2092,6 @@ fi | |
%{_unitdir}/[email protected] | ||
%attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/osd | ||
%config(noreplace) %{_sysctldir}/90-ceph-osd.conf | ||
%{_sysconfdir}/sudoers.d/ceph-osd-smartctl | ||
|
||
%post osd | ||
%if 0%{?suse_version} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
## allow ceph-osd (which runs as user ceph) to collect device health metrics | ||
## allow ceph daemons (which run as user ceph) to collect device health metrics | ||
|
||
ceph ALL=NOPASSWD: /usr/sbin/smartctl -x --json=o /dev/* | ||
ceph ALL=NOPASSWD: /usr/sbin/nvme * smart-log-add --json /dev/* |