]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
7 years agocommon: make it safe to call env_to_vec multiple times
Jeff Layton [Wed, 11 Oct 2017 15:16:38 +0000 (11:16 -0400)]
common: make it safe to call env_to_vec multiple times

After it has been called once and we have outstanding CephContexts with
pointers into str_vec, we can't call get_str_vec on it again.

Add a static local mutex to protect access to str_vec.

Tracker: http://tracker.ceph.com/issues/21512
Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 90e898de5f4b8d22f1a6d0e2aedf9e8c50cf72d5)

7 years agolockdep: fix Mutex tests to disable lockdep properly
Jeff Layton [Thu, 14 Sep 2017 13:28:34 +0000 (09:28 -0400)]
lockdep: fix Mutex tests to disable lockdep properly

...and make g_lockdep a bool.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 0cd0bd778a6149d3e2fe657060e223be3675aed7)

7 years agoclient: test shutdown race
Jeff Layton [Thu, 14 Sep 2017 13:28:33 +0000 (09:28 -0400)]
client: test shutdown race

Spawn threads that bring up a bunch of ceph_mounts with individual
CephContext objects, and then tear them down in parallel.

Tracker: http://tracker.ceph.com/issues/20988
Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 8252f3168a1bc90add7f7515c549e9eecffa54b7)

7 years agoclient: fix signed/unsigned comparison compiler warning
Jeff Layton [Thu, 14 Sep 2017 16:22:52 +0000 (12:22 -0400)]
client: fix signed/unsigned comparison compiler warning

The build says:

src/client/Client.cc: In member function ‘void Client::trim_caps(MetaSession*, int)’:
src/client/Client.cc:4121:22: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
   if (s->caps.size() > max)
       ~~~~~~~~~~~~~~~^~~~~

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit e057b6770b5545f327990cbaf17e7a391e3e8a50)

7 years agolockdep: fix races with concurrent lockdep teardown
Jeff Layton [Thu, 14 Sep 2017 13:28:34 +0000 (09:28 -0400)]
lockdep: fix races with concurrent lockdep teardown

If the cct is unregistered while other threads are flogging mutexes,
then we can hit all sorts of bugs. Ensure that we handle that
situation sanely, by checking that g_lockdep is still set after
we take the lockdep_mutex.

Also, remove an assertion from lockdep_unregister, and just turn it into
an immediate return. It's possible to have a call to
lockdep_unregister_ceph_context, and then a call to
lockdep_register_ceph_context while a mutex is being held by another
task.

In that case, it's possible the lock does not exist in the map
when we go to unregister it. That's not a bug though, just a natural
consequence of that series of actions.

Tracker: http://tracker.ceph.com/issues/20988
Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 75f41a95782a7ee83a243d91963e8d591402f8a6)

7 years agolockdep: don't take lockdep_mutex twice for new lock registrations
Jeff Layton [Thu, 14 Sep 2017 13:28:34 +0000 (09:28 -0400)]
lockdep: don't take lockdep_mutex twice for new lock registrations

We can do it under the same mutex, which should be more efficient.

Signed-off-by: Jeff Layton <jlayton@redhat.com>
(cherry picked from commit 01863bb6fb62ea89aa3e21e43bf4dc4f3da9cfcb)

7 years agoMerge pull request #19257 from ifed01/wip-ifed-rocksdb-fix
Sage Weil [Mon, 22 Jan 2018 15:02:32 +0000 (09:02 -0600)]
Merge pull request #19257 from ifed01/wip-ifed-rocksdb-fix

luminous: rocksdb: fixes early metadata spill over to slow device in

7 years agoMerge pull request #19071 from smithfarm/wip-22181-luminous
Sage Weil [Fri, 19 Jan 2018 21:10:19 +0000 (15:10 -0600)]
Merge pull request #19071 from smithfarm/wip-22181-luminous

luminous: rgw segfaults after running radosgw-admin data sync init

Reviewed-by: Casey Bodley <cbodley@redhat.com>
Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
7 years agoMerge pull request #19077 from smithfarm/wip-22171-luminous
Sage Weil [Fri, 19 Jan 2018 21:09:45 +0000 (15:09 -0600)]
Merge pull request #19077 from smithfarm/wip-22171-luminous

luminous: rgw: log keystone errors at a higher level

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19810 from adamemerson/wip-luminous-21901
Casey Bodley [Fri, 19 Jan 2018 21:08:03 +0000 (16:08 -0500)]
Merge pull request #19810 from adamemerson/wip-luminous-21901

luminous: rgw: bucket policy evaluation logical error

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19847 from adamemerson/wip-22541-luminous
Casey Bodley [Fri, 19 Jan 2018 21:06:08 +0000 (16:06 -0500)]
Merge pull request #19847 from adamemerson/wip-22541-luminous

luminous: rgw: put bucket policy panics RGW process

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19785 from linuxbox2/luminous-22410
Yuri Weinstein [Fri, 19 Jan 2018 21:03:58 +0000 (13:03 -0800)]
Merge pull request #19785 from linuxbox2/luminous-22410

luminous: rgw: fix chained cache invalidation to prevent cache size growth

Reviewed-by: Adam Emerson <aemerson@redhat.com>
7 years agoMerge pull request #19788 from adamemerson/wip-luminous-cache
Yuri Weinstein [Fri, 19 Jan 2018 21:02:34 +0000 (13:02 -0800)]
Merge pull request #19788 from adamemerson/wip-luminous-cache

luminous: rgw: Random 500 errors in Swift PutObject (needs cache fixes)

Reviewed-by: Nathan Cutler <ncutler@suse.com>
Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
7 years agoMerge pull request #19053 from shinobu-x/wip-22187-luminous
Casey Bodley [Fri, 19 Jan 2018 21:01:40 +0000 (16:01 -0500)]
Merge pull request #19053 from shinobu-x/wip-22187-luminous

luminous: rgw: add cors header rule check in cors option request

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19819 from adamemerson/wip-backport-22601
Yuri Weinstein [Fri, 19 Jan 2018 21:01:10 +0000 (13:01 -0800)]
Merge pull request #19819 from adamemerson/wip-backport-22601

luminous: rgw: S3 API Policy Conditions IpAddress and NotIpAddress do not work

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
Reviewed-by: Nathan Cutler <ncutler@suse.com>
7 years agoMerge pull request #19050 from shinobu-x/wip-22184-luminous
Casey Bodley [Fri, 19 Jan 2018 21:00:56 +0000 (16:00 -0500)]
Merge pull request #19050 from shinobu-x/wip-22184-luminous

luminous: Dynamic bucket indexing, resharding and tenants seems to be broken

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19085 from shinobu-x/wip-22215-luminous
Casey Bodley [Fri, 19 Jan 2018 21:00:38 +0000 (16:00 -0500)]
Merge pull request #19085 from shinobu-x/wip-22215-luminous

luminous: rgw: bucket index object not deleted after radosgw-admin bucket rm --purge-objects --bypass-gc

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #18870 from shinobu-x/wip-21949-luminous
Casey Bodley [Fri, 19 Jan 2018 20:54:24 +0000 (15:54 -0500)]
Merge pull request #18870 from shinobu-x/wip-21949-luminous

luminous: rgw: null instance mtime incorrect when enable versioning

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #18764 from smithfarm/wip-22017-luminous
Casey Bodley [Fri, 19 Jan 2018 20:54:05 +0000 (15:54 -0500)]
Merge pull request #18764 from smithfarm/wip-22017-luminous

luminous: rgw: Segmentation fault when starting radosgw after reverting .rgw.root

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #18765 from smithfarm/wip-22024-luminous
Casey Bodley [Fri, 19 Jan 2018 20:53:53 +0000 (15:53 -0500)]
Merge pull request #18765 from smithfarm/wip-22024-luminous

luminous: RGWCrashError: RGW will crash if a putting lc config request does not include an ID tag in the request xml

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #18766 from smithfarm/wip-22021-luminous
Casey Bodley [Fri, 19 Jan 2018 20:53:40 +0000 (15:53 -0500)]
Merge pull request #18766 from smithfarm/wip-22021-luminous

luminous: rgw: modify s3 type subuser access permission fail

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #18867 from shinobu-x/wip-22027-luminous
Casey Bodley [Fri, 19 Jan 2018 20:53:28 +0000 (15:53 -0500)]
Merge pull request #18867 from shinobu-x/wip-22027-luminous

luminous: multisite: destination zone does not compress synced objects

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #18868 from shinobu-x/wip-22026-luminous
Yuri Weinstein [Fri, 19 Jan 2018 20:48:23 +0000 (12:48 -0800)]
Merge pull request #18868 from shinobu-x/wip-22026-luminous

luminous: Policy parser may or may not dereference uninitialized boost::optional sometimes

Reviewed-by: Adam Emerson <aemerson@redhat.com>
7 years agoMerge pull request #19538 from shinobu-x/wip-22434-luminous
Casey Bodley [Fri, 19 Jan 2018 20:46:58 +0000 (15:46 -0500)]
Merge pull request #19538 from shinobu-x/wip-22434-luminous

luminous: rgw: user stats increased after bucket reshard

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19489 from dplyakin/luminous-get-website-error-code
Casey Bodley [Fri, 19 Jan 2018 20:46:21 +0000 (15:46 -0500)]
Merge pull request #19489 from dplyakin/luminous-get-website-error-code

luminous: rgw: fix GET website response error code

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19090 from pdvian/wip-22179-luminous
Yuri Weinstein [Fri, 19 Jan 2018 20:44:55 +0000 (12:44 -0800)]
Merge pull request #19090 from pdvian/wip-22179-luminous

luminous: rgw: Fix swift object expiry not deleting objects

Reviewed-by: Casey Bodley <cbodley@redhat.com>
Reviewed-by: Amit Kumar <amitkuma@redhat.com>
7 years agoMerge pull request #19434 from cbodley/wip-luminous-pr-16807
Yuri Weinstein [Fri, 19 Jan 2018 20:43:07 +0000 (12:43 -0800)]
Merge pull request #19434 from cbodley/wip-luminous-pr-16807

luminous: rgw: revert PR #16807

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
7 years agoMerge pull request #19502 from shinobu-x/wip-22397-luminous
Yuri Weinstein [Fri, 19 Jan 2018 20:41:22 +0000 (12:41 -0800)]
Merge pull request #19502 from shinobu-x/wip-22397-luminous

luminous: rgw: radosgw-admin reshard command argument error.

Reviewed-by: Orit Wasserman <owasserm@redhat.com>
7 years agoMerge pull request #19506 from shinobu-x/wip-22388-luminous
Yuri Weinstein [Fri, 19 Jan 2018 20:40:45 +0000 (12:40 -0800)]
Merge pull request #19506 from shinobu-x/wip-22388-luminous

luminous: rgw: 501 is returned When init multipart is using V4 signature and chunk encoding

Reviewed-by: Radoslaw Zarzynski <rzarzyns@redhat.com
7 years agoMerge pull request #19929 from zmc/wip-luminous-prom-pg_deep
John Spray [Thu, 18 Jan 2018 10:02:00 +0000 (10:02 +0000)]
Merge pull request #19929 from zmc/wip-luminous-prom-pg_deep

luminous: mgr/prometheus: add missing 'deep' state to PG_STATES in ceph-mgr pro…

Reviewed-by: John Spray <john.spray@redhat.com>
7 years agoMerge pull request #19943 from dillaman/wip-22676-luminous
Jason Dillaman [Thu, 18 Jan 2018 01:13:36 +0000 (20:13 -0500)]
Merge pull request #19943 from dillaman/wip-22676-luminous

luminous: cls/rbd: remove incompatible group features from partial implementation

Reviewed-by: Mykola Golub <mgolub@suse.com>
7 years agoqa/suites: filter out cls_rbd tests against unsupported methods 19943/head
Jason Dillaman [Wed, 17 Jan 2018 22:21:47 +0000 (17:21 -0500)]
qa/suites: filter out cls_rbd tests against unsupported methods

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agoMerge pull request #18865 from shinobu-x/wip-21631-luminous
Abhishek L [Wed, 17 Jan 2018 22:12:37 +0000 (23:12 +0100)]
Merge pull request #18865 from shinobu-x/wip-21631-luminous

luminous: doc: remove region from "INSTALL CEPH OBJECT GATEWAY"

Reviewed-By: Abhishek Lekshmanan <abhishek@suse.com>
7 years agocls/rbd: remove incompatible group features from partial implementation
Jason Dillaman [Sat, 13 Jan 2018 21:15:48 +0000 (16:15 -0500)]
cls/rbd: remove incompatible group features from partial implementation

Fixes: https://tracker.ceph.com/issues/22676
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agomgr/prometheus: add missing 'deep' state to PG_STATES in ceph-mgr prometheus plugin 19929/head
Peter Woodman [Sun, 12 Nov 2017 00:32:37 +0000 (16:32 -0800)]
mgr/prometheus: add missing 'deep' state to PG_STATES in ceph-mgr prometheus plugin

without this the endpoint throws 500s when any PG is doing a deep scrub.

Signed-off-by: Peter Woodman <peter@shortbus.org>
Fixes: http://tracker.ceph.com/issues/22116
(cherry picked from commit 8c93c0eeaff406af0878916ef5b9ce958896d586)

7 years agopybind/mgr/prometheus: don't crash when encountering an unknown PG state
Jan Fajerski [Mon, 13 Nov 2017 13:42:56 +0000 (14:42 +0100)]
pybind/mgr/prometheus: don't crash when encountering an unknown PG state

Signed-off-by: Jan Fajerski <jfajerski@suse.com>
(cherry picked from commit 67a1b66b06bf74274c2cf1d4b5c900f2c56a990d)

7 years agoMerge pull request #19925 from jcsp/wip-dashboard-trim-luminous2 19955/head
John Spray [Mon, 15 Jan 2018 14:42:55 +0000 (14:42 +0000)]
Merge pull request #19925 from jcsp/wip-dashboard-trim-luminous2

luminous: mgr: remove unused static files from dashboard module

Reviewed-by: Sebastien Han <shan@redhat.com>
7 years agomgr/dashboard: remove unneeded bits of AdminLTE 19925/head
John Spray [Wed, 2 Aug 2017 14:11:07 +0000 (15:11 +0100)]
mgr/dashboard: remove unneeded bits of AdminLTE

AdminLTE is delivered in a handy all-in format,
but we don't need all this stuff at runtime.

Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit 38df5150ee026c6dc9ec763f757713c7e4d99cdb)

7 years agomgr/dashboard: remove non-minified bootstrap
John Spray [Wed, 2 Aug 2017 14:15:04 +0000 (15:15 +0100)]
mgr/dashboard: remove non-minified bootstrap

Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit 5ce51ebbf047e373eac624e49e2d2bcfb46f09ff)

7 years agomgr/dashboard: remove un-minified datatables source
John Spray [Wed, 2 Aug 2017 14:54:17 +0000 (15:54 +0100)]
mgr/dashboard: remove un-minified datatables source

Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit 888f0f934e59fe28fdd97bca044702ce445bfe2e)

7 years agomgr/dashboard: don't include remote js/css
John Spray [Mon, 18 Sep 2017 10:10:31 +0000 (06:10 -0400)]
mgr/dashboard: don't include remote js/css

This will help anyone running away from the internet.

Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit 199d7ff26959961f200b86062f6290c9c17cba9a)

7 years agomgr/dashboard: re-arrange static files
John Spray [Mon, 18 Sep 2017 10:13:45 +0000 (06:13 -0400)]
mgr/dashboard: re-arrange static files

Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit 85a87da7aa46266abd8d4c42218bcbccce386316)

7 years agoMerge pull request #19880 from jcsp/wip-doc-dashboard-standby-luminous
Kefu Chai [Thu, 11 Jan 2018 06:31:26 +0000 (14:31 +0800)]
Merge pull request #19880 from jcsp/wip-doc-dashboard-standby-luminous

doc: update mgr/dashboard doc about standbys

Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agodoc: update mgr/dashboard doc about standbys 19880/head
John Spray [Tue, 9 Jan 2018 22:23:33 +0000 (22:23 +0000)]
doc: update mgr/dashboard doc about standbys

Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit fa14812cbb584b61cb2ce687ae4c14225eecd9fe)

7 years agoMerge pull request #19844 from jcsp/wip-22615
John Spray [Tue, 9 Jan 2018 11:13:04 +0000 (11:13 +0000)]
Merge pull request #19844 from jcsp/wip-22615

luminous: mgr/dashboard: Fix PG status coloring

Reviewed-by: Wido den Hollander <wido@42on.com>
Reviewed-by: John Spray <john.spray@redhat.com>
7 years agoMerge pull request #19858 from joscollin/wip-luminous-doc-misc-fixes
Jos Collin [Tue, 9 Jan 2018 09:16:58 +0000 (09:16 +0000)]
Merge pull request #19858 from joscollin/wip-luminous-doc-misc-fixes

luminous: doc: misc fixes for CephFS best practices

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
7 years agodoc: misc fixes 19858/head
Jos Collin [Fri, 5 Jan 2018 06:21:00 +0000 (11:51 +0530)]
doc: misc fixes

misc fixes for best-practices.

Signed-off-by: Jos Collin <jcollin@redhat.com>
(cherry picked from commit ecacd1078db5020e6d65436f9d56cc9ed0016666)

7 years agodoc: fix heading
Jos Collin [Fri, 5 Jan 2018 05:54:23 +0000 (11:24 +0530)]
doc: fix heading

Fixed 'Which kernel version?' heading not having brown color background.

Signed-off-by: Jos Collin <jcollin@redhat.com>
(cherry picked from commit a068fd842f431a54f9db2d437a71cdc11907a8e1)

7 years agorgw: put bucket policy panics RGW process 19847/head
Bingyin Zhang [Tue, 26 Dec 2017 09:06:44 +0000 (17:06 +0800)]
rgw: put bucket policy panics RGW process

Fixes: http://tracker.ceph.com/issues/22541
Signed-off-by: Bingyin Zhang <zhangbingyin@cloudin.cn>
(cherry picked from commit f05a044cad18c16ebc2c9a177f38b4bdc76cfd66)

7 years agoMerge pull request #19505 from shinobu-x/wip-22392-luminous
Jos Collin [Mon, 8 Jan 2018 17:22:30 +0000 (17:22 +0000)]
Merge pull request #19505 from shinobu-x/wip-22392-luminous

luminous: mds: tell session ls returns vanila EINVAL when MDS is not active

Reviewed-by: Jos Collin <jcollin@redhat.com>
7 years agoMerge pull request #19831 from pdvian/wip-22576-luminous
John Spray [Mon, 8 Jan 2018 16:18:12 +0000 (16:18 +0000)]
Merge pull request #19831 from pdvian/wip-22576-luminous

luminous: qa: configure zabbix properly before selftest

Reviewed-by: John Spray <john.spray@redhat.com>
Reviewed-by: Wido den Hollander <wido@42on.com>
7 years agomgr/dashboard: Fix PG status coloring 19844/head
Wido den Hollander [Mon, 11 Dec 2017 10:33:16 +0000 (11:33 +0100)]
mgr/dashboard: Fix PG status coloring

This was broken in the 12.2.2 release and PGs would not get a
color anymore.

This commit also makes sure pools/PGs are marked as red when
one or more PGs are inactive, inconsistent, incomplete, down, etc.

Signed-off-by: Wido den Hollander <wido@42on.com>
(cherry picked from commit 450aa2133d05916822083969260ee07622591e33)

7 years agoMerge pull request #19787 from linuxbox2/luminous-21984
Yehuda Sadeh [Mon, 8 Jan 2018 10:15:39 +0000 (12:15 +0200)]
Merge pull request #19787 from linuxbox2/luminous-21984

rgw: fix rewrite a versioning object create a new object bug

7 years agoqa: configure zabbix properly before selftest 19831/head
John Spray [Thu, 21 Dec 2017 13:27:45 +0000 (08:27 -0500)]
qa: configure zabbix properly before selftest

Even though the selftest routine doesn't care about
the settings, we should set them to avoid emitting
nasty log/health messages when enabling the module.

Fixes: http://tracker.ceph.com/issues/22514
Signed-off-by: John Spray <john.spray@redhat.com>
(cherry picked from commit c64c9ff00d2df2177135bcd2735bd7aeac625643)

7 years agorgw: Policies now properly evaluate the X-Forwarded-For header. 19819/head
John Gibson [Tue, 19 Sep 2017 13:17:22 +0000 (09:17 -0400)]
rgw: Policies now properly evaluate the X-Forwarded-For header.

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit 5f7d9c4ff6c78f65d074dbdf8a181cb9ae09851e)

7 years agorgw: Test of proper parsing of the X-Forwarded-For header for policies.
John Gibson [Tue, 19 Sep 2017 14:55:12 +0000 (10:55 -0400)]
rgw: Test of proper parsing of the X-Forwarded-For header for policies.

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit e02facbf5c7b06b4d1d628ddb83ee74935493def)

7 years agorgw: Bucket IP address policy evaluation now uses rgw_remote_addr_param.
John Gibson [Sun, 24 Dec 2017 20:49:50 +0000 (15:49 -0500)]
rgw: Bucket IP address policy evaluation now uses rgw_remote_addr_param.

Previously bucket policy ip address restrictions were only being evaluated
against the REMOTE_ADDR environment variable and ignoring the header
specified by the rgw_remote_addr_param configuration option. This rendered
ip-based bucket policies worthless when running behind a reverse proxy.

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit c4c24ca986f17c68b75f76fc48ad489002fcf87e)

7 years agorgw: rgw_iam test harness can now stringify() the fake identity.
John Gibson [Thu, 14 Sep 2017 14:12:59 +0000 (10:12 -0400)]
rgw: rgw_iam test harness can now stringify() the fake identity.

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit 557bdb617e6eb78f9f0e6d6ba35b79b318a6c275)

7 years agorgw: Fixed several bugs in policies related to IPv6 addresses.
John Gibson [Sun, 24 Dec 2017 20:48:00 +0000 (15:48 -0500)]
rgw: Fixed several bugs in policies related to IPv6 addresses.

The IPv6 conversion was not properly converting the address to host byte
order.
The text conversion of IPv6 addresses was using raw byte values instead of
the converted number. The portions of the addresses were grouped by bytes
instead of 16-bit words. The prefix length was erroneously being rendered
in hex.

http://tracker.ceph.com/issues/20991

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit a25ca37401d1e8dc4349201b9f64aa6990bea0d5)

7 years agorgw: Fixed several bugs in policies related to IP Addresses.
John Gibson [Sun, 24 Dec 2017 20:44:54 +0000 (15:44 -0500)]
rgw: Fixed several bugs in policies related to IP Addresses.

Comparisons of two individual IP addresses caused an assertion error.
The text conversion of IPv4 addresses was using raw byte values instead of
the converted number.
NotIpAddress condition now works with multiple values.

http://tracker.ceph.com/issues/20991

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit ca21596c95aa3871d14ac9112840d3b1101a8635)

7 years agorgw: Added tests for S3 Policy IP Address feature.
John Gibson [Tue, 26 Dec 2017 21:40:31 +0000 (16:40 -0500)]
rgw: Added tests for S3 Policy IP Address feature.

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit 3d260f26e6826182b4de520878b548a28a96e81b)

7 years agorgw: Added support for testing the wildcard principal in policies.
John Gibson [Thu, 10 Aug 2017 17:39:35 +0000 (13:39 -0400)]
rgw: Added support for testing the wildcard principal in policies.

Signed-off-by: John Gibson <jgibson@mitre.org>
(cherry picked from commit e83b647d44153a7775647693fca1848e592ee107)

7 years agorgw: implement ipv4 aws:SourceIp condition for bucket policy
yuliyang [Mon, 27 Nov 2017 06:32:44 +0000 (14:32 +0800)]
rgw: implement ipv4 aws:SourceIp condition for bucket policy

Signed-off-by: yuliyang <yuliyang@cmss.chinamobile.com>
(cherry picked from commit 2fb445b6f7c1e997e83b1c7da2a1fecdde164d35)

7 years agorgw: simplify use of map::emplace in iam
Casey Bodley [Fri, 3 Nov 2017 14:42:37 +0000 (10:42 -0400)]
rgw: simplify use of map::emplace in iam

the piecewise_construct overloads of map::emplace() are only needed when
there's ambiguity around which arguments go to which constructor

Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 9787fe6b8dc545419b0f3375c06a57a414ae8aa6)

7 years agorgw: policy: support for s3 conditionals in ListBucket
Abhishek Lekshmanan [Thu, 27 Jul 2017 15:36:37 +0000 (17:36 +0200)]
rgw: policy: support for s3 conditionals in ListBucket

This adds support for s3:prefix,delimeter & maxkeys identifiers when
specified as conditionals in policy.

Signed-off-by: Abhishek Lekshmanan <abhishek@suse.com>
(cherry picked from commit a7184ca8c507b66ef01687bd85528342ea3bf934)

7 years agorgw: fix opslog can not record remote_addr
Jiaying Ren [Mon, 7 Aug 2017 07:55:19 +0000 (15:55 +0800)]
rgw: fix opslog can not record remote_addr

Fixes: http://tracker.ceph.com/issues/20931
Reported-by: Zhang Shaowen <zhangshaowen@cmss.chinamobile.com>
Signed-off-by: Jiaying Ren <jiaying.ren@umcloud.com>
(cherry picked from commit 650d30d64e084df12f4cfcb3d1edaefb5d475bb4)

7 years agorgw: Fix evaluation of bucket management permissions 19810/head
Adam C. Emerson [Sat, 28 Oct 2017 02:48:18 +0000 (22:48 -0400)]
rgw: Fix evaluation of bucket management permissions

I spent some more time looking through the documentation of how work
is evaluated, and the examples on

<http://docs.aws.amazon.com/AmazonS3/latest/dev/
access-control-auth-workflow-bucket-operation.html>

Have convinced me that the behavior that was requested is more correct
than what we were doing before.

Fixes: http://tracker.ceph.com/issues/21901
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 343a25aa2134b6fdddeca6c9dfbaefde2dc9c66a)

7 years agorgw: Refactor checking of some ops
Adam C. Emerson [Sat, 28 Oct 2017 00:17:52 +0000 (20:17 -0400)]
rgw: Refactor checking of some ops

Since some operations check the user against the bucket owner in the
absence of a policy, rather than open-coding that everywhere, act like
a proper computer scientist and abstract it.

Fixes: http://tracker.ceph.com/issues/21896
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 8818a0cb5e699135976e057061fb8e9d99850cd3)

7 years agoMerge pull request #19449 from smithfarm/wip-22398-luminous
Jos Collin [Fri, 5 Jan 2018 17:07:00 +0000 (17:07 +0000)]
Merge pull request #19449 from smithfarm/wip-22398-luminous

luminous: doc: man page for mount.fuse.ceph

Reviewed-by: Jos Collin <jcollin@redhat.com>
7 years agorgw: Plumb refresh logic into object cache 19788/head
Adam C. Emerson [Wed, 20 Dec 2017 22:06:32 +0000 (17:06 -0500)]
rgw: Plumb refresh logic into object cache

Now when we force a refetch of bucket info it will actually go to the
OSD rather than simply using the objects in the object cache.

Fixes: http://tracker.ceph.com/issues/22517
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit d997f657750faf920170843e62deacab70008d8b)

7 years agorgw: Add expiration in the object cache
Adam C. Emerson [Tue, 19 Dec 2017 21:47:09 +0000 (16:47 -0500)]
rgw: Add expiration in the object cache

We had it in the chained caches, but it doesn't do much good if
they just fetch objects out of the object cache.

Fixes: http://tracker.ceph.com/issues/22517
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 82a7e6ca31b416a7f0e41b5fda4c403d1d6be947)

7 years agorgw: retry CORS put/delete operations on ECANCELLED
Adam C. Emerson [Tue, 19 Dec 2017 17:53:05 +0000 (12:53 -0500)]
rgw: retry CORS put/delete operations on ECANCELLED

Fixes: http://tracker.ceph.com/issues/22517
Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit bff7e61ca5a66b301ec49c1cf9054d1b74535832)

7 years agorgw: Expire entries in bucket info cache
Adam C. Emerson [Fri, 17 Nov 2017 22:15:26 +0000 (17:15 -0500)]
rgw: Expire entries in bucket info cache

To bound the degree to which an RGW instance can go out to lunch if
the watch/notify breaks down, force refresh of any cache entry over a
certain age.

Fifteen minutes by default, and expiration can be turned off entirely.

This is separate from the LRU. The LRU removes entries based on the
last time of access. This expiration patch forces refresh based on the
last time they were updated.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 4489cb58a15647a31ac0546d70400af5668404cb)
Fixes: http://tracker.ceph.com/issues/22517
7 years agodoc: fix typo 19449/head
Jos Collin [Fri, 5 Jan 2018 14:07:31 +0000 (19:37 +0530)]
doc: fix typo

Signed-off-by: Jos Collin <jcollin@redhat.com>
(cherry picked from commit a925bb4520797376b4b169bbcfe613cd1fa36429)

7 years agodoc: add mount.fuse.ceph to index
Jos Collin [Fri, 5 Jan 2018 07:11:37 +0000 (12:41 +0530)]
doc: add mount.fuse.ceph to index

Added mount.fuse.ceph to index.rst

Fixes: http://tracker.ceph.com/issues/22595
Signed-off-by: Jos Collin <jcollin@redhat.com>
(cherry picked from commit db23f4ce30cd521b5b8909edc8c26dc87aeecd98)

7 years agodoc: doc for mount.fuse.ceph
Jos Collin [Mon, 27 Nov 2017 10:46:35 +0000 (16:16 +0530)]
doc: doc for mount.fuse.ceph

Created doc for mount.fuse.ceph.

Fixes: http://tracker.ceph.com/issues/21539
Signed-off-by: Jos Collin <jcollin@redhat.com>
(cherry picked from commit 6c39818eaf39358cab8dd3dce579c932fba0d05d)

7 years agorgw: Handle stale bucket info in RGWDeleteBucketPolicy
Adam C. Emerson [Fri, 17 Nov 2017 21:16:38 +0000 (16:16 -0500)]
rgw: Handle stale bucket info in RGWDeleteBucketPolicy

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit e397b7e6d0c49d625fb2b2363311e6486f2045fe)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: Handle stale bucket info in RGWPutBucketPolicy
Adam C. Emerson [Fri, 17 Nov 2017 21:15:04 +0000 (16:15 -0500)]
rgw: Handle stale bucket info in RGWPutBucketPolicy

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 1738b4f6b726b462abb436f78026c1577b55f05e)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: Handle stale bucket info in RGWDeleteBucketWebsite
Adam C. Emerson [Fri, 17 Nov 2017 21:05:06 +0000 (16:05 -0500)]
rgw: Handle stale bucket info in RGWDeleteBucketWebsite

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit f4d274248e43cb38ff2b27782c010b2c35b12b2b)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: Handle stale bucket info in RGWSetBucketWebsite
Adam C. Emerson [Fri, 17 Nov 2017 21:03:13 +0000 (16:03 -0500)]
rgw: Handle stale bucket info in RGWSetBucketWebsite

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit b2b7385f194def1025a8947bab876c9856b06400)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: Handle stale bucket info in RGWSetBucketVersioning
Adam C. Emerson [Fri, 17 Nov 2017 20:59:44 +0000 (15:59 -0500)]
rgw: Handle stale bucket info in RGWSetBucketVersioning

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit a0a1e7c2ef992b8758bcfb20d893730c1b202475)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: Handle stale bucket info in RGWPutMetadataBucket
Adam C. Emerson [Fri, 17 Nov 2017 20:53:05 +0000 (15:53 -0500)]
rgw: Handle stale bucket info in RGWPutMetadataBucket

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit ebb86301b20098e15824f469001f6153b27965f5)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: Add retry_raced_bucket_write
Adam C. Emerson [Fri, 17 Nov 2017 20:51:42 +0000 (15:51 -0500)]
rgw: Add retry_raced_bucket_write

If the OSD informs us that our bucket info is out of date when we need
to write, we should have a way to update it.

This template function allows us to wrap relevant sections of code so
they'll be retried against new bucket info on -ECANCELED.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 1a3fcc70c0747791aa423cd0aa7d2596eaf3d73c)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: fix rewrite a versioning object create a new object bug 19787/head
Enming Zhang [Tue, 31 Oct 2017 07:21:21 +0000 (15:21 +0800)]
rgw: fix rewrite a versioning object create a new object bug

Fixes: http://tracker.ceph.com/issues/21984
Signed-off-by: Enming Zhang <enming.zhang@umcloud.com>
(cherry picked from commit 700a0292362128cb29586a64ef8215a07d96736b)
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
7 years agorgw: Add try_refresh_bucket_info function
Adam C. Emerson [Thu, 16 Nov 2017 19:42:58 +0000 (14:42 -0500)]
rgw: Add try_refresh_bucket_info function

Sometimes operations fail with -ECANCELED. This means we got raced. If
this happens we should update our bucket info from cache and try again.

Some user reports suggest that our cache may be getting and staying
out of sync. This is a bug and should be fixed, but it would also be
nice if we were robust enough to notice the problem and refresh.

So in that case, we invalidate the cache and fetch direct from the
OSD, putting a warning in the log.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
(cherry picked from commit 9114e5e50995f0c7d2be5c24aa4712d89cd89f48)
Fixes: http://tracker.ceph.com/issues/22517
7 years agorgw: fix chained cache invalidation to prevent cache size growth 19785/head
Mark Kogan [Tue, 12 Dec 2017 15:34:05 +0000 (10:34 -0500)]
rgw: fix chained cache invalidation to prevent cache size growth
above the rgw_cache_lru_size limit

Fixes: http://tracker.ceph.com/issues/22410
Signed-off-by: Mark Kogan <mkogan@redhat.com>
(cherry picked from commit a6a1b664d313a54ad9d2f64b859296b1352b1ce4)

7 years agoMerge pull request #19243 from liewegas/wip-fix-statfs-luminous
Sage Weil [Wed, 3 Jan 2018 17:07:39 +0000 (11:07 -0600)]
Merge pull request #19243 from liewegas/wip-fix-statfs-luminous

mon/Monitor: fix statfs handling before luminous switchover happens

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
7 years agoMerge pull request #19746 from ceph/wip-use-installer0-luminous2
vasukulkarni [Tue, 2 Jan 2018 22:23:35 +0000 (14:23 -0800)]
Merge pull request #19746 from ceph/wip-use-installer0-luminous2

qa/tests - Added options to use both cases: mon.a and installer.0

7 years agoqa/tests - Added options to use both cases: mon.a and installer.0 19746/head
Yuri Weinstein [Tue, 2 Jan 2018 18:12:54 +0000 (10:12 -0800)]
qa/tests - Added options to use both cases: mon.a and installer.0

Signed-off-by: Yuri Weinstein <yweinste@redhat.com>
(cherry picked from commit 10fc85089c3bb64ced8c3a0ea17987e9ec5f46a2)
Signed-off-by: Yuri Weinstein <yweinste@redhat.com>
7 years agoqa/tests: run ceph-ansible task on installer.0 role/node
Yuri Weinstein [Wed, 20 Dec 2017 21:05:22 +0000 (13:05 -0800)]
qa/tests: run ceph-ansible task on installer.0 role/node

Signed-off-by: Yuri Weinstein <yweinste@redhat.com>
(cherry picked from commit 3b2a26d919c173c887fd193f186ea56c33fcd9ae)

7 years agoMerge pull request #19741 from joscollin/luminous
Sage Weil [Tue, 2 Jan 2018 15:17:16 +0000 (09:17 -0600)]
Merge pull request #19741 from joscollin/luminous

luminous: doc: update Blacklisting and OSD epoch barrier

7 years agodoc: fix grammar mistake 19741/head
Jos Collin [Tue, 2 Jan 2018 10:47:39 +0000 (16:17 +0530)]
doc: fix grammar mistake

Fixed grammar mistake in a sentence.

Signed-off-by: Jos Collin <jcollin@redhat.com>
7 years agodoc: update Blacklisting and OSD epoch barrier
Jos Collin [Tue, 2 Jan 2018 10:41:30 +0000 (16:11 +0530)]
doc: update Blacklisting and OSD epoch barrier

Updated missing OSD epoch barrier section, which is referenced by http://docs.ceph.com/docs/luminous/cephfs/full/#hammer-and-later.

Fixes: http://tracker.ceph.com/issues/22552
Signed-off-by: Jos Collin <jcollin@redhat.com>
7 years agoMerge pull request #19721 from tchaikov/wip-luminous-boost-un-submodule
Sage Weil [Sat, 30 Dec 2017 20:12:19 +0000 (14:12 -0600)]
Merge pull request #19721 from tchaikov/wip-luminous-boost-un-submodule

luminous: boost un-submodule

Reviewed-by: Sage Weil <sage@redhat.com>
7 years agomake-dist: exclude unused bits in boost 19721/head
Kefu Chai [Fri, 24 Nov 2017 05:56:02 +0000 (13:56 +0800)]
make-dist: exclude unused bits in boost

the docs, examples and tests are not used. so drop them. we could go
further by removing unused components in boost. but that'd be an issue
if somebody added a component in CMakeLists but forgets to update this
script. also, we need to remove boost/$component and lib/$component to
achieve this goal. this also introduces extra complicity. so leave it
for another change.

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 65f91227a6b052ad60b01276d7d72dea07cbb1a4)

7 years agomake-dist: repackage boost in the correct path
Kefu Chai [Fri, 24 Nov 2017 02:27:19 +0000 (10:27 +0800)]
make-dist: repackage boost in the correct path

before this change, boost is put into ./src. after this change, it is
put into $outfile/src. i.e. something like
ceph-12.1.2-4592-gf5f2ced624/src .

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 2218efa005ab871f26402b5dd33b2e599897c11f)

7 years agomake-dist,cmake: Try multiple URLs to download boost before failing
Brad Hubbard [Thu, 28 Sep 2017 05:28:53 +0000 (15:28 +1000)]
make-dist,cmake: Try multiple URLs to download boost before failing

Remove SPOF during boost download for make-dist and later cmake > 3.7

Signed-off-by: Brad Hubbard <bhubbard@redhat.com>
(cherry picked from commit 598556f98b65a03ad40ad076623b9cc8b507810e)

7 years agomake-dist,cmake: move boost tarball location to download.ceph.com
Sage Weil [Tue, 26 Sep 2017 21:15:17 +0000 (17:15 -0400)]
make-dist,cmake: move boost tarball location to download.ceph.com

Sourceforge is down.  Also, we can hammer our servers instead of
theirs.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 19987549e0ce526e353e24adddc7df8b1f165aab)

7 years agomake-dist: download and repackage boost
Kefu Chai [Thu, 31 Aug 2017 17:00:04 +0000 (01:00 +0800)]
make-dist: download and repackage boost

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit f04436b189376cf7b53d710ab2f2bf01d47482ad)

7 years agoboost: remove boost submodule
Kefu Chai [Tue, 30 May 2017 15:58:44 +0000 (23:58 +0800)]
boost: remove boost submodule

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 6b23056cf8d0d1bbd269bc96eef33dc27c25fd9e)