From dc8a12bedac1d449a52352f86887605c71c0ebd5 Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Thu, 16 Feb 2012 21:39:09 -0500 Subject: [PATCH 1/3] update to 0.41, fix ftbfs, rebuild against gperftools --- ...ment-out-unused-code-in-dump_pop_map.patch | 33 +++++++++ ceph-0.41-compile-fixes.patch | 67 +++++++++++++++++++ ceph-init-fix.patch | 11 +-- ceph.spec | 15 ++++- sources | 2 +- 5 files changed, 119 insertions(+), 9 deletions(-) create mode 100644 ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch create mode 100644 ceph-0.41-compile-fixes.patch diff --git a/ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch b/ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch new file mode 100644 index 0000000..424f743 --- /dev/null +++ b/ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch @@ -0,0 +1,33 @@ +diff -up ceph-0.39/src/mds/MDBalancer.cc.fix ceph-0.39/src/mds/MDBalancer.cc +--- ceph-0.39/src/mds/MDBalancer.cc.fix 2012-02-16 12:23:26.582302711 -0500 ++++ ceph-0.39/src/mds/MDBalancer.cc 2012-02-16 12:31:44.386396603 -0500 +@@ -1155,6 +1155,7 @@ void MDBalancer::dump_pop_map() + { + return; // this is dumb + ++/* + + char fn[32]; + snprintf(fn, sizeof(fn), "popdump.%d.mds%d", beat_epoch, mds->get_nodeid()); +@@ -1174,10 +1175,9 @@ void MDBalancer::dump_pop_map() + iq.pop_front(); + + // pop stats +- /*for (int a=0; apopularity[a].pop[b].get(now) << "\t"; +- */ ++ //for (int a=0; apopularity[a].pop[b].get(now) << "\t"; + + // recurse, depth-first. + if (in->is_dir()) { +@@ -1214,6 +1214,7 @@ void MDBalancer::dump_pop_map() + } + + myfile.close(); ++*/ + } + + diff --git a/ceph-0.41-compile-fixes.patch b/ceph-0.41-compile-fixes.patch new file mode 100644 index 0000000..7f00bd6 --- /dev/null +++ b/ceph-0.41-compile-fixes.patch @@ -0,0 +1,67 @@ +diff -up ceph-0.41/src/cephfs.cc.compilefix ceph-0.41/src/cephfs.cc +--- ceph-0.41/src/cephfs.cc.compilefix 2012-02-16 21:08:19.983652818 -0500 ++++ ceph-0.41/src/cephfs.cc 2012-02-16 21:08:31.917550083 -0500 +@@ -24,6 +24,7 @@ + #include + #include + #include ++#include + #include "client/ioctl.h" + + using namespace std; +diff -up ceph-0.41/src/common/safe_io.h.compilefix ceph-0.41/src/common/safe_io.h +--- ceph-0.41/src/common/safe_io.h.compilefix 2012-02-16 12:53:31.456514774 -0500 ++++ ceph-0.41/src/common/safe_io.h 2012-02-16 12:54:00.045233017 -0500 +@@ -16,6 +16,7 @@ + #define CEPH_SAFE_IO + + #include "common/compiler_extensions.h" ++#include + + #ifdef __cplusplus + extern "C" { +diff -up ceph-0.41/src/osd/PG.cc.compilefix ceph-0.41/src/osd/PG.cc +--- ceph-0.41/src/osd/PG.cc.compilefix 2012-02-16 20:58:21.039559849 -0500 ++++ ceph-0.41/src/osd/PG.cc 2012-02-16 20:59:07.920149937 -0500 +@@ -4830,13 +4830,13 @@ bool PG::PriorSet::affected_by_map(const + } + + // did a down osd in cur get (re)marked as lost? +- map::const_iterator p = blocked_by.find(o); +- if (p != blocked_by.end()) { ++ map::const_iterator r = blocked_by.find(o); ++ if (r != blocked_by.end()) { + if (!osdmap->exists(o)) { + dout(10) << "affected_by_map osd." << o << " no longer exists" << dendl; + return true; + } +- if (osdmap->get_info(o).lost_at != p->second) { ++ if (osdmap->get_info(o).lost_at != r->second) { + dout(10) << "affected_by_map osd." << o << " (re)marked as lost" << dendl; + return true; + } +diff -up ceph-0.41/src/osd/ReplicatedPG.cc.compilefix ceph-0.41/src/osd/ReplicatedPG.cc +--- ceph-0.41/src/osd/ReplicatedPG.cc.compilefix 2012-02-16 21:03:26.140892128 -0500 ++++ ceph-0.41/src/osd/ReplicatedPG.cc 2012-02-16 21:04:45.190200945 -0500 +@@ -5436,8 +5436,8 @@ int ReplicatedPG::recover_replicas(int m + } + + dout(10) << __func__ << ": recover_object_replicas(" << soid << ")" << dendl; +- map::const_iterator p = m.missing.find(soid); +- started += recover_object_replicas(soid, p->second.need); ++ map::const_iterator r = m.missing.find(soid); ++ started += recover_object_replicas(soid, r->second.need); + } + } + +diff -up ceph-0.41/src/test/system/systest_runnable.cc.compilefix ceph-0.41/src/test/system/systest_runnable.cc +--- ceph-0.41/src/test/system/systest_runnable.cc.compilefix 2012-02-16 12:54:35.430884275 -0500 ++++ ceph-0.41/src/test/system/systest_runnable.cc 2012-02-16 12:54:45.923780862 -0500 +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include + #include + + #if defined(__FreeBSD__) diff --git a/ceph-init-fix.patch b/ceph-init-fix.patch index fb2b252..3d22e19 100644 --- a/ceph-init-fix.patch +++ b/ceph-init-fix.patch @@ -1,5 +1,6 @@ ---- ceph-0.21.1/src/init-ceph.in.orig 2010-07-29 15:16:49.000000000 -0500 -+++ ceph-0.21.1/src/init-ceph.in 2010-08-26 14:58:25.328581937 -0500 +diff -up ceph-0.41/src/init-ceph.in.init ceph-0.41/src/init-ceph.in +--- ceph-0.41/src/init-ceph.in.init 2012-01-17 15:33:20.000000000 -0500 ++++ ceph-0.41/src/init-ceph.in 2012-02-16 12:48:50.887279921 -0500 @@ -1,11 +1,11 @@ #!/bin/sh # Start/stop ceph daemons @@ -8,10 +9,10 @@ ### BEGIN INIT INFO # Provides: ceph --# Default-Start: 2 3 4 5 +-# Default-Start: 2 3 5 -# Default-Stop: 0 1 6 -+# Default-Start: -+# Default-Stop: ++# Default-Start: ++# Default-Stop: # Required-Start: $remote_fs $named $network $time # Required-Stop: $remote_fs $named $network $time # Short-Description: Start Ceph distributed file system daemons at boot time diff --git a/ceph.spec b/ceph.spec index 43ab4d0..20bff01 100644 --- a/ceph.spec +++ b/ceph.spec @@ -1,19 +1,21 @@ Name: ceph -Version: 0.39 +Version: 0.41 Release: 1%{?dist} Summary: User space components of the Ceph file system License: LGPLv2 Group: System Environment/Base URL: http://ceph.newdream.net/ -Source: http://ceph.newdream.net/download/%{name}-%{version}.tar.gz +Source: http://ceph.newdream.net/download/%{name}-%{version}.tar.bz2 Patch0: ceph-init-fix.patch Patch1: ceph.logrotate.patch +Patch2: ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch +Patch3: ceph-0.41-compile-fixes.patch BuildRequires: fuse-devel, libtool, libtool-ltdl-devel, boost-devel, BuildRequires: libedit-devel, fuse-devel, git, perl, gdbm, # google-perftools is not available on these: %ifnarch ppc64 s390 s390x -BuildRequires: google-perftools-devel +BuildRequires: gperftools-devel %endif BuildRequires: cryptopp-devel, libatomic_ops-devel, gcc-c++ BuildRequires: pkgconfig, libcurl-devel, keyutils-libs-devel @@ -80,6 +82,8 @@ file system. %setup -q %patch0 -p1 -b .init %patch1 -p0 +%patch2 -p1 -b .unusedfix +%patch3 -p1 -b .compilefix %build ./autogen.sh @@ -235,6 +239,11 @@ fi %{_bindir}/boto_tool %changelog +* Thu Feb 16 2012 Tom Callaway 0.41-1 +- update to 0.41 +- fix issues preventing build +- rebuild against gperftools + * Sat Dec 03 2011 David Nalley 0.38-1 - updating to upstream 0.39 diff --git a/sources b/sources index 8fec600..470e201 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -8dcc078604c54d10085b6990ef554738 ceph-0.39.tar.gz +12730a25f7c82549a08b0d8b8c09d69f ceph-0.41.tar.bz2 From 3cf1ae6df2d735b9aec6d0b136325138592ea40a Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Tue, 28 Feb 2012 12:01:56 -0600 Subject: [PATCH 2/3] - Rebuilt for c++ ABI breakage --- ceph.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ceph.spec b/ceph.spec index 20bff01..0810e37 100644 --- a/ceph.spec +++ b/ceph.spec @@ -1,6 +1,6 @@ Name: ceph Version: 0.41 -Release: 1%{?dist} +Release: 2%{?dist} Summary: User space components of the Ceph file system License: LGPLv2 Group: System Environment/Base @@ -239,6 +239,9 @@ fi %{_bindir}/boto_tool %changelog +* Tue Feb 28 2012 Fedora Release Engineering - 0.41-2 +- Rebuilt for c++ ABI breakage + * Thu Feb 16 2012 Tom Callaway 0.41-1 - update to 0.41 - fix issues preventing build From f32a9e4df73790644713a329d8555374130af6f8 Mon Sep 17 00:00:00 2001 From: Jonathan Dieter Date: Tue, 6 Mar 2012 16:58:21 +0200 Subject: [PATCH 3/3] Update to upstream 0.43 and drop unnecessary patches Signed-off-by: Jonathan Dieter --- .gitignore | 1 + ...ment-out-unused-code-in-dump_pop_map.patch | 33 --------- ceph-0.41-compile-fixes.patch | 67 ------------------- ceph.spec | 22 +++--- sources | 2 +- 5 files changed, 15 insertions(+), 110 deletions(-) delete mode 100644 ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch delete mode 100644 ceph-0.41-compile-fixes.patch diff --git a/.gitignore b/.gitignore index 2404c22..939ad6c 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ ceph-0.20.tar.gz /ceph-0.31.tar.gz /ceph-0.37.tar.gz /ceph-0.39.tar.gz +/ceph-0.43.tar.bz2 diff --git a/ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch b/ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch deleted file mode 100644 index 424f743..0000000 --- a/ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch +++ /dev/null @@ -1,33 +0,0 @@ -diff -up ceph-0.39/src/mds/MDBalancer.cc.fix ceph-0.39/src/mds/MDBalancer.cc ---- ceph-0.39/src/mds/MDBalancer.cc.fix 2012-02-16 12:23:26.582302711 -0500 -+++ ceph-0.39/src/mds/MDBalancer.cc 2012-02-16 12:31:44.386396603 -0500 -@@ -1155,6 +1155,7 @@ void MDBalancer::dump_pop_map() - { - return; // this is dumb - -+/* - - char fn[32]; - snprintf(fn, sizeof(fn), "popdump.%d.mds%d", beat_epoch, mds->get_nodeid()); -@@ -1174,10 +1175,9 @@ void MDBalancer::dump_pop_map() - iq.pop_front(); - - // pop stats -- /*for (int a=0; apopularity[a].pop[b].get(now) << "\t"; -- */ -+ //for (int a=0; apopularity[a].pop[b].get(now) << "\t"; - - // recurse, depth-first. - if (in->is_dir()) { -@@ -1214,6 +1214,7 @@ void MDBalancer::dump_pop_map() - } - - myfile.close(); -+*/ - } - - diff --git a/ceph-0.41-compile-fixes.patch b/ceph-0.41-compile-fixes.patch deleted file mode 100644 index 7f00bd6..0000000 --- a/ceph-0.41-compile-fixes.patch +++ /dev/null @@ -1,67 +0,0 @@ -diff -up ceph-0.41/src/cephfs.cc.compilefix ceph-0.41/src/cephfs.cc ---- ceph-0.41/src/cephfs.cc.compilefix 2012-02-16 21:08:19.983652818 -0500 -+++ ceph-0.41/src/cephfs.cc 2012-02-16 21:08:31.917550083 -0500 -@@ -24,6 +24,7 @@ - #include - #include - #include -+#include - #include "client/ioctl.h" - - using namespace std; -diff -up ceph-0.41/src/common/safe_io.h.compilefix ceph-0.41/src/common/safe_io.h ---- ceph-0.41/src/common/safe_io.h.compilefix 2012-02-16 12:53:31.456514774 -0500 -+++ ceph-0.41/src/common/safe_io.h 2012-02-16 12:54:00.045233017 -0500 -@@ -16,6 +16,7 @@ - #define CEPH_SAFE_IO - - #include "common/compiler_extensions.h" -+#include - - #ifdef __cplusplus - extern "C" { -diff -up ceph-0.41/src/osd/PG.cc.compilefix ceph-0.41/src/osd/PG.cc ---- ceph-0.41/src/osd/PG.cc.compilefix 2012-02-16 20:58:21.039559849 -0500 -+++ ceph-0.41/src/osd/PG.cc 2012-02-16 20:59:07.920149937 -0500 -@@ -4830,13 +4830,13 @@ bool PG::PriorSet::affected_by_map(const - } - - // did a down osd in cur get (re)marked as lost? -- map::const_iterator p = blocked_by.find(o); -- if (p != blocked_by.end()) { -+ map::const_iterator r = blocked_by.find(o); -+ if (r != blocked_by.end()) { - if (!osdmap->exists(o)) { - dout(10) << "affected_by_map osd." << o << " no longer exists" << dendl; - return true; - } -- if (osdmap->get_info(o).lost_at != p->second) { -+ if (osdmap->get_info(o).lost_at != r->second) { - dout(10) << "affected_by_map osd." << o << " (re)marked as lost" << dendl; - return true; - } -diff -up ceph-0.41/src/osd/ReplicatedPG.cc.compilefix ceph-0.41/src/osd/ReplicatedPG.cc ---- ceph-0.41/src/osd/ReplicatedPG.cc.compilefix 2012-02-16 21:03:26.140892128 -0500 -+++ ceph-0.41/src/osd/ReplicatedPG.cc 2012-02-16 21:04:45.190200945 -0500 -@@ -5436,8 +5436,8 @@ int ReplicatedPG::recover_replicas(int m - } - - dout(10) << __func__ << ": recover_object_replicas(" << soid << ")" << dendl; -- map::const_iterator p = m.missing.find(soid); -- started += recover_object_replicas(soid, p->second.need); -+ map::const_iterator r = m.missing.find(soid); -+ started += recover_object_replicas(soid, r->second.need); - } - } - -diff -up ceph-0.41/src/test/system/systest_runnable.cc.compilefix ceph-0.41/src/test/system/systest_runnable.cc ---- ceph-0.41/src/test/system/systest_runnable.cc.compilefix 2012-02-16 12:54:35.430884275 -0500 -+++ ceph-0.41/src/test/system/systest_runnable.cc 2012-02-16 12:54:45.923780862 -0500 -@@ -28,6 +28,7 @@ - #include - #include - #include -+#include - #include - - #if defined(__FreeBSD__) diff --git a/ceph.spec b/ceph.spec index 0810e37..7fd71e6 100644 --- a/ceph.spec +++ b/ceph.spec @@ -1,6 +1,6 @@ Name: ceph -Version: 0.41 -Release: 2%{?dist} +Version: 0.43 +Release: 1%{?dist} Summary: User space components of the Ceph file system License: LGPLv2 Group: System Environment/Base @@ -9,10 +9,8 @@ URL: http://ceph.newdream.net/ Source: http://ceph.newdream.net/download/%{name}-%{version}.tar.bz2 Patch0: ceph-init-fix.patch Patch1: ceph.logrotate.patch -Patch2: ceph-0.39-comment-out-unused-code-in-dump_pop_map.patch -Patch3: ceph-0.41-compile-fixes.patch BuildRequires: fuse-devel, libtool, libtool-ltdl-devel, boost-devel, -BuildRequires: libedit-devel, fuse-devel, git, perl, gdbm, +BuildRequires: libedit-devel, fuse-devel, git, perl, gdbm, libaio-devel, # google-perftools is not available on these: %ifnarch ppc64 s390 s390x BuildRequires: gperftools-devel @@ -81,9 +79,7 @@ file system. %prep %setup -q %patch0 -p1 -b .init -%patch1 -p0 -%patch2 -p1 -b .unusedfix -%patch3 -p1 -b .compilefix +%patch1 -p0 %build ./autogen.sh @@ -108,6 +104,7 @@ mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/ceph/ mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/log/ceph/stat mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/ceph mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/bash_completion.d + %clean rm -rf $RPM_BUILD_ROOT @@ -150,6 +147,7 @@ fi %{_bindir}/rbd %{_bindir}/ceph-debugpack %{_bindir}/ceph-coverage +%{_bindir}/ceph-dencoder %{_initrddir}/ceph %{_libdir}/libcephfs.so.* %{_libdir}/librados.so.* @@ -185,7 +183,8 @@ fi %{_mandir}/man8/rbd.8* %{_mandir}/man8/ceph-authtool.8* %{_mandir}/man8/ceph-debugpack.8* -%{_mandir}/man8/ceph-clsinfo.8.gz +%{_mandir}/man8/ceph-clsinfo.8* +%{_mandir}/man8/ceph-dencoder.8* %{python_sitelib}/rados.py* %{python_sitelib}/rgw.py* %{python_sitelib}/rbd.py* @@ -239,6 +238,11 @@ fi %{_bindir}/boto_tool %changelog +* Mon Mar 5 2012 Jonathan Dieter - 0.43-1 +- Update to 0.43 +- Remove upstreamed compile fixes patch +- Remove obsoleted dump_pop patch + * Tue Feb 28 2012 Fedora Release Engineering - 0.41-2 - Rebuilt for c++ ABI breakage diff --git a/sources b/sources index 470e201..ef78d9b 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -12730a25f7c82549a08b0d8b8c09d69f ceph-0.41.tar.bz2 +037d4aa271ac7f4bbff2370a87d35e90 ceph-0.43.tar.bz2