]> git.proxmox.com Git - ceph.git/blob - ceph/ceph.spec.in
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / ceph.spec.in
1 #
2 # spec file for package ceph
3 #
4 # Copyright (C) 2004-2019 The Ceph Project Developers. See COPYING file
5 # at the top-level directory of this distribution and at
6 # https://github.com/ceph/ceph/blob/master/COPYING
7 #
8 # All modifications and additions to the file contributed by third parties
9 # remain the property of their copyright owners, unless otherwise agreed
10 # upon.
11 #
12 # This file is under the GNU Lesser General Public License, version 2.1
13 #
14 # Please submit bugfixes or comments via http://tracker.ceph.com/
15 #
16
17 #################################################################################
18 # conditional build section
19 #
20 # please read http://rpm.org/user_doc/conditional_builds.html for explanation of
21 # bcond syntax!
22 #################################################################################
23 %bcond_with make_check
24 %bcond_with zbd
25 %bcond_with cmake_verbose_logging
26 %bcond_without ceph_test_package
27 %ifarch s390
28 %bcond_with tcmalloc
29 %else
30 %bcond_without tcmalloc
31 %endif
32 %if 0%{?fedora} || 0%{?rhel}
33 %bcond_without selinux
34 %ifarch x86_64 ppc64le
35 %bcond_without rbd_rwl_cache
36 %bcond_without rbd_ssd_cache
37 %global _system_pmdk 1
38 %else
39 %bcond_with rbd_rwl_cache
40 %bcond_with rbd_ssd_cache
41 %endif
42 %if 0%{?rhel} >= 8
43 %bcond_with cephfs_java
44 %else
45 %bcond_without cephfs_java
46 %endif
47 %bcond_without amqp_endpoint
48 %bcond_without kafka_endpoint
49 %bcond_without lttng
50 %bcond_without libradosstriper
51 %bcond_without ocf
52 %global _remote_tarball_prefix https://download.ceph.com/tarballs/
53 %endif
54 %if 0%{?suse_version}
55 %bcond_with amqp_endpoint
56 %bcond_with cephfs_java
57 %bcond_with kafka_endpoint
58 %bcond_with libradosstriper
59 %ifarch x86_64 aarch64 ppc64le
60 %bcond_without lttng
61 %global _system_pmdk 1
62 %bcond_without rbd_rwl_cache
63 %bcond_without rbd_ssd_cache
64 %else
65 %bcond_with lttng
66 %global _system_pmdk 0
67 %bcond_with rbd_rwl_cache
68 %bcond_with rbd_ssd_cache
69 %endif
70 %bcond_with ocf
71 %bcond_with selinux
72 #Compat macro for _fillupdir macro introduced in Nov 2017
73 %if ! %{defined _fillupdir}
74 %global _fillupdir /var/adm/fillup-templates
75 %endif
76 %endif
77 %bcond_with seastar
78 %bcond_with jaeger
79 %if 0%{?fedora} || 0%{?suse_version} >= 1500
80 # distros that ship cmd2 and/or colorama
81 %bcond_without cephfs_shell
82 %else
83 # distros that do _not_ ship cmd2/colorama
84 %bcond_with cephfs_shell
85 %endif
86 %if 0%{?fedora} || 0%{?suse_version} || 0%{?rhel} >= 8
87 %global weak_deps 1
88 %endif
89 %if %{with selinux}
90 # get selinux policy version
91 # Force 0.0.0 policy version for centos builds to avoid repository sync issues between rhel and centos
92 %if 0%{?centos}
93 %global _selinux_policy_version 0.0.0
94 %else
95 %{!?_selinux_policy_version: %global _selinux_policy_version 0.0.0}
96 %endif
97 %endif
98
99 %if 0%{?suse_version}
100 %if !0%{?is_opensuse}
101 # SLE does not support luarocks
102 %bcond_with lua_packages
103 %else
104 %global luarocks_package_name lua53-luarocks
105 %bcond_without lua_packages
106 %endif
107 %else
108 %global luarocks_package_name luarocks
109 %bcond_without lua_packages
110 %endif
111
112 %{!?_udevrulesdir: %global _udevrulesdir /lib/udev/rules.d}
113 %{!?tmpfiles_create: %global tmpfiles_create systemd-tmpfiles --create}
114 %{!?python3_pkgversion: %global python3_pkgversion 3}
115 %{!?python3_version_nodots: %global python3_version_nodots 3}
116 %{!?python3_version: %global python3_version 3}
117
118 # disable dwz which compresses the debuginfo
119 %global _find_debuginfo_dwz_opts %{nil}
120
121 #################################################################################
122 # main package definition
123 #################################################################################
124 Name: ceph
125 Version: @PROJECT_VERSION@
126 Release: @RPM_RELEASE@%{?dist}
127 %if 0%{?fedora} || 0%{?rhel}
128 Epoch: 2
129 %endif
130
131 # define _epoch_prefix macro which will expand to the empty string if epoch is
132 # undefined
133 %global _epoch_prefix %{?epoch:%{epoch}:}
134
135 Summary: User space components of the Ceph file system
136 License: LGPL-2.1 and LGPL-3.0 and CC-BY-SA-3.0 and GPL-2.0 and BSL-1.0 and BSD-3-Clause and MIT
137 %if 0%{?suse_version}
138 Group: System/Filesystems
139 %endif
140 URL: http://ceph.com/
141 Source0: %{?_remote_tarball_prefix}@TARBALL_BASENAME@.tar.bz2
142 %if 0%{?suse_version}
143 # _insert_obs_source_lines_here
144 ExclusiveArch: x86_64 aarch64 ppc64le s390x
145 %endif
146 #################################################################################
147 # dependencies that apply across all distro families
148 #################################################################################
149 Requires: ceph-osd = %{_epoch_prefix}%{version}-%{release}
150 Requires: ceph-mds = %{_epoch_prefix}%{version}-%{release}
151 Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
152 Requires: ceph-mon = %{_epoch_prefix}%{version}-%{release}
153 Requires(post): binutils
154 %if 0%{with cephfs_java}
155 BuildRequires: java-devel
156 BuildRequires: sharutils
157 %endif
158 %if 0%{with selinux}
159 BuildRequires: checkpolicy
160 BuildRequires: selinux-policy-devel
161 %endif
162 BuildRequires: gperf
163 BuildRequires: cmake > 3.5
164 BuildRequires: cryptsetup
165 BuildRequires: fuse-devel
166 %if 0%{with seastar}
167 BuildRequires: gcc-toolset-9-gcc-c++ >= 9.2.1-2.3
168 %else
169 BuildRequires: gcc-c++
170 %endif
171 BuildRequires: gdbm
172 %if 0%{with tcmalloc}
173 # libprofiler did not build on ppc64le until 2.7.90
174 %if 0%{?fedora} || 0%{?rhel} >= 8
175 BuildRequires: gperftools-devel >= 2.7.90
176 %endif
177 %if 0%{?rhel} && 0%{?rhel} < 8
178 BuildRequires: gperftools-devel >= 2.6.1
179 %endif
180 %if 0%{?suse_version}
181 BuildRequires: gperftools-devel >= 2.4
182 %endif
183 %endif
184 BuildRequires: leveldb-devel > 1.2
185 BuildRequires: libaio-devel
186 BuildRequires: libblkid-devel >= 2.17
187 BuildRequires: cryptsetup-devel
188 BuildRequires: libcurl-devel
189 BuildRequires: libcap-ng-devel
190 BuildRequires: fmt-devel >= 5.2.1
191 BuildRequires: pkgconfig(libudev)
192 BuildRequires: libnl3-devel
193 BuildRequires: liboath-devel
194 BuildRequires: libtool
195 BuildRequires: libxml2-devel
196 BuildRequires: make
197 BuildRequires: ncurses-devel
198 BuildRequires: libicu-devel
199 BuildRequires: parted
200 BuildRequires: patch
201 BuildRequires: perl
202 BuildRequires: pkgconfig
203 BuildRequires: procps
204 BuildRequires: python%{python3_pkgversion}
205 BuildRequires: python%{python3_pkgversion}-devel
206 BuildRequires: snappy-devel
207 BuildRequires: sqlite-devel
208 BuildRequires: sudo
209 BuildRequires: pkgconfig(udev)
210 BuildRequires: util-linux
211 BuildRequires: valgrind-devel
212 BuildRequires: which
213 BuildRequires: xfsprogs
214 BuildRequires: xfsprogs-devel
215 BuildRequires: xmlstarlet
216 BuildRequires: nasm
217 BuildRequires: lua-devel
218 %if 0%{with amqp_endpoint}
219 BuildRequires: librabbitmq-devel
220 %endif
221 %if 0%{with kafka_endpoint}
222 BuildRequires: librdkafka-devel
223 %endif
224 %if 0%{with lua_packages}
225 BuildRequires: %{luarocks_package_name}
226 %endif
227 %if 0%{with make_check}
228 BuildRequires: jq
229 BuildRequires: libuuid-devel
230 BuildRequires: python%{python3_pkgversion}-bcrypt
231 BuildRequires: python%{python3_pkgversion}-nose
232 BuildRequires: python%{python3_pkgversion}-pecan
233 BuildRequires: python%{python3_pkgversion}-requests
234 BuildRequires: python%{python3_pkgversion}-dateutil
235 BuildRequires: python%{python3_pkgversion}-virtualenv
236 BuildRequires: python%{python3_pkgversion}-coverage
237 BuildRequires: python%{python3_pkgversion}-pyOpenSSL
238 BuildRequires: socat
239 %endif
240 %if 0%{with zbd}
241 BuildRequires: libzbd-devel
242 %endif
243 %if 0%{with jaeger}
244 BuildRequires: bison
245 BuildRequires: flex
246 %if 0%{?fedora} || 0%{?rhel}
247 BuildRequires: json-devel
248 %endif
249 %if 0%{?suse_version}
250 BuildRequires: nlohmann_json-devel
251 %endif
252 BuildRequires: libevent-devel
253 BuildRequires: yaml-cpp-devel
254 %endif
255 %if 0%{?_system_pmdk}
256 BuildRequires: libpmem-devel
257 BuildRequires: libpmemobj-devel
258 %endif
259 %if 0%{with seastar}
260 BuildRequires: c-ares-devel
261 BuildRequires: gnutls-devel
262 BuildRequires: hwloc-devel
263 BuildRequires: libpciaccess-devel
264 BuildRequires: lksctp-tools-devel
265 BuildRequires: protobuf-devel
266 BuildRequires: ragel
267 BuildRequires: systemtap-sdt-devel
268 BuildRequires: yaml-cpp-devel
269 %if 0%{?fedora}
270 BuildRequires: libubsan
271 BuildRequires: libasan
272 BuildRequires: libatomic
273 %endif
274 %if 0%{?rhel}
275 BuildRequires: gcc-toolset-9-annobin
276 BuildRequires: gcc-toolset-9-libubsan-devel
277 BuildRequires: gcc-toolset-9-libasan-devel
278 BuildRequires: gcc-toolset-9-libatomic-devel
279 %endif
280 %endif
281 #################################################################################
282 # distro-conditional dependencies
283 #################################################################################
284 %if 0%{?suse_version}
285 BuildRequires: pkgconfig(systemd)
286 BuildRequires: systemd-rpm-macros
287 %{?systemd_requires}
288 PreReq: %fillup_prereq
289 BuildRequires: fdupes
290 BuildRequires: net-tools
291 BuildRequires: libbz2-devel
292 BuildRequires: mozilla-nss-devel
293 BuildRequires: keyutils-devel
294 BuildRequires: libopenssl-devel
295 BuildRequires: lsb-release
296 BuildRequires: openldap2-devel
297 #BuildRequires: krb5
298 #BuildRequires: krb5-devel
299 BuildRequires: cunit-devel
300 BuildRequires: python%{python3_pkgversion}-setuptools
301 BuildRequires: python%{python3_pkgversion}-Cython
302 BuildRequires: python%{python3_pkgversion}-PrettyTable
303 BuildRequires: python%{python3_pkgversion}-Sphinx
304 BuildRequires: rdma-core-devel
305 BuildRequires: liblz4-devel >= 1.7
306 # for prometheus-alerts
307 BuildRequires: golang-github-prometheus-prometheus
308 %endif
309 %if 0%{?fedora} || 0%{?rhel}
310 Requires: systemd
311 BuildRequires: boost-random
312 BuildRequires: nss-devel
313 BuildRequires: keyutils-libs-devel
314 BuildRequires: libibverbs-devel
315 BuildRequires: librdmacm-devel
316 BuildRequires: openldap-devel
317 #BuildRequires: krb5-devel
318 BuildRequires: openssl-devel
319 BuildRequires: CUnit-devel
320 BuildRequires: redhat-lsb-core
321 BuildRequires: python%{python3_pkgversion}-devel
322 BuildRequires: python%{python3_pkgversion}-setuptools
323 BuildRequires: python%{python3_pkgversion}-Cython
324 BuildRequires: python%{python3_pkgversion}-prettytable
325 BuildRequires: python%{python3_pkgversion}-sphinx
326 BuildRequires: lz4-devel >= 1.7
327 %endif
328 # distro-conditional make check dependencies
329 %if 0%{with make_check}
330 %if 0%{?fedora} || 0%{?rhel}
331 BuildRequires: golang-github-prometheus
332 BuildRequires: libtool-ltdl-devel
333 BuildRequires: xmlsec1
334 BuildRequires: xmlsec1-devel
335 %ifarch x86_64
336 BuildRequires: xmlsec1-nss
337 %endif
338 BuildRequires: xmlsec1-openssl
339 BuildRequires: xmlsec1-openssl-devel
340 BuildRequires: python%{python3_pkgversion}-cherrypy
341 BuildRequires: python%{python3_pkgversion}-jwt
342 BuildRequires: python%{python3_pkgversion}-routes
343 BuildRequires: python%{python3_pkgversion}-scipy
344 BuildRequires: python%{python3_pkgversion}-werkzeug
345 BuildRequires: python%{python3_pkgversion}-pyOpenSSL
346 %endif
347 %if 0%{?suse_version}
348 BuildRequires: golang-github-prometheus-prometheus
349 BuildRequires: libxmlsec1-1
350 BuildRequires: libxmlsec1-nss1
351 BuildRequires: libxmlsec1-openssl1
352 BuildRequires: python%{python3_pkgversion}-CherryPy
353 BuildRequires: python%{python3_pkgversion}-PyJWT
354 BuildRequires: python%{python3_pkgversion}-Routes
355 BuildRequires: python%{python3_pkgversion}-Werkzeug
356 BuildRequires: python%{python3_pkgversion}-numpy-devel
357 BuildRequires: xmlsec1-devel
358 BuildRequires: xmlsec1-openssl-devel
359 %endif
360 %endif
361 # lttng and babeltrace for rbd-replay-prep
362 %if %{with lttng}
363 %if 0%{?fedora} || 0%{?rhel}
364 BuildRequires: lttng-ust-devel
365 BuildRequires: libbabeltrace-devel
366 %endif
367 %if 0%{?suse_version}
368 BuildRequires: lttng-ust-devel
369 BuildRequires: babeltrace-devel
370 %endif
371 %endif
372 %if 0%{?suse_version}
373 BuildRequires: libexpat-devel
374 %endif
375 %if 0%{?rhel} || 0%{?fedora}
376 BuildRequires: expat-devel
377 %endif
378 #hardened-cc1
379 %if 0%{?fedora} || 0%{?rhel}
380 BuildRequires: redhat-rpm-config
381 %endif
382 %if 0%{with seastar}
383 %if 0%{?fedora} || 0%{?rhel}
384 BuildRequires: cryptopp-devel
385 BuildRequires: numactl-devel
386 BuildRequires: protobuf-compiler
387 %endif
388 %if 0%{?suse_version}
389 BuildRequires: libcryptopp-devel
390 BuildRequires: libnuma-devel
391 %endif
392 %endif
393 %if 0%{?rhel} >= 8
394 BuildRequires: /usr/bin/pathfix.py
395 %endif
396
397 %description
398 Ceph is a massively scalable, open-source, distributed storage system that runs
399 on commodity hardware and delivers object, block and file system storage.
400
401
402 #################################################################################
403 # subpackages
404 #################################################################################
405 %package base
406 Summary: Ceph Base Package
407 %if 0%{?suse_version}
408 Group: System/Filesystems
409 %endif
410 Provides: ceph-test:/usr/bin/ceph-kvstore-tool
411 Requires: ceph-common = %{_epoch_prefix}%{version}-%{release}
412 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
413 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
414 Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release}
415 Requires: librgw2 = %{_epoch_prefix}%{version}-%{release}
416 %if 0%{with selinux}
417 Requires: ceph-selinux = %{_epoch_prefix}%{version}-%{release}
418 %endif
419 Requires: cryptsetup
420 Requires: e2fsprogs
421 Requires: findutils
422 Requires: grep
423 Requires: logrotate
424 Requires: parted
425 Requires: psmisc
426 Requires: python%{python3_pkgversion}-setuptools
427 Requires: util-linux
428 Requires: xfsprogs
429 Requires: which
430 %if 0%{?rhel} && 0%{?rhel} < 8
431 # The following is necessary due to tracker 36508 and can be removed once the
432 # associated upstream bugs are resolved.
433 %if 0%{with tcmalloc}
434 Requires: gperftools-libs >= 2.6.1
435 %endif
436 %endif
437 %if 0%{?weak_deps}
438 Recommends: chrony
439 %endif
440 %description base
441 Base is the package that includes all the files shared amongst ceph servers
442
443 %package -n cephadm
444 Summary: Utility to bootstrap Ceph clusters
445 BuildArch: noarch
446 Requires: lvm2
447 Requires: python%{python3_pkgversion}
448 %if 0%{?weak_deps}
449 Recommends: podman >= 2.0.2
450 %endif
451 %description -n cephadm
452 Utility to bootstrap a Ceph cluster and manage Ceph daemons deployed
453 with systemd and podman.
454
455 %package -n ceph-common
456 Summary: Ceph Common
457 %if 0%{?suse_version}
458 Group: System/Filesystems
459 %endif
460 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
461 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
462 Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release}
463 Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release}
464 Requires: python%{python3_pkgversion}-rbd = %{_epoch_prefix}%{version}-%{release}
465 Requires: python%{python3_pkgversion}-cephfs = %{_epoch_prefix}%{version}-%{release}
466 Requires: python%{python3_pkgversion}-rgw = %{_epoch_prefix}%{version}-%{release}
467 Requires: python%{python3_pkgversion}-ceph-argparse = %{_epoch_prefix}%{version}-%{release}
468 Requires: python%{python3_pkgversion}-ceph-common = %{_epoch_prefix}%{version}-%{release}
469 %if 0%{with jaeger}
470 Requires: libjaeger = %{_epoch_prefix}%{version}-%{release}
471 %endif
472 %if 0%{?fedora} || 0%{?rhel}
473 Requires: python%{python3_pkgversion}-prettytable
474 %endif
475 %if 0%{?suse_version}
476 Requires: python%{python3_pkgversion}-PrettyTable
477 %endif
478 %if 0%{with libradosstriper}
479 Requires: libradosstriper1 = %{_epoch_prefix}%{version}-%{release}
480 %endif
481 %{?systemd_requires}
482 %if 0%{?suse_version}
483 Requires(pre): pwdutils
484 %endif
485 %description -n ceph-common
486 Common utilities to mount and interact with a ceph storage cluster.
487 Comprised of files that are common to Ceph clients and servers.
488
489 %package mds
490 Summary: Ceph Metadata Server Daemon
491 %if 0%{?suse_version}
492 Group: System/Filesystems
493 %endif
494 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
495 %description mds
496 ceph-mds is the metadata server daemon for the Ceph distributed file system.
497 One or more instances of ceph-mds collectively manage the file system
498 namespace, coordinating access to the shared OSD cluster.
499
500 %package mon
501 Summary: Ceph Monitor Daemon
502 %if 0%{?suse_version}
503 Group: System/Filesystems
504 %endif
505 Provides: ceph-test:/usr/bin/ceph-monstore-tool
506 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
507 %if 0%{?weak_deps}
508 Recommends: nvme-cli
509 %if 0%{?suse_version}
510 Requires: smartmontools
511 %else
512 Recommends: smartmontools
513 %endif
514 %endif
515 %if 0%{with jaeger}
516 Requires: libjaeger = %{_epoch_prefix}%{version}-%{release}
517 %endif
518 %description mon
519 ceph-mon is the cluster monitor daemon for the Ceph distributed file
520 system. One or more instances of ceph-mon form a Paxos part-time
521 parliament cluster that provides extremely reliable and durable storage
522 of cluster membership, configuration, and state.
523
524 %package mgr
525 Summary: Ceph Manager Daemon
526 %if 0%{?suse_version}
527 Group: System/Filesystems
528 %endif
529 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
530 Requires: ceph-mgr-modules-core = %{_epoch_prefix}%{version}-%{release}
531 Requires: libcephsqlite = %{_epoch_prefix}%{version}-%{release}
532 %if 0%{?weak_deps}
533 Recommends: ceph-mgr-dashboard = %{_epoch_prefix}%{version}-%{release}
534 Recommends: ceph-mgr-diskprediction-local = %{_epoch_prefix}%{version}-%{release}
535 Recommends: ceph-mgr-k8sevents = %{_epoch_prefix}%{version}-%{release}
536 Recommends: ceph-mgr-cephadm = %{_epoch_prefix}%{version}-%{release}
537 Recommends: python%{python3_pkgversion}-influxdb
538 %endif
539 %description mgr
540 ceph-mgr enables python modules that provide services (such as the REST
541 module derived from Calamari) and expose CLI hooks. ceph-mgr gathers
542 the cluster maps, the daemon metadata, and performance counters, and
543 exposes all these to the python modules.
544
545 %package mgr-dashboard
546 Summary: Ceph Dashboard
547 BuildArch: noarch
548 %if 0%{?suse_version}
549 Group: System/Filesystems
550 %endif
551 Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
552 Requires: ceph-grafana-dashboards = %{_epoch_prefix}%{version}-%{release}
553 Requires: ceph-prometheus-alerts = %{_epoch_prefix}%{version}-%{release}
554 %if 0%{?fedora} || 0%{?rhel}
555 Requires: python%{python3_pkgversion}-cherrypy
556 Requires: python%{python3_pkgversion}-jwt
557 Requires: python%{python3_pkgversion}-routes
558 Requires: python%{python3_pkgversion}-werkzeug
559 %if 0%{?weak_deps}
560 Recommends: python%{python3_pkgversion}-saml
561 %endif
562 %endif
563 %if 0%{?suse_version}
564 Requires: python%{python3_pkgversion}-CherryPy
565 Requires: python%{python3_pkgversion}-PyJWT
566 Requires: python%{python3_pkgversion}-Routes
567 Requires: python%{python3_pkgversion}-Werkzeug
568 Recommends: python%{python3_pkgversion}-python3-saml
569 %endif
570 %description mgr-dashboard
571 ceph-mgr-dashboard is a manager module, providing a web-based application
572 to monitor and manage many aspects of a Ceph cluster and related components.
573 See the Dashboard documentation at http://docs.ceph.com/ for details and a
574 detailed feature overview.
575
576 %package mgr-diskprediction-local
577 Summary: Ceph Manager module for predicting disk failures
578 BuildArch: noarch
579 %if 0%{?suse_version}
580 Group: System/Filesystems
581 %endif
582 Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
583 Requires: python%{python3_pkgversion}-numpy
584 %if 0%{?fedora} || 0%{?suse_version}
585 Requires: python%{python3_pkgversion}-scikit-learn
586 %endif
587 Requires: python3-scipy
588 %description mgr-diskprediction-local
589 ceph-mgr-diskprediction-local is a ceph-mgr module that tries to predict
590 disk failures using local algorithms and machine-learning databases.
591
592 %package mgr-modules-core
593 Summary: Ceph Manager modules which are always enabled
594 BuildArch: noarch
595 %if 0%{?suse_version}
596 Group: System/Filesystems
597 %endif
598 Requires: python%{python3_pkgversion}-bcrypt
599 Requires: python%{python3_pkgversion}-pecan
600 Requires: python%{python3_pkgversion}-pyOpenSSL
601 Requires: python%{python3_pkgversion}-requests
602 Requires: python%{python3_pkgversion}-dateutil
603 %if 0%{?fedora} || 0%{?rhel} >= 8
604 Requires: python%{python3_pkgversion}-cherrypy
605 Requires: python%{python3_pkgversion}-pyyaml
606 Requires: python%{python3_pkgversion}-werkzeug
607 %endif
608 %if 0%{?suse_version}
609 Requires: python%{python3_pkgversion}-CherryPy
610 Requires: python%{python3_pkgversion}-PyYAML
611 Requires: python%{python3_pkgversion}-Werkzeug
612 %endif
613 %if 0%{?weak_deps}
614 Recommends: ceph-mgr-rook = %{_epoch_prefix}%{version}-%{release}
615 %endif
616 %description mgr-modules-core
617 ceph-mgr-modules-core provides a set of modules which are always
618 enabled by ceph-mgr.
619
620 %package mgr-rook
621 BuildArch: noarch
622 Summary: Ceph Manager module for Rook-based orchestration
623 %if 0%{?suse_version}
624 Group: System/Filesystems
625 %endif
626 Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
627 Requires: python%{python3_pkgversion}-kubernetes
628 Requires: python%{python3_pkgversion}-jsonpatch
629 %description mgr-rook
630 ceph-mgr-rook is a ceph-mgr module for orchestration functions using
631 a Rook backend.
632
633 %package mgr-k8sevents
634 BuildArch: noarch
635 Summary: Ceph Manager module to orchestrate ceph-events to kubernetes' events API
636 %if 0%{?suse_version}
637 Group: System/Filesystems
638 %endif
639 Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
640 Requires: python%{python3_pkgversion}-kubernetes
641 %description mgr-k8sevents
642 ceph-mgr-k8sevents is a ceph-mgr module that sends every ceph-events
643 to kubernetes' events API
644
645 %package mgr-cephadm
646 Summary: Ceph Manager module for cephadm-based orchestration
647 BuildArch: noarch
648 %if 0%{?suse_version}
649 Group: System/Filesystems
650 %endif
651 Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release}
652 Requires: python%{python3_pkgversion}-remoto
653 Requires: cephadm = %{_epoch_prefix}%{version}-%{release}
654 %if 0%{?suse_version}
655 Requires: openssh
656 Requires: python%{python3_pkgversion}-Jinja2
657 %endif
658 %if 0%{?rhel} || 0%{?fedora}
659 Requires: openssh-clients
660 Requires: python%{python3_pkgversion}-jinja2
661 %endif
662 %description mgr-cephadm
663 ceph-mgr-cephadm is a ceph-mgr module for orchestration functions using
664 the integrated cephadm deployment tool management operations.
665
666 %package fuse
667 Summary: Ceph fuse-based client
668 %if 0%{?suse_version}
669 Group: System/Filesystems
670 %endif
671 Requires: fuse
672 Requires: python%{python3_pkgversion}
673 %description fuse
674 FUSE based client for Ceph distributed network file system
675
676 %package -n cephfs-mirror
677 Summary: Ceph daemon for mirroring CephFS snapshots
678 %if 0%{?suse_version}
679 Group: System/Filesystems
680 %endif
681 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
682 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
683 Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release}
684 %description -n cephfs-mirror
685 Daemon for mirroring CephFS snapshots between Ceph clusters.
686
687 %package -n rbd-fuse
688 Summary: Ceph fuse-based client
689 %if 0%{?suse_version}
690 Group: System/Filesystems
691 %endif
692 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
693 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
694 %description -n rbd-fuse
695 FUSE based client to map Ceph rbd images to files
696
697 %package -n rbd-mirror
698 Summary: Ceph daemon for mirroring RBD images
699 %if 0%{?suse_version}
700 Group: System/Filesystems
701 %endif
702 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
703 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
704 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
705 %description -n rbd-mirror
706 Daemon for mirroring RBD images between Ceph clusters, streaming
707 changes asynchronously.
708
709 %package immutable-object-cache
710 Summary: Ceph daemon for immutable object cache
711 %if 0%{?suse_version}
712 Group: System/Filesystems
713 %endif
714 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
715 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
716 %description immutable-object-cache
717 Daemon for immutable object cache.
718
719 %package -n rbd-nbd
720 Summary: Ceph RBD client base on NBD
721 %if 0%{?suse_version}
722 Group: System/Filesystems
723 %endif
724 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
725 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
726 %description -n rbd-nbd
727 NBD based client to map Ceph rbd images to local device
728
729 %package radosgw
730 Summary: Rados REST gateway
731 %if 0%{?suse_version}
732 Group: System/Filesystems
733 %endif
734 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
735 %if 0%{with selinux}
736 Requires: ceph-selinux = %{_epoch_prefix}%{version}-%{release}
737 %endif
738 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
739 Requires: librgw2 = %{_epoch_prefix}%{version}-%{release}
740 %if 0%{?rhel} || 0%{?fedora}
741 Requires: mailcap
742 %endif
743 %if 0%{?weak_deps}
744 Recommends: gawk
745 %endif
746 %description radosgw
747 RADOS is a distributed object store used by the Ceph distributed
748 storage system. This package provides a REST gateway to the
749 object store that aims to implement a superset of Amazon's S3
750 service as well as the OpenStack Object Storage ("Swift") API.
751
752 %package -n cephfs-top
753 Summary: top(1) like utility for Ceph Filesystem
754 BuildArch: noarch
755 Requires: python%{python3_pkgversion}-rados
756 %description -n cephfs-top
757 This package provides a top(1) like utility to display Ceph Filesystem metrics
758 in realtime.
759
760 %if %{with ocf}
761 %package resource-agents
762 Summary: OCF-compliant resource agents for Ceph daemons
763 %if 0%{?suse_version}
764 Group: System/Filesystems
765 %endif
766 Requires: ceph-base = %{_epoch_prefix}%{version}
767 Requires: resource-agents
768 %description resource-agents
769 Resource agents for monitoring and managing Ceph daemons
770 under Open Cluster Framework (OCF) compliant resource
771 managers such as Pacemaker.
772 %endif
773
774 %package osd
775 Summary: Ceph Object Storage Daemon
776 %if 0%{?suse_version}
777 Group: System/Filesystems
778 %endif
779 Provides: ceph-test:/usr/bin/ceph-osdomap-tool
780 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
781 Requires: lvm2
782 Requires: sudo
783 Requires: libstoragemgmt
784 Requires: python%{python3_pkgversion}-ceph-common = %{_epoch_prefix}%{version}-%{release}
785 %if 0%{?weak_deps}
786 Recommends: nvme-cli
787 %if 0%{?suse_version}
788 Requires: smartmontools
789 %else
790 Recommends: smartmontools
791 %endif
792 %endif
793 %description osd
794 ceph-osd is the object storage daemon for the Ceph distributed file
795 system. It is responsible for storing objects on a local file system
796 and providing access to them over the network.
797
798 %if 0%{with seastar}
799 %package crimson-osd
800 Summary: Ceph Object Storage Daemon (crimson)
801 %if 0%{?suse_version}
802 Group: System/Filesystems
803 %endif
804 Requires: ceph-osd = %{_epoch_prefix}%{version}-%{release}
805 %description crimson-osd
806 crimson-osd is the object storage daemon for the Ceph distributed file
807 system. It is responsible for storing objects on a local file system
808 and providing access to them over the network.
809 %endif
810
811 %package -n librados2
812 Summary: RADOS distributed object store client library
813 %if 0%{?suse_version}
814 Group: System/Libraries
815 %endif
816 %if 0%{?rhel} || 0%{?fedora}
817 Obsoletes: ceph-libs < %{_epoch_prefix}%{version}-%{release}
818 %endif
819 %description -n librados2
820 RADOS is a reliable, autonomic distributed object storage cluster
821 developed as part of the Ceph distributed storage system. This is a
822 shared library allowing applications to access the distributed object
823 store using a simple file-like interface.
824
825 %package -n librados-devel
826 Summary: RADOS headers
827 %if 0%{?suse_version}
828 Group: Development/Libraries/C and C++
829 %endif
830 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
831 Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release}
832 Provides: librados2-devel = %{_epoch_prefix}%{version}-%{release}
833 Obsoletes: librados2-devel < %{_epoch_prefix}%{version}-%{release}
834 %description -n librados-devel
835 This package contains C libraries and headers needed to develop programs
836 that use RADOS object store.
837
838 %package -n libradospp-devel
839 Summary: RADOS headers
840 %if 0%{?suse_version}
841 Group: Development/Libraries/C and C++
842 %endif
843 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
844 Requires: librados-devel = %{_epoch_prefix}%{version}-%{release}
845 %description -n libradospp-devel
846 This package contains C++ libraries and headers needed to develop programs
847 that use RADOS object store.
848
849 %package -n librgw2
850 Summary: RADOS gateway client library
851 %if 0%{?suse_version}
852 Group: System/Libraries
853 %endif
854 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
855 %description -n librgw2
856 This package provides a library implementation of the RADOS gateway
857 (distributed object store with S3 and Swift personalities).
858
859 %package -n librgw-devel
860 Summary: RADOS gateway client library
861 %if 0%{?suse_version}
862 Group: Development/Libraries/C and C++
863 %endif
864 Requires: librados-devel = %{_epoch_prefix}%{version}-%{release}
865 Requires: librgw2 = %{_epoch_prefix}%{version}-%{release}
866 Provides: librgw2-devel = %{_epoch_prefix}%{version}-%{release}
867 Obsoletes: librgw2-devel < %{_epoch_prefix}%{version}-%{release}
868 %description -n librgw-devel
869 This package contains libraries and headers needed to develop programs
870 that use RADOS gateway client library.
871
872 %package -n python%{python3_pkgversion}-rgw
873 Summary: Python 3 libraries for the RADOS gateway
874 %if 0%{?suse_version}
875 Group: Development/Libraries/Python
876 %endif
877 Requires: librgw2 = %{_epoch_prefix}%{version}-%{release}
878 Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release}
879 %{?python_provide:%python_provide python%{python3_pkgversion}-rgw}
880 Provides: python-rgw = %{_epoch_prefix}%{version}-%{release}
881 Obsoletes: python-rgw < %{_epoch_prefix}%{version}-%{release}
882 %description -n python%{python3_pkgversion}-rgw
883 This package contains Python 3 libraries for interacting with Ceph RADOS
884 gateway.
885
886 %package -n python%{python3_pkgversion}-rados
887 Summary: Python 3 libraries for the RADOS object store
888 %if 0%{?suse_version}
889 Group: Development/Libraries/Python
890 %endif
891 Requires: python%{python3_pkgversion}
892 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
893 %{?python_provide:%python_provide python%{python3_pkgversion}-rados}
894 Provides: python-rados = %{_epoch_prefix}%{version}-%{release}
895 Obsoletes: python-rados < %{_epoch_prefix}%{version}-%{release}
896 %description -n python%{python3_pkgversion}-rados
897 This package contains Python 3 libraries for interacting with Ceph RADOS
898 object store.
899
900 %package -n libcephsqlite
901 Summary: SQLite3 VFS for Ceph
902 %if 0%{?suse_version}
903 Group: System/Libraries
904 %endif
905 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
906 %description -n libcephsqlite
907 A SQLite3 VFS for storing and manipulating databases stored on Ceph's RADOS
908 distributed object store.
909
910 %package -n libcephsqlite-devel
911 Summary: SQLite3 VFS for Ceph headers
912 %if 0%{?suse_version}
913 Group: Development/Libraries/C and C++
914 %endif
915 Requires: sqlite-devel
916 Requires: libcephsqlite = %{_epoch_prefix}%{version}-%{release}
917 Requires: librados-devel = %{_epoch_prefix}%{version}-%{release}
918 Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release}
919 Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release}
920 Provides: libcephsqlite-devel = %{_epoch_prefix}%{version}-%{release}
921 Obsoletes: libcephsqlite-devel < %{_epoch_prefix}%{version}-%{release}
922 %description -n libcephsqlite-devel
923 A SQLite3 VFS for storing and manipulating databases stored on Ceph's RADOS
924 distributed object store.
925
926 %if 0%{with libradosstriper}
927 %package -n libradosstriper1
928 Summary: RADOS striping interface
929 %if 0%{?suse_version}
930 Group: System/Libraries
931 %endif
932 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
933 %description -n libradosstriper1
934 Striping interface built on top of the rados library, allowing
935 to stripe bigger objects onto several standard rados objects using
936 an interface very similar to the rados one.
937
938 %package -n libradosstriper-devel
939 Summary: RADOS striping interface headers
940 %if 0%{?suse_version}
941 Group: Development/Libraries/C and C++
942 %endif
943 Requires: libradosstriper1 = %{_epoch_prefix}%{version}-%{release}
944 Requires: librados-devel = %{_epoch_prefix}%{version}-%{release}
945 Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release}
946 Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release}
947 Provides: libradosstriper1-devel = %{_epoch_prefix}%{version}-%{release}
948 Obsoletes: libradosstriper1-devel < %{_epoch_prefix}%{version}-%{release}
949 %description -n libradosstriper-devel
950 This package contains libraries and headers needed to develop programs
951 that use RADOS striping interface.
952 %endif
953
954 %package -n librbd1
955 Summary: RADOS block device client library
956 %if 0%{?suse_version}
957 Group: System/Libraries
958 %endif
959 Requires: librados2 = %{_epoch_prefix}%{version}-%{release}
960 %if 0%{?suse_version}
961 Requires(post): coreutils
962 %endif
963 %if 0%{?rhel} || 0%{?fedora}
964 Obsoletes: ceph-libs < %{_epoch_prefix}%{version}-%{release}
965 %endif
966 %description -n librbd1
967 RBD is a block device striped across multiple distributed objects in
968 RADOS, a reliable, autonomic distributed object storage cluster
969 developed as part of the Ceph distributed storage system. This is a
970 shared library allowing applications to manage these block devices.
971
972 %package -n librbd-devel
973 Summary: RADOS block device headers
974 %if 0%{?suse_version}
975 Group: Development/Libraries/C and C++
976 %endif
977 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
978 Requires: librados-devel = %{_epoch_prefix}%{version}-%{release}
979 Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release}
980 Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release}
981 Provides: librbd1-devel = %{_epoch_prefix}%{version}-%{release}
982 Obsoletes: librbd1-devel < %{_epoch_prefix}%{version}-%{release}
983 %description -n librbd-devel
984 This package contains libraries and headers needed to develop programs
985 that use RADOS block device.
986
987 %package -n python%{python3_pkgversion}-rbd
988 Summary: Python 3 libraries for the RADOS block device
989 %if 0%{?suse_version}
990 Group: Development/Libraries/Python
991 %endif
992 Requires: librbd1 = %{_epoch_prefix}%{version}-%{release}
993 Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release}
994 %{?python_provide:%python_provide python%{python3_pkgversion}-rbd}
995 Provides: python-rbd = %{_epoch_prefix}%{version}-%{release}
996 Obsoletes: python-rbd < %{_epoch_prefix}%{version}-%{release}
997 %description -n python%{python3_pkgversion}-rbd
998 This package contains Python 3 libraries for interacting with Ceph RADOS
999 block device.
1000
1001 %package -n libcephfs2
1002 Summary: Ceph distributed file system client library
1003 %if 0%{?suse_version}
1004 Group: System/Libraries
1005 %endif
1006 Obsoletes: libcephfs1 < %{_epoch_prefix}%{version}-%{release}
1007 %if 0%{?rhel} || 0%{?fedora}
1008 Obsoletes: ceph-libs < %{_epoch_prefix}%{version}-%{release}
1009 Obsoletes: ceph-libcephfs
1010 %endif
1011 %description -n libcephfs2
1012 Ceph is a distributed network file system designed to provide excellent
1013 performance, reliability, and scalability. This is a shared library
1014 allowing applications to access a Ceph distributed file system via a
1015 POSIX-like interface.
1016
1017 %package -n libcephfs-devel
1018 Summary: Ceph distributed file system headers
1019 %if 0%{?suse_version}
1020 Group: Development/Libraries/C and C++
1021 %endif
1022 Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release}
1023 Requires: librados-devel = %{_epoch_prefix}%{version}-%{release}
1024 Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release}
1025 Provides: libcephfs2-devel = %{_epoch_prefix}%{version}-%{release}
1026 Obsoletes: libcephfs2-devel < %{_epoch_prefix}%{version}-%{release}
1027 %description -n libcephfs-devel
1028 This package contains libraries and headers needed to develop programs
1029 that use Ceph distributed file system.
1030
1031 %if 0%{with jaeger}
1032 %package -n libjaeger
1033 Summary: Ceph distributed file system tracing library
1034 %if 0%{?suse_version}
1035 Group: System/Libraries
1036 %endif
1037 Provides: libjaegertracing.so.0()(64bit)
1038 Provides: libopentracing.so.1()(64bit)
1039 Provides: libthrift.so.0.13.0()(64bit)
1040 %description -n libjaeger
1041 This package contains libraries needed to provide distributed
1042 tracing for Ceph.
1043 %endif
1044
1045 %package -n python%{python3_pkgversion}-cephfs
1046 Summary: Python 3 libraries for Ceph distributed file system
1047 %if 0%{?suse_version}
1048 Group: Development/Libraries/Python
1049 %endif
1050 Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release}
1051 Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release}
1052 Requires: python%{python3_pkgversion}-ceph-argparse = %{_epoch_prefix}%{version}-%{release}
1053 %{?python_provide:%python_provide python%{python3_pkgversion}-cephfs}
1054 Provides: python-cephfs = %{_epoch_prefix}%{version}-%{release}
1055 Obsoletes: python-cephfs < %{_epoch_prefix}%{version}-%{release}
1056 %description -n python%{python3_pkgversion}-cephfs
1057 This package contains Python 3 libraries for interacting with Ceph distributed
1058 file system.
1059
1060 %package -n python%{python3_pkgversion}-ceph-argparse
1061 Summary: Python 3 utility libraries for Ceph CLI
1062 %if 0%{?suse_version}
1063 Group: Development/Libraries/Python
1064 %endif
1065 %{?python_provide:%python_provide python%{python3_pkgversion}-ceph-argparse}
1066 %description -n python%{python3_pkgversion}-ceph-argparse
1067 This package contains types and routines for Python 3 used by the Ceph CLI as
1068 well as the RESTful interface. These have to do with querying the daemons for
1069 command-description information, validating user command input against those
1070 descriptions, and submitting the command to the appropriate daemon.
1071
1072 %package -n python%{python3_pkgversion}-ceph-common
1073 Summary: Python 3 utility libraries for Ceph
1074 %if 0%{?fedora} || 0%{?rhel} >= 8
1075 Requires: python%{python3_pkgversion}-pyyaml
1076 %endif
1077 %if 0%{?suse_version}
1078 Requires: python%{python3_pkgversion}-PyYAML
1079 %endif
1080 %if 0%{?suse_version}
1081 Group: Development/Libraries/Python
1082 %endif
1083 %{?python_provide:%python_provide python%{python3_pkgversion}-ceph-common}
1084 %description -n python%{python3_pkgversion}-ceph-common
1085 This package contains data structures, classes and functions used by Ceph.
1086 It also contains utilities used for the cephadm orchestrator.
1087
1088 %if 0%{with cephfs_shell}
1089 %package -n cephfs-shell
1090 Summary: Interactive shell for Ceph file system
1091 Requires: python%{python3_pkgversion}-cmd2
1092 Requires: python%{python3_pkgversion}-colorama
1093 Requires: python%{python3_pkgversion}-cephfs
1094 %description -n cephfs-shell
1095 This package contains an interactive tool that allows accessing a Ceph
1096 file system without mounting it by providing a nice pseudo-shell which
1097 works like an FTP client.
1098 %endif
1099
1100 %if 0%{with ceph_test_package}
1101 %package -n ceph-test
1102 Summary: Ceph benchmarks and test tools
1103 %if 0%{?suse_version}
1104 Group: System/Benchmark
1105 %endif
1106 Requires: ceph-common = %{_epoch_prefix}%{version}-%{release}
1107 Requires: xmlstarlet
1108 Requires: jq
1109 Requires: socat
1110 %description -n ceph-test
1111 This package contains Ceph benchmarks and test tools.
1112 %endif
1113
1114 %if 0%{with cephfs_java}
1115
1116 %package -n libcephfs_jni1
1117 Summary: Java Native Interface library for CephFS Java bindings
1118 %if 0%{?suse_version}
1119 Group: System/Libraries
1120 %endif
1121 Requires: java
1122 Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release}
1123 %description -n libcephfs_jni1
1124 This package contains the Java Native Interface library for CephFS Java
1125 bindings.
1126
1127 %package -n libcephfs_jni-devel
1128 Summary: Development files for CephFS Java Native Interface library
1129 %if 0%{?suse_version}
1130 Group: Development/Libraries/Java
1131 %endif
1132 Requires: java
1133 Requires: libcephfs_jni1 = %{_epoch_prefix}%{version}-%{release}
1134 Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release}
1135 Provides: libcephfs_jni1-devel = %{_epoch_prefix}%{version}-%{release}
1136 Obsoletes: libcephfs_jni1-devel < %{_epoch_prefix}%{version}-%{release}
1137 %description -n libcephfs_jni-devel
1138 This package contains the development files for CephFS Java Native Interface
1139 library.
1140
1141 %package -n cephfs-java
1142 Summary: Java libraries for the Ceph File System
1143 %if 0%{?suse_version}
1144 Group: System/Libraries
1145 %endif
1146 Requires: java
1147 Requires: libcephfs_jni1 = %{_epoch_prefix}%{version}-%{release}
1148 Requires: junit
1149 BuildRequires: junit
1150 %description -n cephfs-java
1151 This package contains the Java libraries for the Ceph File System.
1152
1153 %endif
1154
1155 %package -n rados-objclass-devel
1156 Summary: RADOS object class development kit
1157 %if 0%{?suse_version}
1158 Group: Development/Libraries/C and C++
1159 %endif
1160 Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release}
1161 %description -n rados-objclass-devel
1162 This package contains libraries and headers needed to develop RADOS object
1163 class plugins.
1164
1165 %if 0%{with selinux}
1166
1167 %package selinux
1168 Summary: SELinux support for Ceph MON, OSD and MDS
1169 %if 0%{?suse_version}
1170 Group: System/Filesystems
1171 %endif
1172 Requires: ceph-base = %{_epoch_prefix}%{version}-%{release}
1173 Requires: policycoreutils, libselinux-utils
1174 Requires(post): ceph-base = %{_epoch_prefix}%{version}-%{release}
1175 Requires(post): selinux-policy-base >= %{_selinux_policy_version}, policycoreutils, gawk
1176 Requires(postun): policycoreutils
1177 %description selinux
1178 This package contains SELinux support for Ceph MON, OSD and MDS. The package
1179 also performs file-system relabelling which can take a long time on heavily
1180 populated file-systems.
1181
1182 %endif
1183
1184 %package grafana-dashboards
1185 Summary: The set of Grafana dashboards for monitoring purposes
1186 BuildArch: noarch
1187 %if 0%{?suse_version}
1188 Group: System/Filesystems
1189 %endif
1190 %description grafana-dashboards
1191 This package provides a set of Grafana dashboards for monitoring of
1192 Ceph clusters. The dashboards require a Prometheus server setup
1193 collecting data from Ceph Manager "prometheus" module and Prometheus
1194 project "node_exporter" module. The dashboards are designed to be
1195 integrated with the Ceph Manager Dashboard web UI.
1196
1197 %package prometheus-alerts
1198 Summary: Prometheus alerts for a Ceph deployment
1199 BuildArch: noarch
1200 Group: System/Monitoring
1201 %description prometheus-alerts
1202 This package provides Ceph default alerts for Prometheus.
1203
1204 #################################################################################
1205 # common
1206 #################################################################################
1207 %prep
1208 %autosetup -p1 -n @TARBALL_BASENAME@
1209
1210 %build
1211 # LTO can be enabled as soon as the following GCC bug is fixed:
1212 # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48200
1213 %define _lto_cflags %{nil}
1214
1215 %if 0%{with seastar} && 0%{?rhel}
1216 . /opt/rh/gcc-toolset-9/enable
1217 %endif
1218
1219 %if 0%{with cephfs_java}
1220 # Find jni.h
1221 for i in /usr/{lib64,lib}/jvm/java/include{,/linux}; do
1222 [ -d $i ] && java_inc="$java_inc -I$i"
1223 done
1224 %endif
1225
1226 %if 0%{?suse_version}
1227 # the following setting fixed an OOM condition we once encountered in the OBS
1228 RPM_OPT_FLAGS="$RPM_OPT_FLAGS --param ggc-min-expand=20 --param ggc-min-heapsize=32768"
1229 %endif
1230
1231 export CPPFLAGS="$java_inc"
1232 export CFLAGS="$RPM_OPT_FLAGS"
1233 export CXXFLAGS="$RPM_OPT_FLAGS"
1234 export LDFLAGS="$RPM_LD_FLAGS"
1235
1236 %if 0%{with seastar}
1237 # seastar uses longjmp() to implement coroutine. and this annoys longjmp_chk()
1238 export CXXFLAGS=$(echo $RPM_OPT_FLAGS | sed -e 's/-Wp,-D_FORTIFY_SOURCE=2//g')
1239 %endif
1240
1241 # Parallel build settings ...
1242 CEPH_MFLAGS_JOBS="%{?_smp_mflags}"
1243 CEPH_SMP_NCPUS=$(echo "$CEPH_MFLAGS_JOBS" | sed 's/-j//')
1244 %if 0%{?__isa_bits} == 32
1245 # 32-bit builds can use 3G memory max, which is not enough even for -j2
1246 CEPH_SMP_NCPUS="1"
1247 %endif
1248 # do not eat all memory
1249 echo "Available memory:"
1250 free -h
1251 echo "System limits:"
1252 ulimit -a
1253 if test -n "$CEPH_SMP_NCPUS" -a "$CEPH_SMP_NCPUS" -gt 1 ; then
1254 mem_per_process=2500
1255 max_mem=$(LANG=C free -m | sed -n "s|^Mem: *\([0-9]*\).*$|\1|p")
1256 max_jobs="$(($max_mem / $mem_per_process))"
1257 test "$CEPH_SMP_NCPUS" -gt "$max_jobs" && CEPH_SMP_NCPUS="$max_jobs" && echo "Warning: Reducing build parallelism to -j$max_jobs because of memory limits"
1258 test "$CEPH_SMP_NCPUS" -le 0 && CEPH_SMP_NCPUS="1" && echo "Warning: Not using parallel build at all because of memory limits"
1259 fi
1260 export CEPH_SMP_NCPUS
1261 export CEPH_MFLAGS_JOBS="-j$CEPH_SMP_NCPUS"
1262
1263 env | sort
1264
1265 mkdir build
1266 cd build
1267 CMAKE=cmake
1268 ${CMAKE} .. \
1269 -DCMAKE_INSTALL_PREFIX=%{_prefix} \
1270 -DCMAKE_INSTALL_LIBDIR=%{_libdir} \
1271 -DCMAKE_INSTALL_LIBEXECDIR=%{_libexecdir} \
1272 -DCMAKE_INSTALL_LOCALSTATEDIR=%{_localstatedir} \
1273 -DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir} \
1274 -DCMAKE_INSTALL_MANDIR=%{_mandir} \
1275 -DCMAKE_INSTALL_DOCDIR=%{_docdir}/ceph \
1276 -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir} \
1277 -DCMAKE_INSTALL_SYSTEMD_SERVICEDIR=%{_unitdir} \
1278 -DWITH_MANPAGE=ON \
1279 -DWITH_PYTHON3=%{python3_version} \
1280 -DWITH_MGR_DASHBOARD_FRONTEND=OFF \
1281 %if 0%{without ceph_test_package}
1282 -DWITH_TESTS=OFF \
1283 %endif
1284 %if 0%{with cephfs_java}
1285 -DWITH_CEPHFS_JAVA=ON \
1286 %endif
1287 %if 0%{with selinux}
1288 -DWITH_SELINUX=ON \
1289 %endif
1290 %if %{with lttng}
1291 -DWITH_LTTNG=ON \
1292 -DWITH_BABELTRACE=ON \
1293 %else
1294 -DWITH_LTTNG=OFF \
1295 -DWITH_BABELTRACE=OFF \
1296 %endif
1297 $CEPH_EXTRA_CMAKE_ARGS \
1298 %if 0%{with ocf}
1299 -DWITH_OCF=ON \
1300 %endif
1301 %if 0%{with cephfs_shell}
1302 -DWITH_CEPHFS_SHELL=ON \
1303 %endif
1304 %if 0%{with libradosstriper}
1305 -DWITH_LIBRADOSSTRIPER=ON \
1306 %else
1307 -DWITH_LIBRADOSSTRIPER=OFF \
1308 %endif
1309 %if 0%{with amqp_endpoint}
1310 -DWITH_RADOSGW_AMQP_ENDPOINT=ON \
1311 %else
1312 -DWITH_RADOSGW_AMQP_ENDPOINT=OFF \
1313 %endif
1314 %if 0%{with kafka_endpoint}
1315 -DWITH_RADOSGW_KAFKA_ENDPOINT=ON \
1316 %else
1317 -DWITH_RADOSGW_KAFKA_ENDPOINT=OFF \
1318 %endif
1319 %if 0%{without lua_packages}
1320 -DWITH_RADOSGW_LUA_PACKAGES=OFF \
1321 %endif
1322 %if 0%{with zbd}
1323 -DWITH_ZBD=ON \
1324 %endif
1325 %if 0%{with cmake_verbose_logging}
1326 -DCMAKE_VERBOSE_MAKEFILE=ON \
1327 %endif
1328 %if 0%{with rbd_rwl_cache}
1329 -DWITH_RBD_RWL=ON \
1330 %endif
1331 %if 0%{with rbd_ssd_cache}
1332 -DWITH_RBD_SSD_CACHE=ON \
1333 %endif
1334 %if 0%{?_system_pmdk}
1335 -DWITH_SYSTEM_PMDK:BOOL=ON \
1336 %endif
1337 -DBOOST_J=$CEPH_SMP_NCPUS \
1338 -DWITH_GRAFANA=ON
1339
1340 %if %{with cmake_verbose_logging}
1341 cat ./CMakeFiles/CMakeOutput.log
1342 cat ./CMakeFiles/CMakeError.log
1343 %endif
1344
1345 make "$CEPH_MFLAGS_JOBS"
1346
1347
1348 %if 0%{with make_check}
1349 %check
1350 # run in-tree unittests
1351 cd build
1352 ctest "$CEPH_MFLAGS_JOBS"
1353 %endif
1354
1355
1356 %install
1357 pushd build
1358 make DESTDIR=%{buildroot} install
1359 # we have dropped sysvinit bits
1360 rm -f %{buildroot}/%{_sysconfdir}/init.d/ceph
1361 popd
1362
1363 %if 0%{with seastar}
1364 # package crimson-osd with the name of ceph-osd
1365 install -m 0755 %{buildroot}%{_bindir}/crimson-osd %{buildroot}%{_bindir}/ceph-osd
1366 %endif
1367
1368 install -m 0644 -D src/etc-rbdmap %{buildroot}%{_sysconfdir}/ceph/rbdmap
1369 %if 0%{?fedora} || 0%{?rhel}
1370 install -m 0644 -D etc/sysconfig/ceph %{buildroot}%{_sysconfdir}/sysconfig/ceph
1371 %endif
1372 %if 0%{?suse_version}
1373 install -m 0644 -D etc/sysconfig/ceph %{buildroot}%{_fillupdir}/sysconfig.%{name}
1374 %endif
1375 install -m 0644 -D systemd/ceph.tmpfiles.d %{buildroot}%{_tmpfilesdir}/ceph-common.conf
1376 install -m 0644 -D systemd/50-ceph.preset %{buildroot}%{_presetdir}/50-ceph.preset
1377 mkdir -p %{buildroot}%{_sbindir}
1378 install -m 0644 -D src/logrotate.conf %{buildroot}%{_sysconfdir}/logrotate.d/ceph
1379 chmod 0644 %{buildroot}%{_docdir}/ceph/sample.ceph.conf
1380 install -m 0644 -D COPYING %{buildroot}%{_docdir}/ceph/COPYING
1381 install -m 0644 -D etc/sysctl/90-ceph-osd.conf %{buildroot}%{_sysctldir}/90-ceph-osd.conf
1382 install -m 0755 -D src/tools/rbd_nbd/rbd-nbd_quiesce %{buildroot}%{_libexecdir}/rbd-nbd/rbd-nbd_quiesce
1383
1384 install -m 0755 src/cephadm/cephadm %{buildroot}%{_sbindir}/cephadm
1385 mkdir -p %{buildroot}%{_sharedstatedir}/cephadm
1386 chmod 0700 %{buildroot}%{_sharedstatedir}/cephadm
1387 mkdir -p %{buildroot}%{_sharedstatedir}/cephadm/.ssh
1388 chmod 0700 %{buildroot}%{_sharedstatedir}/cephadm/.ssh
1389 touch %{buildroot}%{_sharedstatedir}/cephadm/.ssh/authorized_keys
1390 chmod 0600 %{buildroot}%{_sharedstatedir}/cephadm/.ssh/authorized_keys
1391
1392 # firewall templates and /sbin/mount.ceph symlink
1393 %if 0%{?suse_version} && !0%{?usrmerged}
1394 mkdir -p %{buildroot}/sbin
1395 ln -sf %{_sbindir}/mount.ceph %{buildroot}/sbin/mount.ceph
1396 %endif
1397
1398 # udev rules
1399 install -m 0644 -D udev/50-rbd.rules %{buildroot}%{_udevrulesdir}/50-rbd.rules
1400
1401 # sudoers.d
1402 install -m 0440 -D sudoers.d/ceph-osd-smartctl %{buildroot}%{_sysconfdir}/sudoers.d/ceph-osd-smartctl
1403
1404 %if 0%{?rhel} >= 8
1405 pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{_bindir}/*
1406 pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{_sbindir}/*
1407 %endif
1408
1409 #set up placeholder directories
1410 mkdir -p %{buildroot}%{_sysconfdir}/ceph
1411 mkdir -p %{buildroot}%{_localstatedir}/run/ceph
1412 mkdir -p %{buildroot}%{_localstatedir}/log/ceph
1413 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/tmp
1414 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/mon
1415 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/osd
1416 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/mds
1417 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/mgr
1418 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/crash
1419 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/crash/posted
1420 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/radosgw
1421 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-osd
1422 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-mds
1423 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rgw
1424 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-mgr
1425 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd
1426 mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd-mirror
1427
1428 # prometheus alerts
1429 install -m 644 -D monitoring/prometheus/alerts/ceph_default_alerts.yml %{buildroot}/etc/prometheus/ceph/ceph_default_alerts.yml
1430
1431 %if 0%{?suse_version}
1432 # create __pycache__ directories and their contents
1433 %py3_compile %{buildroot}%{python3_sitelib}
1434 # hardlink duplicate files under /usr to save space
1435 %fdupes %{buildroot}%{_prefix}
1436 %endif
1437
1438 %if 0%{?rhel} == 8
1439 %py_byte_compile %{__python3} %{buildroot}%{python3_sitelib}
1440 %endif
1441
1442 %clean
1443 rm -rf %{buildroot}
1444
1445 #################################################################################
1446 # files and systemd scriptlets
1447 #################################################################################
1448 %files
1449
1450 %files base
1451 %{_bindir}/ceph-crash
1452 %{_bindir}/crushtool
1453 %{_bindir}/monmaptool
1454 %{_bindir}/osdmaptool
1455 %{_bindir}/ceph-kvstore-tool
1456 %{_bindir}/ceph-run
1457 %{_presetdir}/50-ceph.preset
1458 %{_sbindir}/ceph-create-keys
1459 %dir %{_libexecdir}/ceph
1460 %{_libexecdir}/ceph/ceph_common.sh
1461 %dir %{_libdir}/rados-classes
1462 %{_libdir}/rados-classes/*
1463 %dir %{_libdir}/ceph
1464 %dir %{_libdir}/ceph/erasure-code
1465 %{_libdir}/ceph/erasure-code/libec_*.so*
1466 %dir %{_libdir}/ceph/compressor
1467 %{_libdir}/ceph/compressor/libceph_*.so*
1468 %{_unitdir}/ceph-crash.service
1469 %dir %{_libdir}/ceph/crypto
1470 %{_libdir}/ceph/crypto/libceph_*.so*
1471 %if %{with lttng}
1472 %{_libdir}/libos_tp.so*
1473 %{_libdir}/libosd_tp.so*
1474 %endif
1475 %config(noreplace) %{_sysconfdir}/logrotate.d/ceph
1476 %if 0%{?fedora} || 0%{?rhel}
1477 %config(noreplace) %{_sysconfdir}/sysconfig/ceph
1478 %endif
1479 %if 0%{?suse_version}
1480 %{_fillupdir}/sysconfig.*
1481 %endif
1482 %{_unitdir}/ceph.target
1483 %dir %{python3_sitelib}/ceph_volume
1484 %{python3_sitelib}/ceph_volume/*
1485 %{python3_sitelib}/ceph_volume-*
1486 %{_mandir}/man8/ceph-deploy.8*
1487 %{_mandir}/man8/ceph-create-keys.8*
1488 %{_mandir}/man8/ceph-run.8*
1489 %{_mandir}/man8/crushtool.8*
1490 %{_mandir}/man8/osdmaptool.8*
1491 %{_mandir}/man8/monmaptool.8*
1492 %{_mandir}/man8/ceph-kvstore-tool.8*
1493 #set up placeholder directories
1494 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/crash
1495 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/crash/posted
1496 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/tmp
1497 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-osd
1498 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-mds
1499 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rgw
1500 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-mgr
1501 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rbd
1502 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rbd-mirror
1503
1504 %post base
1505 /sbin/ldconfig
1506 %if 0%{?suse_version}
1507 %fillup_only
1508 if [ $1 -eq 1 ] ; then
1509 /usr/bin/systemctl preset ceph.target ceph-crash.service >/dev/null 2>&1 || :
1510 fi
1511 %endif
1512 %if 0%{?fedora} || 0%{?rhel}
1513 %systemd_post ceph.target ceph-crash.service
1514 %endif
1515 if [ $1 -eq 1 ] ; then
1516 /usr/bin/systemctl start ceph.target ceph-crash.service >/dev/null 2>&1 || :
1517 fi
1518
1519 %preun base
1520 %if 0%{?suse_version}
1521 %service_del_preun ceph.target ceph-crash.service
1522 %endif
1523 %if 0%{?fedora} || 0%{?rhel}
1524 %systemd_preun ceph.target ceph-crash.service
1525 %endif
1526
1527 %postun base
1528 /sbin/ldconfig
1529 %systemd_postun ceph.target
1530
1531 %pre -n cephadm
1532 getent group cephadm >/dev/null || groupadd -r cephadm
1533 getent passwd cephadm >/dev/null || useradd -r -g cephadm -s /bin/bash -c "cephadm user for mgr/cephadm" -d %{_sharedstatedir}/cephadm cephadm
1534 exit 0
1535
1536 %if ! 0%{?suse_version}
1537 %postun -n cephadm
1538 userdel -r cephadm || true
1539 exit 0
1540 %endif
1541
1542 %files -n cephadm
1543 %{_sbindir}/cephadm
1544 %{_mandir}/man8/cephadm.8*
1545 %attr(0700,cephadm,cephadm) %dir %{_sharedstatedir}/cephadm
1546 %attr(0700,cephadm,cephadm) %dir %{_sharedstatedir}/cephadm/.ssh
1547 %attr(0600,cephadm,cephadm) %{_sharedstatedir}/cephadm/.ssh/authorized_keys
1548
1549 %files common
1550 %dir %{_docdir}/ceph
1551 %doc %{_docdir}/ceph/sample.ceph.conf
1552 %license %{_docdir}/ceph/COPYING
1553 %{_bindir}/ceph
1554 %{_bindir}/ceph-authtool
1555 %{_bindir}/ceph-conf
1556 %{_bindir}/ceph-dencoder
1557 %{_bindir}/ceph-rbdnamer
1558 %{_bindir}/ceph-syn
1559 %{_bindir}/cephfs-data-scan
1560 %{_bindir}/cephfs-journal-tool
1561 %{_bindir}/cephfs-table-tool
1562 %{_bindir}/rados
1563 %{_bindir}/radosgw-admin
1564 %{_bindir}/rbd
1565 %{_bindir}/rbd-replay
1566 %{_bindir}/rbd-replay-many
1567 %{_bindir}/rbdmap
1568 %{_sbindir}/mount.ceph
1569 %if 0%{?suse_version} && !0%{?usrmerged}
1570 /sbin/mount.ceph
1571 %endif
1572 %if %{with lttng}
1573 %{_bindir}/rbd-replay-prep
1574 %endif
1575 %{_bindir}/ceph-post-file
1576 %{_tmpfilesdir}/ceph-common.conf
1577 %{_mandir}/man8/ceph-authtool.8*
1578 %{_mandir}/man8/ceph-conf.8*
1579 %{_mandir}/man8/ceph-dencoder.8*
1580 %{_mandir}/man8/ceph-diff-sorted.8*
1581 %{_mandir}/man8/ceph-rbdnamer.8*
1582 %{_mandir}/man8/ceph-syn.8*
1583 %{_mandir}/man8/ceph-post-file.8*
1584 %{_mandir}/man8/ceph.8*
1585 %{_mandir}/man8/mount.ceph.8*
1586 %{_mandir}/man8/rados.8*
1587 %{_mandir}/man8/radosgw-admin.8*
1588 %{_mandir}/man8/rbd.8*
1589 %{_mandir}/man8/rbdmap.8*
1590 %{_mandir}/man8/rbd-replay.8*
1591 %{_mandir}/man8/rbd-replay-many.8*
1592 %{_mandir}/man8/rbd-replay-prep.8*
1593 %{_mandir}/man8/rgw-orphan-list.8*
1594 %dir %{_datadir}/ceph/
1595 %{_datadir}/ceph/known_hosts_drop.ceph.com
1596 %{_datadir}/ceph/id_rsa_drop.ceph.com
1597 %{_datadir}/ceph/id_rsa_drop.ceph.com.pub
1598 %dir %{_sysconfdir}/ceph/
1599 %config %{_sysconfdir}/bash_completion.d/ceph
1600 %config %{_sysconfdir}/bash_completion.d/rados
1601 %config %{_sysconfdir}/bash_completion.d/rbd
1602 %config %{_sysconfdir}/bash_completion.d/radosgw-admin
1603 %config(noreplace) %{_sysconfdir}/ceph/rbdmap
1604 %{_unitdir}/rbdmap.service
1605 %dir %{_udevrulesdir}
1606 %{_udevrulesdir}/50-rbd.rules
1607 %attr(3770,ceph,ceph) %dir %{_localstatedir}/log/ceph/
1608 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/
1609
1610 %pre common
1611 CEPH_GROUP_ID=167
1612 CEPH_USER_ID=167
1613 %if 0%{?rhel} || 0%{?fedora}
1614 /usr/sbin/groupadd ceph -g $CEPH_GROUP_ID -o -r 2>/dev/null || :
1615 /usr/sbin/useradd ceph -u $CEPH_USER_ID -o -r -g ceph -s /sbin/nologin -c "Ceph daemons" -d %{_localstatedir}/lib/ceph 2>/dev/null || :
1616 %endif
1617 %if 0%{?suse_version}
1618 if ! getent group ceph >/dev/null ; then
1619 CEPH_GROUP_ID_OPTION=""
1620 getent group $CEPH_GROUP_ID >/dev/null || CEPH_GROUP_ID_OPTION="-g $CEPH_GROUP_ID"
1621 groupadd ceph $CEPH_GROUP_ID_OPTION -r 2>/dev/null || :
1622 fi
1623 if ! getent passwd ceph >/dev/null ; then
1624 CEPH_USER_ID_OPTION=""
1625 getent passwd $CEPH_USER_ID >/dev/null || CEPH_USER_ID_OPTION="-u $CEPH_USER_ID"
1626 useradd ceph $CEPH_USER_ID_OPTION -r -g ceph -s /sbin/nologin 2>/dev/null || :
1627 fi
1628 usermod -c "Ceph storage service" \
1629 -d %{_localstatedir}/lib/ceph \
1630 -g ceph \
1631 -s /sbin/nologin \
1632 ceph
1633 %endif
1634 exit 0
1635
1636 %post common
1637 %tmpfiles_create %{_tmpfilesdir}/ceph-common.conf
1638
1639 %postun common
1640 # Package removal cleanup
1641 if [ "$1" -eq "0" ] ; then
1642 rm -rf %{_localstatedir}/log/ceph
1643 rm -rf %{_sysconfdir}/ceph
1644 fi
1645
1646 %files mds
1647 %{_bindir}/ceph-mds
1648 %{_mandir}/man8/ceph-mds.8*
1649 %{_unitdir}/ceph-mds@.service
1650 %{_unitdir}/ceph-mds.target
1651 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mds
1652
1653 %post mds
1654 %if 0%{?suse_version}
1655 if [ $1 -eq 1 ] ; then
1656 /usr/bin/systemctl preset ceph-mds@\*.service ceph-mds.target >/dev/null 2>&1 || :
1657 fi
1658 %endif
1659 %if 0%{?fedora} || 0%{?rhel}
1660 %systemd_post ceph-mds@\*.service ceph-mds.target
1661 %endif
1662 if [ $1 -eq 1 ] ; then
1663 /usr/bin/systemctl start ceph-mds.target >/dev/null 2>&1 || :
1664 fi
1665
1666 %preun mds
1667 %if 0%{?suse_version}
1668 %service_del_preun ceph-mds@\*.service ceph-mds.target
1669 %endif
1670 %if 0%{?fedora} || 0%{?rhel}
1671 %systemd_preun ceph-mds@\*.service ceph-mds.target
1672 %endif
1673
1674 %postun mds
1675 %systemd_postun ceph-mds@\*.service ceph-mds.target
1676 if [ $1 -ge 1 ] ; then
1677 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
1678 # "yes". In any case: if units are not running, do not touch them.
1679 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
1680 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
1681 source $SYSCONF_CEPH
1682 fi
1683 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
1684 /usr/bin/systemctl try-restart ceph-mds@\*.service > /dev/null 2>&1 || :
1685 fi
1686 fi
1687
1688 %files mgr
1689 %{_bindir}/ceph-mgr
1690 %dir %{_datadir}/ceph/mgr
1691 %{_datadir}/ceph/mgr/mgr_module.*
1692 %{_datadir}/ceph/mgr/mgr_util.*
1693 %{_unitdir}/ceph-mgr@.service
1694 %{_unitdir}/ceph-mgr.target
1695 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mgr
1696
1697 %post mgr
1698 %if 0%{?suse_version}
1699 if [ $1 -eq 1 ] ; then
1700 /usr/bin/systemctl preset ceph-mgr@\*.service ceph-mgr.target >/dev/null 2>&1 || :
1701 fi
1702 %endif
1703 %if 0%{?fedora} || 0%{?rhel}
1704 %systemd_post ceph-mgr@\*.service ceph-mgr.target
1705 %endif
1706 if [ $1 -eq 1 ] ; then
1707 /usr/bin/systemctl start ceph-mgr.target >/dev/null 2>&1 || :
1708 fi
1709
1710 %preun mgr
1711 %if 0%{?suse_version}
1712 %service_del_preun ceph-mgr@\*.service ceph-mgr.target
1713 %endif
1714 %if 0%{?fedora} || 0%{?rhel}
1715 %systemd_preun ceph-mgr@\*.service ceph-mgr.target
1716 %endif
1717
1718 %postun mgr
1719 %systemd_postun ceph-mgr@\*.service ceph-mgr.target
1720 if [ $1 -ge 1 ] ; then
1721 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
1722 # "yes". In any case: if units are not running, do not touch them.
1723 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
1724 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
1725 source $SYSCONF_CEPH
1726 fi
1727 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
1728 /usr/bin/systemctl try-restart ceph-mgr@\*.service > /dev/null 2>&1 || :
1729 fi
1730 fi
1731
1732 %files mgr-dashboard
1733 %{_datadir}/ceph/mgr/dashboard
1734
1735 %post mgr-dashboard
1736 if [ $1 -eq 1 ] ; then
1737 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1738 fi
1739
1740 %postun mgr-dashboard
1741 if [ $1 -eq 1 ] ; then
1742 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1743 fi
1744
1745 %files mgr-diskprediction-local
1746 %{_datadir}/ceph/mgr/diskprediction_local
1747
1748 %post mgr-diskprediction-local
1749 if [ $1 -eq 1 ] ; then
1750 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1751 fi
1752
1753 %postun mgr-diskprediction-local
1754 if [ $1 -eq 1 ] ; then
1755 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1756 fi
1757
1758 %files mgr-modules-core
1759 %dir %{_datadir}/ceph/mgr
1760 %{_datadir}/ceph/mgr/alerts
1761 %{_datadir}/ceph/mgr/balancer
1762 %{_datadir}/ceph/mgr/crash
1763 %{_datadir}/ceph/mgr/devicehealth
1764 %{_datadir}/ceph/mgr/influx
1765 %{_datadir}/ceph/mgr/insights
1766 %{_datadir}/ceph/mgr/iostat
1767 %{_datadir}/ceph/mgr/localpool
1768 %{_datadir}/ceph/mgr/mds_autoscaler
1769 %{_datadir}/ceph/mgr/mirroring
1770 %{_datadir}/ceph/mgr/orchestrator
1771 %{_datadir}/ceph/mgr/osd_perf_query
1772 %{_datadir}/ceph/mgr/osd_support
1773 %{_datadir}/ceph/mgr/pg_autoscaler
1774 %{_datadir}/ceph/mgr/progress
1775 %{_datadir}/ceph/mgr/prometheus
1776 %{_datadir}/ceph/mgr/rbd_support
1777 %{_datadir}/ceph/mgr/restful
1778 %{_datadir}/ceph/mgr/selftest
1779 %{_datadir}/ceph/mgr/snap_schedule
1780 %{_datadir}/ceph/mgr/stats
1781 %{_datadir}/ceph/mgr/status
1782 %{_datadir}/ceph/mgr/telegraf
1783 %{_datadir}/ceph/mgr/telemetry
1784 %{_datadir}/ceph/mgr/test_orchestrator
1785 %{_datadir}/ceph/mgr/volumes
1786 %{_datadir}/ceph/mgr/zabbix
1787
1788 %files mgr-rook
1789 %{_datadir}/ceph/mgr/rook
1790
1791 %post mgr-rook
1792 if [ $1 -eq 1 ] ; then
1793 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1794 fi
1795
1796 %postun mgr-rook
1797 if [ $1 -eq 1 ] ; then
1798 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1799 fi
1800
1801 %files mgr-k8sevents
1802 %{_datadir}/ceph/mgr/k8sevents
1803
1804 %post mgr-k8sevents
1805 if [ $1 -eq 1 ] ; then
1806 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1807 fi
1808
1809 %postun mgr-k8sevents
1810 if [ $1 -eq 1 ] ; then
1811 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1812 fi
1813
1814 %files mgr-cephadm
1815 %{_datadir}/ceph/mgr/cephadm
1816
1817 %post mgr-cephadm
1818 if [ $1 -eq 1 ] ; then
1819 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1820 fi
1821
1822 %postun mgr-cephadm
1823 if [ $1 -eq 1 ] ; then
1824 /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || :
1825 fi
1826
1827 %files mon
1828 %{_bindir}/ceph-mon
1829 %{_bindir}/ceph-monstore-tool
1830 %{_mandir}/man8/ceph-mon.8*
1831 %{_unitdir}/ceph-mon@.service
1832 %{_unitdir}/ceph-mon.target
1833 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mon
1834
1835 %post mon
1836 %if 0%{?suse_version}
1837 if [ $1 -eq 1 ] ; then
1838 /usr/bin/systemctl preset ceph-mon@\*.service ceph-mon.target >/dev/null 2>&1 || :
1839 fi
1840 %endif
1841 %if 0%{?fedora} || 0%{?rhel}
1842 %systemd_post ceph-mon@\*.service ceph-mon.target
1843 %endif
1844 if [ $1 -eq 1 ] ; then
1845 /usr/bin/systemctl start ceph-mon.target >/dev/null 2>&1 || :
1846 fi
1847
1848 %preun mon
1849 %if 0%{?suse_version}
1850 %service_del_preun ceph-mon@\*.service ceph-mon.target
1851 %endif
1852 %if 0%{?fedora} || 0%{?rhel}
1853 %systemd_preun ceph-mon@\*.service ceph-mon.target
1854 %endif
1855
1856 %postun mon
1857 %systemd_postun ceph-mon@\*.service ceph-mon.target
1858 if [ $1 -ge 1 ] ; then
1859 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
1860 # "yes". In any case: if units are not running, do not touch them.
1861 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
1862 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
1863 source $SYSCONF_CEPH
1864 fi
1865 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
1866 /usr/bin/systemctl try-restart ceph-mon@\*.service > /dev/null 2>&1 || :
1867 fi
1868 fi
1869
1870 %files fuse
1871 %{_bindir}/ceph-fuse
1872 %{_mandir}/man8/ceph-fuse.8*
1873 %{_sbindir}/mount.fuse.ceph
1874 %{_mandir}/man8/mount.fuse.ceph.8*
1875 %{_unitdir}/ceph-fuse@.service
1876 %{_unitdir}/ceph-fuse.target
1877
1878 %files -n cephfs-mirror
1879 %{_bindir}/cephfs-mirror
1880 %{_mandir}/man8/cephfs-mirror.8*
1881 %{_unitdir}/cephfs-mirror@.service
1882 %{_unitdir}/cephfs-mirror.target
1883
1884 %post -n cephfs-mirror
1885 %if 0%{?suse_version}
1886 if [ $1 -eq 1 ] ; then
1887 /usr/bin/systemctl preset cephfs-mirror@\*.service cephfs-mirror.target >/dev/null 2>&1 || :
1888 fi
1889 %endif
1890 %if 0%{?fedora} || 0%{?rhel}
1891 %systemd_post cephfs-mirror@\*.service cephfs-mirror.target
1892 %endif
1893 if [ $1 -eq 1 ] ; then
1894 /usr/bin/systemctl start cephfs-mirror.target >/dev/null 2>&1 || :
1895 fi
1896
1897 %preun -n cephfs-mirror
1898 %if 0%{?suse_version}
1899 %service_del_preun cephfs-mirror@\*.service cephfs-mirror.target
1900 %endif
1901 %if 0%{?fedora} || 0%{?rhel}
1902 %systemd_preun cephfs-mirror@\*.service cephfs-mirror.target
1903 %endif
1904
1905 %postun -n cephfs-mirror
1906 %systemd_postun cephfs-mirror@\*.service cephfs-mirror.target
1907 if [ $1 -ge 1 ] ; then
1908 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
1909 # "yes". In any case: if units are not running, do not touch them.
1910 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
1911 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
1912 source $SYSCONF_CEPH
1913 fi
1914 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
1915 /usr/bin/systemctl try-restart cephfs-mirror@\*.service > /dev/null 2>&1 || :
1916 fi
1917 fi
1918
1919 %files -n rbd-fuse
1920 %{_bindir}/rbd-fuse
1921 %{_mandir}/man8/rbd-fuse.8*
1922
1923 %files -n rbd-mirror
1924 %{_bindir}/rbd-mirror
1925 %{_mandir}/man8/rbd-mirror.8*
1926 %{_unitdir}/ceph-rbd-mirror@.service
1927 %{_unitdir}/ceph-rbd-mirror.target
1928
1929 %post -n rbd-mirror
1930 %if 0%{?suse_version}
1931 if [ $1 -eq 1 ] ; then
1932 /usr/bin/systemctl preset ceph-rbd-mirror@\*.service ceph-rbd-mirror.target >/dev/null 2>&1 || :
1933 fi
1934 %endif
1935 %if 0%{?fedora} || 0%{?rhel}
1936 %systemd_post ceph-rbd-mirror@\*.service ceph-rbd-mirror.target
1937 %endif
1938 if [ $1 -eq 1 ] ; then
1939 /usr/bin/systemctl start ceph-rbd-mirror.target >/dev/null 2>&1 || :
1940 fi
1941
1942 %preun -n rbd-mirror
1943 %if 0%{?suse_version}
1944 %service_del_preun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target
1945 %endif
1946 %if 0%{?fedora} || 0%{?rhel}
1947 %systemd_preun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target
1948 %endif
1949
1950 %postun -n rbd-mirror
1951 %systemd_postun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target
1952 if [ $1 -ge 1 ] ; then
1953 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
1954 # "yes". In any case: if units are not running, do not touch them.
1955 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
1956 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
1957 source $SYSCONF_CEPH
1958 fi
1959 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
1960 /usr/bin/systemctl try-restart ceph-rbd-mirror@\*.service > /dev/null 2>&1 || :
1961 fi
1962 fi
1963
1964 %files immutable-object-cache
1965 %{_bindir}/ceph-immutable-object-cache
1966 %{_mandir}/man8/ceph-immutable-object-cache.8*
1967 %{_unitdir}/ceph-immutable-object-cache@.service
1968 %{_unitdir}/ceph-immutable-object-cache.target
1969
1970 %post immutable-object-cache
1971 %if 0%{?suse_version}
1972 if [ $1 -eq 1 ] ; then
1973 /usr/bin/systemctl preset ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target >/dev/null 2>&1 || :
1974 fi
1975 %endif
1976 %if 0%{?fedora} || 0%{?rhel}
1977 %systemd_post ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target
1978 %endif
1979 if [ $1 -eq 1 ] ; then
1980 /usr/bin/systemctl start ceph-immutable-object-cache.target >/dev/null 2>&1 || :
1981 fi
1982
1983 %preun immutable-object-cache
1984 %if 0%{?suse_version}
1985 %service_del_preun ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target
1986 %endif
1987 %if 0%{?fedora} || 0%{?rhel}
1988 %systemd_preun ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target
1989 %endif
1990
1991 %postun immutable-object-cache
1992 test -n "$FIRST_ARG" || FIRST_ARG=$1
1993 %systemd_postun ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target
1994 if [ $FIRST_ARG -ge 1 ] ; then
1995 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
1996 # "yes". In any case: if units are not running, do not touch them.
1997 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
1998 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
1999 source $SYSCONF_CEPH
2000 fi
2001 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
2002 /usr/bin/systemctl try-restart ceph-immutable-object-cache@\*.service > /dev/null 2>&1 || :
2003 fi
2004 fi
2005
2006 %files -n rbd-nbd
2007 %{_bindir}/rbd-nbd
2008 %{_mandir}/man8/rbd-nbd.8*
2009 %dir %{_libexecdir}/rbd-nbd
2010 %{_libexecdir}/rbd-nbd/rbd-nbd_quiesce
2011
2012 %files radosgw
2013 %{_bindir}/ceph-diff-sorted
2014 %{_bindir}/radosgw
2015 %{_bindir}/radosgw-token
2016 %{_bindir}/radosgw-es
2017 %{_bindir}/radosgw-object-expirer
2018 %{_bindir}/rgw-gap-list
2019 %{_bindir}/rgw-gap-list-comparator
2020 %{_bindir}/rgw-orphan-list
2021 %{_libdir}/libradosgw.so*
2022 %{_mandir}/man8/radosgw.8*
2023 %dir %{_localstatedir}/lib/ceph/radosgw
2024 %{_unitdir}/ceph-radosgw@.service
2025 %{_unitdir}/ceph-radosgw.target
2026
2027 %post radosgw
2028 /sbin/ldconfig
2029 %if 0%{?suse_version}
2030 if [ $1 -eq 1 ] ; then
2031 /usr/bin/systemctl preset ceph-radosgw@\*.service ceph-radosgw.target >/dev/null 2>&1 || :
2032 fi
2033 %endif
2034 %if 0%{?fedora} || 0%{?rhel}
2035 %systemd_post ceph-radosgw@\*.service ceph-radosgw.target
2036 %endif
2037 if [ $1 -eq 1 ] ; then
2038 /usr/bin/systemctl start ceph-radosgw.target >/dev/null 2>&1 || :
2039 fi
2040
2041 %preun radosgw
2042 %if 0%{?suse_version}
2043 %service_del_preun ceph-radosgw@\*.service ceph-radosgw.target
2044 %endif
2045 %if 0%{?fedora} || 0%{?rhel}
2046 %systemd_preun ceph-radosgw@\*.service ceph-radosgw.target
2047 %endif
2048
2049 %postun radosgw
2050 /sbin/ldconfig
2051 %systemd_postun ceph-radosgw@\*.service ceph-radosgw.target
2052 if [ $1 -ge 1 ] ; then
2053 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
2054 # "yes". In any case: if units are not running, do not touch them.
2055 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
2056 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
2057 source $SYSCONF_CEPH
2058 fi
2059 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
2060 /usr/bin/systemctl try-restart ceph-radosgw@\*.service > /dev/null 2>&1 || :
2061 fi
2062 fi
2063
2064 %files osd
2065 %{_bindir}/ceph-clsinfo
2066 %{_bindir}/ceph-bluestore-tool
2067 %{_bindir}/ceph-erasure-code-tool
2068 %{_bindir}/ceph-objectstore-tool
2069 %{_bindir}/ceph-osdomap-tool
2070 %{_bindir}/ceph-osd
2071 %{_libexecdir}/ceph/ceph-osd-prestart.sh
2072 %{_sbindir}/ceph-volume
2073 %{_sbindir}/ceph-volume-systemd
2074 %{_mandir}/man8/ceph-clsinfo.8*
2075 %{_mandir}/man8/ceph-osd.8*
2076 %{_mandir}/man8/ceph-bluestore-tool.8*
2077 %{_mandir}/man8/ceph-volume.8*
2078 %{_mandir}/man8/ceph-volume-systemd.8*
2079 %{_unitdir}/ceph-osd@.service
2080 %{_unitdir}/ceph-osd.target
2081 %{_unitdir}/ceph-volume@.service
2082 %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/osd
2083 %config(noreplace) %{_sysctldir}/90-ceph-osd.conf
2084 %{_sysconfdir}/sudoers.d/ceph-osd-smartctl
2085
2086 %post osd
2087 %if 0%{?suse_version}
2088 if [ $1 -eq 1 ] ; then
2089 /usr/bin/systemctl preset ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target >/dev/null 2>&1 || :
2090 fi
2091 %endif
2092 %if 0%{?fedora} || 0%{?rhel}
2093 %systemd_post ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target
2094 %endif
2095 if [ $1 -eq 1 ] ; then
2096 /usr/bin/systemctl start ceph-osd.target >/dev/null 2>&1 || :
2097 fi
2098 %if 0%{?sysctl_apply}
2099 %sysctl_apply 90-ceph-osd.conf
2100 %else
2101 /usr/lib/systemd/systemd-sysctl %{_sysctldir}/90-ceph-osd.conf > /dev/null 2>&1 || :
2102 %endif
2103
2104 %preun osd
2105 %if 0%{?suse_version}
2106 %service_del_preun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target
2107 %endif
2108 %if 0%{?fedora} || 0%{?rhel}
2109 %systemd_preun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target
2110 %endif
2111
2112 %postun osd
2113 %systemd_postun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target
2114 if [ $1 -ge 1 ] ; then
2115 # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to
2116 # "yes". In any case: if units are not running, do not touch them.
2117 SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph
2118 if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then
2119 source $SYSCONF_CEPH
2120 fi
2121 if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then
2122 /usr/bin/systemctl try-restart ceph-osd@\*.service ceph-volume@\*.service > /dev/null 2>&1 || :
2123 fi
2124 fi
2125
2126 %if 0%{with seastar}
2127 %files crimson-osd
2128 %{_bindir}/crimson-osd
2129 %endif
2130
2131 %if %{with ocf}
2132
2133 %files resource-agents
2134 %dir %{_prefix}/lib/ocf
2135 %dir %{_prefix}/lib/ocf/resource.d
2136 %dir %{_prefix}/lib/ocf/resource.d/ceph
2137 %attr(0755,-,-) %{_prefix}/lib/ocf/resource.d/ceph/rbd
2138
2139 %endif
2140
2141 %files -n librados2
2142 %{_libdir}/librados.so.*
2143 %dir %{_libdir}/ceph
2144 %{_libdir}/ceph/libceph-common.so.*
2145 %if %{with lttng}
2146 %{_libdir}/librados_tp.so.*
2147 %endif
2148 %dir %{_sysconfdir}/ceph
2149
2150 %post -n librados2 -p /sbin/ldconfig
2151
2152 %postun -n librados2 -p /sbin/ldconfig
2153
2154 %files -n librados-devel
2155 %dir %{_includedir}/rados
2156 %{_includedir}/rados/librados.h
2157 %{_includedir}/rados/rados_types.h
2158 %{_libdir}/librados.so
2159 %if %{with lttng}
2160 %{_libdir}/librados_tp.so
2161 %endif
2162 %{_bindir}/librados-config
2163 %{_mandir}/man8/librados-config.8*
2164
2165 %files -n libradospp-devel
2166 %dir %{_includedir}/rados
2167 %{_includedir}/rados/buffer.h
2168 %{_includedir}/rados/buffer_fwd.h
2169 %{_includedir}/rados/crc32c.h
2170 %{_includedir}/rados/inline_memory.h
2171 %{_includedir}/rados/librados.hpp
2172 %{_includedir}/rados/librados_fwd.hpp
2173 %{_includedir}/rados/page.h
2174 %{_includedir}/rados/rados_types.hpp
2175
2176 %files -n python%{python3_pkgversion}-rados
2177 %{python3_sitearch}/rados.cpython*.so
2178 %{python3_sitearch}/rados-*.egg-info
2179
2180 %files -n libcephsqlite
2181 %{_libdir}/libcephsqlite.so
2182
2183 %post -n libcephsqlite -p /sbin/ldconfig
2184
2185 %postun -n libcephsqlite -p /sbin/ldconfig
2186
2187 %files -n libcephsqlite-devel
2188 %{_includedir}/libcephsqlite.h
2189
2190 %if 0%{with libradosstriper}
2191 %files -n libradosstriper1
2192 %{_libdir}/libradosstriper.so.*
2193
2194 %post -n libradosstriper1 -p /sbin/ldconfig
2195
2196 %postun -n libradosstriper1 -p /sbin/ldconfig
2197
2198 %files -n libradosstriper-devel
2199 %dir %{_includedir}/radosstriper
2200 %{_includedir}/radosstriper/libradosstriper.h
2201 %{_includedir}/radosstriper/libradosstriper.hpp
2202 %{_libdir}/libradosstriper.so
2203 %endif
2204
2205 %files -n librbd1
2206 %{_libdir}/librbd.so.*
2207 %if %{with lttng}
2208 %{_libdir}/librbd_tp.so.*
2209 %endif
2210 %dir %{_libdir}/ceph/librbd
2211 %{_libdir}/ceph/librbd/libceph_*.so*
2212
2213 %post -n librbd1 -p /sbin/ldconfig
2214
2215 %postun -n librbd1 -p /sbin/ldconfig
2216
2217 %files -n librbd-devel
2218 %dir %{_includedir}/rbd
2219 %{_includedir}/rbd/librbd.h
2220 %{_includedir}/rbd/librbd.hpp
2221 %{_includedir}/rbd/features.h
2222 %{_libdir}/librbd.so
2223 %if %{with lttng}
2224 %{_libdir}/librbd_tp.so
2225 %endif
2226
2227 %files -n librgw2
2228 %{_libdir}/librgw.so.*
2229 %if %{with lttng}
2230 %{_libdir}/librgw_op_tp.so.*
2231 %{_libdir}/librgw_rados_tp.so.*
2232 %endif
2233
2234 %post -n librgw2 -p /sbin/ldconfig
2235
2236 %postun -n librgw2 -p /sbin/ldconfig
2237
2238 %files -n librgw-devel
2239 %dir %{_includedir}/rados
2240 %{_includedir}/rados/librgw.h
2241 %{_includedir}/rados/rgw_file.h
2242 %{_libdir}/librgw.so
2243 %if %{with lttng}
2244 %{_libdir}/librgw_op_tp.so
2245 %{_libdir}/librgw_rados_tp.so
2246 %endif
2247
2248 %files -n python%{python3_pkgversion}-rgw
2249 %{python3_sitearch}/rgw.cpython*.so
2250 %{python3_sitearch}/rgw-*.egg-info
2251
2252 %files -n python%{python3_pkgversion}-rbd
2253 %{python3_sitearch}/rbd.cpython*.so
2254 %{python3_sitearch}/rbd-*.egg-info
2255
2256 %files -n libcephfs2
2257 %{_libdir}/libcephfs.so.*
2258 %dir %{_sysconfdir}/ceph
2259
2260 %post -n libcephfs2 -p /sbin/ldconfig
2261
2262 %postun -n libcephfs2 -p /sbin/ldconfig
2263
2264 %files -n libcephfs-devel
2265 %dir %{_includedir}/cephfs
2266 %{_includedir}/cephfs/libcephfs.h
2267 %{_includedir}/cephfs/ceph_ll_client.h
2268 %dir %{_includedir}/cephfs/metrics
2269 %{_includedir}/cephfs/metrics/Types.h
2270 %{_libdir}/libcephfs.so
2271
2272 %if %{with jaeger}
2273 %files -n libjaeger
2274 %{_libdir}/libopentracing.so.*
2275 %{_libdir}/libthrift.so.*
2276 %{_libdir}/libjaegertracing.so.*
2277 %post -n libjaeger -p /sbin/ldconfig
2278 %postun -n libjaeger -p /sbin/ldconfig
2279 %endif
2280
2281 %files -n python%{python3_pkgversion}-cephfs
2282 %{python3_sitearch}/cephfs.cpython*.so
2283 %{python3_sitearch}/cephfs-*.egg-info
2284 %{python3_sitelib}/ceph_volume_client.py
2285 %{python3_sitelib}/__pycache__/ceph_volume_client.cpython*.py*
2286
2287 %files -n python%{python3_pkgversion}-ceph-argparse
2288 %{python3_sitelib}/ceph_argparse.py
2289 %{python3_sitelib}/__pycache__/ceph_argparse.cpython*.py*
2290 %{python3_sitelib}/ceph_daemon.py
2291 %{python3_sitelib}/__pycache__/ceph_daemon.cpython*.py*
2292
2293 %files -n python%{python3_pkgversion}-ceph-common
2294 %{python3_sitelib}/ceph
2295 %{python3_sitelib}/ceph-*.egg-info
2296
2297 %if 0%{with cephfs_shell}
2298 %files -n cephfs-shell
2299 %{python3_sitelib}/cephfs_shell-*.egg-info
2300 %{_bindir}/cephfs-shell
2301 %endif
2302
2303 %files -n cephfs-top
2304 %{python3_sitelib}/cephfs_top-*.egg-info
2305 %{_bindir}/cephfs-top
2306 %{_mandir}/man8/cephfs-top.8*
2307
2308 %if 0%{with ceph_test_package}
2309 %files -n ceph-test
2310 %{_bindir}/ceph-client-debug
2311 %{_bindir}/ceph_bench_log
2312 %{_bindir}/ceph_kvstorebench
2313 %{_bindir}/ceph_multi_stress_watch
2314 %{_bindir}/ceph_erasure_code_benchmark
2315 %{_bindir}/ceph_omapbench
2316 %{_bindir}/ceph_objectstore_bench
2317 %{_bindir}/ceph_perf_objectstore
2318 %{_bindir}/ceph_perf_local
2319 %{_bindir}/ceph_perf_msgr_client
2320 %{_bindir}/ceph_perf_msgr_server
2321 %{_bindir}/ceph_psim
2322 %{_bindir}/ceph_radosacl
2323 %{_bindir}/ceph_rgw_jsonparser
2324 %{_bindir}/ceph_rgw_multiparser
2325 %{_bindir}/ceph_scratchtool
2326 %{_bindir}/ceph_scratchtoolpp
2327 %{_bindir}/ceph_test_*
2328 %{_bindir}/ceph-coverage
2329 %{_bindir}/ceph-debugpack
2330 %{_bindir}/ceph-dedup-tool
2331 %if 0%{with seastar}
2332 %{_bindir}/crimson-store-nbd
2333 %endif
2334 %{_mandir}/man8/ceph-debugpack.8*
2335 %dir %{_libdir}/ceph
2336 %{_libdir}/ceph/ceph-monstore-update-crush.sh
2337 %endif
2338
2339 %if 0%{with cephfs_java}
2340 %files -n libcephfs_jni1
2341 %{_libdir}/libcephfs_jni.so.*
2342
2343 %post -n libcephfs_jni1 -p /sbin/ldconfig
2344
2345 %postun -n libcephfs_jni1 -p /sbin/ldconfig
2346
2347 %files -n libcephfs_jni-devel
2348 %{_libdir}/libcephfs_jni.so
2349
2350 %files -n cephfs-java
2351 %{_javadir}/libcephfs.jar
2352 %{_javadir}/libcephfs-test.jar
2353 %endif
2354
2355 %files -n rados-objclass-devel
2356 %dir %{_includedir}/rados
2357 %{_includedir}/rados/objclass.h
2358
2359 %if 0%{with selinux}
2360 %files selinux
2361 %attr(0600,root,root) %{_datadir}/selinux/packages/ceph.pp
2362 %{_datadir}/selinux/devel/include/contrib/ceph.if
2363 %{_mandir}/man8/ceph_selinux.8*
2364
2365 %post selinux
2366 # backup file_contexts before update
2367 . /etc/selinux/config
2368 FILE_CONTEXT=/etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts
2369 cp ${FILE_CONTEXT} ${FILE_CONTEXT}.pre
2370
2371 # Install the policy
2372 /usr/sbin/semodule -i %{_datadir}/selinux/packages/ceph.pp
2373
2374 # Load the policy if SELinux is enabled
2375 if ! /usr/sbin/selinuxenabled; then
2376 # Do not relabel if selinux is not enabled
2377 exit 0
2378 fi
2379
2380 if diff ${FILE_CONTEXT} ${FILE_CONTEXT}.pre > /dev/null 2>&1; then
2381 # Do not relabel if file contexts did not change
2382 exit 0
2383 fi
2384
2385 # Check whether the daemons are running
2386 /usr/bin/systemctl status ceph.target > /dev/null 2>&1
2387 STATUS=$?
2388
2389 # Stop the daemons if they were running
2390 if test $STATUS -eq 0; then
2391 /usr/bin/systemctl stop ceph.target > /dev/null 2>&1
2392 fi
2393
2394 # Relabel the files fix for first package install
2395 /usr/sbin/fixfiles -C ${FILE_CONTEXT}.pre restore 2> /dev/null
2396
2397 rm -f ${FILE_CONTEXT}.pre
2398 # The fixfiles command won't fix label for /var/run/ceph
2399 /usr/sbin/restorecon -R /var/run/ceph > /dev/null 2>&1
2400
2401 # Start the daemons iff they were running before
2402 if test $STATUS -eq 0; then
2403 /usr/bin/systemctl start ceph.target > /dev/null 2>&1 || :
2404 fi
2405 exit 0
2406
2407 %postun selinux
2408 if [ $1 -eq 0 ]; then
2409 # backup file_contexts before update
2410 . /etc/selinux/config
2411 FILE_CONTEXT=/etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts
2412 cp ${FILE_CONTEXT} ${FILE_CONTEXT}.pre
2413
2414 # Remove the module
2415 /usr/sbin/semodule -n -r ceph > /dev/null 2>&1
2416
2417 # Reload the policy if SELinux is enabled
2418 if ! /usr/sbin/selinuxenabled ; then
2419 # Do not relabel if SELinux is not enabled
2420 exit 0
2421 fi
2422
2423 # Check whether the daemons are running
2424 /usr/bin/systemctl status ceph.target > /dev/null 2>&1
2425 STATUS=$?
2426
2427 # Stop the daemons if they were running
2428 if test $STATUS -eq 0; then
2429 /usr/bin/systemctl stop ceph.target > /dev/null 2>&1
2430 fi
2431
2432 /usr/sbin/fixfiles -C ${FILE_CONTEXT}.pre restore 2> /dev/null
2433 rm -f ${FILE_CONTEXT}.pre
2434 # The fixfiles command won't fix label for /var/run/ceph
2435 /usr/sbin/restorecon -R /var/run/ceph > /dev/null 2>&1
2436
2437 # Start the daemons if they were running before
2438 if test $STATUS -eq 0; then
2439 /usr/bin/systemctl start ceph.target > /dev/null 2>&1 || :
2440 fi
2441 fi
2442 exit 0
2443 %endif
2444
2445 %files grafana-dashboards
2446 %if 0%{?suse_version}
2447 %attr(0755,root,root) %dir %{_sysconfdir}/grafana
2448 %attr(0755,root,root) %dir %{_sysconfdir}/grafana/dashboards
2449 %endif
2450 %attr(0755,root,root) %dir %{_sysconfdir}/grafana/dashboards/ceph-dashboard
2451 %config %{_sysconfdir}/grafana/dashboards/ceph-dashboard/*
2452 %doc monitoring/grafana/dashboards/README
2453 %doc monitoring/grafana/README.md
2454
2455 %files prometheus-alerts
2456 %if 0%{?suse_version}
2457 %attr(0755,root,root) %dir %{_sysconfdir}/prometheus
2458 %endif
2459 %attr(0755,root,root) %dir %{_sysconfdir}/prometheus/ceph
2460 %config %{_sysconfdir}/prometheus/ceph/ceph_default_alerts.yml
2461
2462 %changelog