Project

General

Profile

Bug #4471

osd: pool name for each pg not updated in memory after pool rename

Added by Josh Durgin about 11 years ago. Updated about 11 years ago.

Status:
Resolved
Priority:
High
Assignee:
David Zafman
Category:
OSD
Target version:
-
% Done:

0%

Source:
Community (user)
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

I noticed this before (hence #4269), but apparently didn't finish filing a bug about it.

Now someone else ran into it on ceph-users:

During my journey of using rados cppool, which is an awesome feature by the way, I found an interesting behavior related to cephx. I wanted to share it for anyone else who may be using Openstack, that decides to rename, or copy a pool. 

My client.glance entry is currently set to this (with the exception of the key, of course): 

client.glance 
key: punkrawk 
caps: [mon] allow r 
caps: [osd] allow class-read object_prefix rbd_children, allow rwx 

It was limited to the images pool based on the following setting listed at http://ceph.com/docs/master/rbd/rbd-openstack/ : 

client.glance 
key: punkrawk 
caps: [mon] allow r 
caps: [osd] allow class-read object_prefix rbd_children, allow rwx pool=images 
ceph auth get-or-create client.glance mon 'allow r' osd 'allow class-read object_prefix rbd_children, allow rwx pool=images' What I found was that when I would create my pool as images-new or anything but images, then rename it to images I would have a problem. I could not even upload an image to an empty pool. 

I could, however; upload to the pool if I renamed the original to images-old, then created a brand new pool called images. 

My first guess is that there's a reference to the old name which would interfere whenever my client would try to use it with the client.glance keyring. I have not looked in the code yet, so I don't have any other concrete idea. 

As soon as I lifted the pool restriction, as if by the power greyskull, I could upload, delete and take snapshots in the renamed pool. 

I believe this would be rather easy for anyone to reproduce with a test install of Openstack. 

Just create pool named images-new. Rename it to images, then try to upload an image. It should fail. Remove the pool restriction, and it will work. 

Dave Spano 
Optogenics 
Systems Administrator 

Associated revisions

Revision f804892d (diff)
Added by Samuel Just about 11 years ago

PG: update PGPool::name in PGPool::update

Fixes: #4471
Signed-off-by: Samuel Just <>

Revision d89ab0ea (diff)
Added by Samuel Just about 11 years ago

PG: update PGPool::name in PGPool::update

Fixes: #4471
Signed-off-by: Samuel Just <>
Reviewed-by: Sage Weil <>
(cherry picked from commit f804892d725cfa25c242bdc577b12ee81dcc0dcc)

History

#1 Updated by Ian Colle about 11 years ago

  • Assignee set to David Zafman
  • Priority changed from Normal to High

#2 Updated by Samuel Just about 11 years ago

  • Status changed from 12 to Resolved

Also available in: Atom PDF