diff --git a/0004-cmake-modules-BuildBoost.cmake.patch b/0004-cmake-modules-BuildBoost.cmake.patch new file mode 100644 index 0000000..644a6c4 --- /dev/null +++ b/0004-cmake-modules-BuildBoost.cmake.patch @@ -0,0 +1,11 @@ +--- ceph-12.2.3/cmake/modules/BuildBoost.cmake.orig 2018-02-21 14:13:32.527899631 -0500 ++++ ceph-12.2.3/cmake/modules/BuildBoost.cmake 2018-02-21 14:14:04.796899631 -0500 +@@ -75,7 +75,7 @@ + set(install_command + ${b2} install) + set(boost_root_dir "${CMAKE_BINARY_DIR}/boost") +- if(EXISTS "${PROJECT_SOURCE_DIR}/src/boost/libs/config/include/boost/config.hpp") ++ if(EXISTS "${PROJECT_SOURCE_DIR}/src/boost/boost/config.hpp") + message(STATUS "boost already in src") + set(source_dir + SOURCE_DIR "${PROJECT_SOURCE_DIR}/src/boost") diff --git a/0005-src-rocksdb-table-block.h.patch b/0005-src-rocksdb-table-block.h.patch new file mode 100644 index 0000000..8acb401 --- /dev/null +++ b/0005-src-rocksdb-table-block.h.patch @@ -0,0 +1,155 @@ +--- ceph-12.2.3/src/rocksdb/table/block.h.orig 2018-02-22 07:49:38.044899631 -0500 ++++ ceph-12.2.3/src/rocksdb/table/block.h 2018-02-22 07:58:55.855899631 -0500 +@@ -65,7 +65,8 @@ + + // Create bitmap and set all the bits to 0 + bitmap_ = new std::atomic[bitmap_size]; +- memset(bitmap_, 0, bitmap_size * kBytesPersEntry); ++ // memset(bitmap_, 0, bitmap_size * kBytesPersEntry); ++ { unsigned i = 0; for (; i < bitmap_size;) bitmap_[i++] = 0; } + + RecordTick(GetStatistics(), READ_AMP_TOTAL_READ_BYTES, + num_bits_needed << bytes_per_bit_pow_); +--- ceph-12.2.3/src/rocksdb/db/c.cc.orig 2018-02-22 08:14:56.033899631 -0500 ++++ ceph-12.2.3/src/rocksdb/db/c.cc 2018-02-22 10:06:39.759899631 -0500 +@@ -1322,11 +1322,6 @@ + b->rep.PutLogData(Slice(blob, len)); + } + +-void rocksdb_writebatch_iterate( +- rocksdb_writebatch_t* b, +- void* state, +- void (*put)(void*, const char* k, size_t klen, const char* v, size_t vlen), +- void (*deleted)(void*, const char* k, size_t klen)) { + class H : public WriteBatch::Handler { + public: + void* state_; +@@ -1339,6 +1334,12 @@ + (*deleted_)(state_, key.data(), key.size()); + } + }; ++ ++void rocksdb_writebatch_iterate( ++ rocksdb_writebatch_t* b, ++ void* state, ++ void (*put)(void*, const char* k, size_t klen, const char* v, size_t vlen), ++ void (*deleted)(void*, const char* k, size_t klen)) { + H handler; + handler.state_ = state; + handler.put_ = put; +@@ -1579,18 +1580,6 @@ + void* state, + void (*put)(void*, const char* k, size_t klen, const char* v, size_t vlen), + void (*deleted)(void*, const char* k, size_t klen)) { +- class H : public WriteBatch::Handler { +- public: +- void* state_; +- void (*put_)(void*, const char* k, size_t klen, const char* v, size_t vlen); +- void (*deleted_)(void*, const char* k, size_t klen); +- virtual void Put(const Slice& key, const Slice& value) override { +- (*put_)(state_, key.data(), key.size(), value.data(), value.size()); +- } +- virtual void Delete(const Slice& key) override { +- (*deleted_)(state_, key.data(), key.size()); +- } +- }; + H handler; + handler.state_ = state; + handler.put_ = put; +@@ -2532,13 +2521,9 @@ + delete filter; + } + +-rocksdb_filterpolicy_t* rocksdb_filterpolicy_create_bloom_format(int bits_per_key, bool original_format) { +- // Make a rocksdb_filterpolicy_t, but override all of its methods so +- // they delegate to a NewBloomFilterPolicy() instead of user +- // supplied C functions. +- struct Wrapper : public rocksdb_filterpolicy_t { ++ struct WrapperFP : public rocksdb_filterpolicy_t { + const FilterPolicy* rep_; +- ~Wrapper() { delete rep_; } ++ ~WrapperFP() { delete rep_; } + const char* Name() const override { return rep_->Name(); } + void CreateFilter(const Slice* keys, int n, + std::string* dst) const override { +@@ -2549,11 +2534,16 @@ + } + static void DoNothing(void*) { } + }; +- Wrapper* wrapper = new Wrapper; ++ ++rocksdb_filterpolicy_t* rocksdb_filterpolicy_create_bloom_format(int bits_per_key, bool original_format) { ++ // Make a rocksdb_filterpolicy_t, but override all of its methods so ++ // they delegate to a NewBloomFilterPolicy() instead of user ++ // supplied C functions. ++ WrapperFP* wrapper = new WrapperFP; + wrapper->rep_ = NewBloomFilterPolicy(bits_per_key, original_format); + wrapper->state_ = nullptr; + wrapper->delete_filter_ = nullptr; +- wrapper->destructor_ = &Wrapper::DoNothing; ++ wrapper->destructor_ = &WrapperFP::DoNothing; + return wrapper; + } + +@@ -2889,10 +2879,9 @@ + delete st; + } + +-rocksdb_slicetransform_t* rocksdb_slicetransform_create_fixed_prefix(size_t prefixLen) { +- struct Wrapper : public rocksdb_slicetransform_t { ++ struct WrapperST : public rocksdb_slicetransform_t { + const SliceTransform* rep_; +- ~Wrapper() { delete rep_; } ++ ~WrapperST() { delete rep_; } + const char* Name() const override { return rep_->Name(); } + Slice Transform(const Slice& src) const override { + return rep_->Transform(src); +@@ -2903,31 +2892,20 @@ + bool InRange(const Slice& src) const override { return rep_->InRange(src); } + static void DoNothing(void*) { } + }; +- Wrapper* wrapper = new Wrapper; ++ ++rocksdb_slicetransform_t* rocksdb_slicetransform_create_fixed_prefix(size_t prefixLen) { ++ WrapperST* wrapper = new WrapperST; + wrapper->rep_ = rocksdb::NewFixedPrefixTransform(prefixLen); + wrapper->state_ = nullptr; +- wrapper->destructor_ = &Wrapper::DoNothing; ++ wrapper->destructor_ = &WrapperST::DoNothing; + return wrapper; + } + + rocksdb_slicetransform_t* rocksdb_slicetransform_create_noop() { +- struct Wrapper : public rocksdb_slicetransform_t { +- const SliceTransform* rep_; +- ~Wrapper() { delete rep_; } +- const char* Name() const override { return rep_->Name(); } +- Slice Transform(const Slice& src) const override { +- return rep_->Transform(src); +- } +- bool InDomain(const Slice& src) const override { +- return rep_->InDomain(src); +- } +- bool InRange(const Slice& src) const override { return rep_->InRange(src); } +- static void DoNothing(void*) { } +- }; +- Wrapper* wrapper = new Wrapper; ++ WrapperST* wrapper = new WrapperST; + wrapper->rep_ = rocksdb::NewNoopTransform(); + wrapper->state_ = nullptr; +- wrapper->destructor_ = &Wrapper::DoNothing; ++ wrapper->destructor_ = &WrapperST::DoNothing; + return wrapper; + } + +--- ceph-12.2.3/src/rocksdb/memtable/inlineskiplist.h.orig 2018-02-22 10:34:06.918899631 -0500 ++++ ceph-12.2.3/src/rocksdb/memtable/inlineskiplist.h 2018-02-22 10:34:44.145899631 -0500 +@@ -279,7 +279,7 @@ + // next_[0]. This is used for passing data from AllocateKey to Insert. + void StashHeight(const int height) { + assert(sizeof(int) <= sizeof(next_[0])); +- memcpy(&next_[0], &height, sizeof(int)); ++ memcpy(static_cast(&next_[0]), &height, sizeof(int)); + } + + // Retrieves the value passed to StashHeight. Undefined after a call diff --git a/ceph.spec b/ceph.spec index 8a8f76a..dd15145 100644 --- a/ceph.spec +++ b/ceph.spec @@ -85,8 +85,8 @@ # main package definition ################################################################################# Name: ceph -Version: 12.2.2 -Release: 3%{?dist} +Version: 12.2.3 +Release: 1%{?dist} %if 0%{?fedora} || 0%{?rhel} Epoch: 1 %endif @@ -106,6 +106,8 @@ Patch001: 0001-src-rocksdb-util-murmurhash.patch # https://bugzilla.redhat.com/show_bug.cgi?id=1474774 Patch002: 0002-cmake-Support-ppc64.patch Patch003: 0003-librbd-Conditionally-import-TrimRequest.cc.patch +Patch004: 0004-cmake-modules-BuildBoost.cmake.patch +Patch005: 0005-src-rocksdb-table-block.h.patch %if 0%{?suse_version} %if 0%{?is_opensuse} ExclusiveArch: x86_64 aarch64 ppc64 ppc64le @@ -272,6 +274,8 @@ Requires: librgw2 = %{_epoch_prefix}%{version}-%{release} %if 0%{with selinux} Requires: ceph-selinux = %{_epoch_prefix}%{version}-%{release} %endif +Requires(post):/sbin/ldconfig +Requires(postun):/sbin/ldconfig Requires: python Requires: python-requests Requires: python-setuptools @@ -354,11 +358,13 @@ Group: System/Filesystems Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} %if 0%{?fedora} || 0%{?rhel} Requires: python-cherrypy +Requires: python-jinja2 Requires: python-werkzeug Requires: pyOpenSSL %endif %if 0%{?suse_version} -Requires: python-CherryPy +Requires: python-CherryPy +Requires: python-jinja2 Requires: python-Werkzeug Requires: python-pyOpenSSL %endif @@ -457,6 +463,7 @@ Requires: gdisk Requires: gptfdisk %endif Requires: parted +Requires: lvm2 %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 @@ -712,7 +719,7 @@ Summary: Ceph benchmarks and test tools %if 0%{?suse_version} Group: System/Benchmark %endif -Requires: ceph-common +Requires: ceph-common = %{_epoch_prefix}%{version}-%{release} Requires: xmlstarlet Requires: jq Requires: socat @@ -888,9 +895,9 @@ cmake .. \ -DWITH_OCF=ON \ %endif %ifarch aarch64 armv7hl mips mipsel ppc ppc64 ppc64le %{ix86} x86_64 - -DWITH_RADOSGW_BEAST_FRONTEND=ON \ + -DWITH_BOOST_CONTEXT=ON \ %else - -DWITH_RADOSGW_BEAST_FRONTEND=OFF \ + -DWITH_BOOST_CONTEXT=OFF \ %endif %ifnarch %{arm} -DWITH_RDMA=OFF \ @@ -930,7 +937,7 @@ mkdir -p %{buildroot}%{_sbindir} install -m 0644 -D src/logrotate.conf %{buildroot}%{_sysconfdir}/logrotate.d/ceph chmod 0644 %{buildroot}%{_docdir}/ceph/sample.ceph.conf install -m 0644 -D COPYING %{buildroot}%{_docdir}/ceph/COPYING -install -m 0644 -D src/90-ceph-osd.conf %{buildroot}%{_sysctldir}/90-ceph-osd.conf +install -m 0644 -D etc/sysctl/90-ceph-osd.conf %{buildroot}%{_sysctldir}/90-ceph-osd.conf # firewall templates and /sbin/mount.ceph symlink %if 0%{?suse_version} @@ -975,13 +982,12 @@ mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd %{_bindir}/crushtool %{_bindir}/monmaptool %{_bindir}/osdmaptool +%{_bindir}/ceph-kvstore-tool %{_bindir}/ceph-run %{_bindir}/ceph-detect-init %{_libexecdir}/systemd/system-preset/50-ceph.preset %{_sbindir}/ceph-create-keys %{_sbindir}/ceph-disk -%{_sbindir}/ceph-volume -%{_sbindir}/ceph-volume-systemd %{_sbindir}/rcceph %dir %{_libexecdir}/ceph %{_libexecdir}/ceph/ceph_common.sh @@ -1010,7 +1016,6 @@ mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd %config %{_sysconfdir}/sysconfig/SuSEfirewall2.d/services/ceph-osd-mds %endif %{_unitdir}/ceph-disk@.service -%{_unitdir}/ceph-volume@.service %{_unitdir}/ceph.target %{python_sitelib}/ceph_detect_init* %{python_sitelib}/ceph_disk* @@ -1021,12 +1026,11 @@ mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd %{_mandir}/man8/ceph-detect-init.8* %{_mandir}/man8/ceph-create-keys.8* %{_mandir}/man8/ceph-disk.8* -%{_mandir}/man8/ceph-volume.8* -%{_mandir}/man8/ceph-volume-systemd.8* %{_mandir}/man8/ceph-run.8* %{_mandir}/man8/crushtool.8* %{_mandir}/man8/osdmaptool.8* %{_mandir}/man8/monmaptool.8* +%{_mandir}/man8/ceph-kvstore-tool.8* #set up placeholder directories %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/tmp %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-osd @@ -1039,12 +1043,11 @@ mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd %if 0%{?suse_version} %fillup_only if [ $1 -eq 1 ] ; then - /usr/bin/systemctl preset ceph-disk@\*.service ceph.target >/dev/null 2>&1 || : +/usr/bin/systemctl preset ceph-disk@\*.service ceph.target >/dev/null 2>&1 || : fi %endif %if 0%{?fedora} || 0%{?rhel} %systemd_post ceph-disk@\*.service ceph.target -%systemd_post ceph-volume@\*.service ceph.target %endif if [ $1 -eq 1 ] ; then /usr/bin/systemctl start ceph.target >/dev/null 2>&1 || : @@ -1056,7 +1059,6 @@ fi %endif %if 0%{?fedora} || 0%{?rhel} %systemd_preun ceph-disk@\*.service ceph.target -%systemd_preun ceph-volume@\*.service ceph.target %endif %postun base @@ -1076,7 +1078,7 @@ if [ $FIRST_ARG -ge 1 ] ; then source $SYSCONF_CEPH fi if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then - /usr/bin/systemctl try-restart ceph-disk@\*.service ceph-volume@\*.service > /dev/null 2>&1 || : + /usr/bin/systemctl try-restart ceph-disk@\*.service > /dev/null 2>&1 || : fi fi @@ -1280,6 +1282,7 @@ fi %files mon %{_bindir}/ceph-mon %{_bindir}/ceph-rest-api +%{_bindir}/ceph-monstore-tool %{_mandir}/man8/ceph-mon.8* %{_mandir}/man8/ceph-rest-api.8* %{python_sitelib}/ceph_rest_api.py* @@ -1448,26 +1451,32 @@ fi %{_bindir}/ceph-clsinfo %{_bindir}/ceph-bluestore-tool %{_bindir}/ceph-objectstore-tool +%{_bindir}/ceph-osdomap-tool %{_bindir}/ceph-osd %{_libexecdir}/ceph/ceph-osd-prestart.sh +%{_sbindir}/ceph-volume +%{_sbindir}/ceph-volume-systemd %dir %{_udevrulesdir} %{_udevrulesdir}/60-ceph-by-parttypeuuid.rules %{_udevrulesdir}/95-ceph-osd.rules %{_mandir}/man8/ceph-clsinfo.8* %{_mandir}/man8/ceph-osd.8* %{_mandir}/man8/ceph-bluestore-tool.8* +%{_mandir}/man8/ceph-volume.8* +%{_mandir}/man8/ceph-volume-systemd.8* %if ( ( 0%{?rhel} && 0%{?rhel} <= 7) && ! 0%{?centos} ) %attr(0755,-,-) %{_sysconfdir}/cron.hourly/subman %endif %{_unitdir}/ceph-osd@.service %{_unitdir}/ceph-osd.target +%{_unitdir}/ceph-volume@.service %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/osd %config(noreplace) %{_sysctldir}/90-ceph-osd.conf %post osd %if 0%{?suse_version} if [ $1 -eq 1 ] ; then - /usr/bin/systemctl preset ceph-osd@\*.service ceph-osd.target >/dev/null 2>&1 || : + /usr/bin/systemctl preset ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target >/dev/null 2>&1 || : fi %if 0%{?sysctl_apply} %sysctl_apply 90-ceph-osd.conf @@ -1476,7 +1485,7 @@ fi %endif %endif %if 0%{?fedora} || 0%{?rhel} -%systemd_post ceph-osd@\*.service ceph-osd.target +%systemd_post ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target %endif if [ $1 -eq 1 ] ; then /usr/bin/systemctl start ceph-osd.target >/dev/null 2>&1 || : @@ -1484,20 +1493,20 @@ fi %preun osd %if 0%{?suse_version} -%service_del_preun ceph-osd@\*.service ceph-osd.target +%service_del_preun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target %endif %if 0%{?fedora} || 0%{?rhel} -%systemd_preun ceph-osd@\*.service ceph-osd.target +%systemd_preun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target %endif %postun osd test -n "$FIRST_ARG" || FIRST_ARG=$1 %if 0%{?suse_version} DISABLE_RESTART_ON_UPDATE="yes" -%service_del_postun ceph-osd@\*.service ceph-osd.target +%service_del_postun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target %endif %if 0%{?fedora} || 0%{?rhel} -%systemd_postun ceph-osd@\*.service ceph-osd.target +%systemd_postun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target %endif if [ $FIRST_ARG -ge 1 ] ; then # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to @@ -1507,7 +1516,7 @@ if [ $FIRST_ARG -ge 1 ] ; then source $SYSCONF_CEPH fi if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then - /usr/bin/systemctl try-restart ceph-osd@\*.service > /dev/null 2>&1 || : + /usr/bin/systemctl try-restart ceph-osd@\*.service ceph-volume@\*.service > /dev/null 2>&1 || : fi fi @@ -1517,10 +1526,11 @@ fi %dir %{_prefix}/lib/ocf %dir %{_prefix}/lib/ocf/resource.d %dir %{_prefix}/lib/ocf/resource.d/ceph -%{_prefix}/lib/ocf/resource.d/ceph/rbd +%attr(0755,-,-) %{_prefix}/lib/ocf/resource.d/ceph/rbd %endif +%ldconfig_scriptlets -n librados2 %files -n librados2 %{_libdir}/librados.so.* %dir %{_libdir}/ceph @@ -1556,6 +1566,7 @@ fi %{python3_sitearch}/rados.cpython*.so %{python3_sitearch}/rados-*.egg-info +%ldconfig_scriptlets -n libradosstriper1 %files -n libradosstriper1 %{_libdir}/libradosstriper.so.* @@ -1565,6 +1576,7 @@ fi %{_includedir}/radosstriper/libradosstriper.hpp %{_libdir}/libradosstriper.so +%ldconfig_scriptlets -n librbd1 %files -n librbd1 %{_libdir}/librbd.so.* %if %{with lttng} @@ -1581,6 +1593,7 @@ fi %{_libdir}/librbd_tp.so %endif +%ldconfig_scriptlets -n librgw2 %files -n librgw2 %{_libdir}/librgw.so.* @@ -1606,6 +1619,7 @@ fi %{python3_sitearch}/rbd.cpython*.so %{python3_sitearch}/rbd-*.egg-info +%ldconfig_scriptlets -n libcephfs2 %files -n libcephfs2 %{_libdir}/libcephfs.so.* @@ -1660,9 +1674,6 @@ fi %{_bindir}/ceph_tpbench %{_bindir}/ceph_xattr_bench %{_bindir}/ceph-coverage -%{_bindir}/ceph-monstore-tool -%{_bindir}/ceph-osdomap-tool -%{_bindir}/ceph-kvstore-tool %{_bindir}/ceph-debugpack %{_mandir}/man8/ceph-debugpack.8* %dir %{_libdir}/ceph @@ -1670,6 +1681,7 @@ fi %endif %if 0%{with cephfs_java} +%ldconfig_scriptlets -n libcephfs_jni1 %files -n libcephfs_jni1 %{_libdir}/libcephfs_jni.so.* @@ -1783,6 +1795,9 @@ exit 0 %changelog +* Wed Feb 21 2018 Kaleb S. KEITHLEY - 1:12.2.3-1 +- New release (1:12.2.3-1) + * Thu Feb 15 2018 Kaleb S. KEITHLEY - 1:12.2.2-3 - no ldconfig in F28 diff --git a/sources b/sources index de58d58..bc2f72b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (ceph-12.2.2.tar.gz) = 89b166dc4b58e0110ebe0147eef9f47e1090ccee01702b3f72cfbdca856d02bf03b2663de9e88c84b21a2a61f8f92211e217a05b8bdcf7d5de3158adbe49db88 +SHA512 (ceph-12.2.3.tar.gz) = 3cdc105a64a68b07f55e9ea5cb8880e3eac882937313a2a8e454e34325443cee1675413d3e2148f944ecaf32be35a1384bd0a662ca58bdb2d2ab3c9eff518cd2