Skip to contentSkip to conversation

cls_rbd ops on rbd_id.$name objects in EC pool

DISCUSSION Sage Weil 9 participants 19 messages Feb 5, 2016 – Feb 12, 2016 10 messages not in the archive

lore
Share & tools
lore

Sage Weil

author
#0 lore raw
Quoted 13 lines · Nick Fisk
Quoted 9 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 3 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the same.

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior from cls_rbd. It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis workaround?

Jason? Sam?
sage

Quoted 65 lines
Quoted 54 lines

--

Jason Dillaman

----- Original Message -----

Quoted 37 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G
rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1 asok(0x561837b88360)
AdminSocketConfigObs::init: failed: AdminSocket::bind_and_listen:
failed to bind the UNIX domain socket to
'/var/run/ceph/ceph-client.admin.asok': (17) File exists
2016-01-27 13:39:52.703987 7f9e32ffd700 -1 librbd::image::OpenRequest:
failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported
2016-01-27 13:39:52.704138 7f9e327fc700 -1 librbd::ImageState: failed
Quoted 9 lines

to open image: (95) Operation not supported

Nick

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

#1 lore raw

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

Signature · 3 lines
Jason Dillaman 

----- Original Message -----
Quoted 123 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 14 lines · Nick Fisk
Quoted 9 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an
issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the same.

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior from cls_rbd. It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis workaround?

Jason? Sam?
sage

Quoted 59 lines
Quoted 54 lines

--

Jason Dillaman

----- Original Message -----

Quoted 37 lines

From: "Nick Fisk" <[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G
rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1 asok(0x561837b88360)
AdminSocketConfigObs::init: failed: AdminSocket::bind_and_listen:
failed to bind the UNIX domain socket to
'/var/run/ceph/ceph-client.admin.asok': (17) File exists
2016-01-27 13:39:52.703987 7f9e32ffd700 -1 librbd::image::OpenRequest:
failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported
2016-01-27 13:39:52.704138 7f9e327fc700 -1 librbd::ImageState: failed
Quoted 9 lines

to open image: (95) Operation not supported

Nick

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): 1582262647.20033136.1454687586287.JavaMail.zimbra-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org

#3 lore raw

It seems like the cache tier should force promote when it gets an op the backing pool doesn't support. I think using the cache-pin mechanism would make sense.
-Sam

Quoted 134 lines · Jason Dillaman

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

--

Jason Dillaman

----- Original Message -----

Quoted 118 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <nick-ksME7r3P/[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 14 lines · Nick Fisk
Quoted 9 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an
issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the same.

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior from cls_rbd. It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis workaround?

Jason? Sam?
sage

Quoted 59 lines
Quoted 54 lines

--

Jason Dillaman

----- Original Message -----

Quoted 37 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G
rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1 asok(0x561837b88360)
AdminSocketConfigObs::init: failed: AdminSocket::bind_and_listen:
failed to bind the UNIX domain socket to
'/var/run/ceph/ceph-client.admin.asok': (17) File exists
2016-01-27 13:39:52.703987 7f9e32ffd700 -1 librbd::image::OpenRequest:
failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported
2016-01-27 13:39:52.704138 7f9e327fc700 -1 librbd::ImageState: failed
Quoted 9 lines

to open image: (95) Operation not supported

Nick

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 5 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#4 lore raw
Quoted 6 lines · Samuel Just
Quoted 5 lines · Jason Dillaman

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

sage

Quoted 137 lines

-Sam

Quoted 133 lines

--

Jason Dillaman

----- Original Message -----

Quoted 118 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 14 lines · Nick Fisk
Quoted 9 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an
issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the same.

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior from cls_rbd. It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis workaround?

Jason? Sam?
sage

Quoted 59 lines
Quoted 54 lines

--

Jason Dillaman

----- Original Message -----

Quoted 37 lines

From: "Nick Fisk" <[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G
rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1 asok(0x561837b88360)
AdminSocketConfigObs::init: failed: AdminSocket::bind_and_listen:
failed to bind the UNIX domain socket to
'/var/run/ceph/ceph-client.admin.asok': (17) File exists
2016-01-27 13:39:52.703987 7f9e32ffd700 -1 librbd::image::OpenRequest:
failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported
2016-01-27 13:39:52.704138 7f9e327fc700 -1 librbd::ImageState: failed
Quoted 9 lines

to open image: (95) Operation not supported

Nick

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 5 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): alpine.DEB.2.11.1602051340490.28396-Wo5lQnKln9t9PHm/[email protected]

#6 lore raw
Quoted 30 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <nick-ksME7r3P/[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 1 line · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency fix on Infernalis. Initially I thought this was a flushing issue as I just assumed those objects shouldn't get flushed out at all. But after reading your email where you said it forced the promotion, it struck me that the broken recency behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above again and this time it worked. Does this make sense?

Nick

Quoted 154 lines

sage

Quoted 49 lines

-Sam

Quoted 47 lines

--

Jason Dillaman

----- Original Message -----

Quoted 41 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <nick-ksME7r3P/[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 15 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone
confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 38 lines
Quoted 38 lines
Quoted 38 lines

Jason? Sam?
sage

Quoted 32 lines
Quoted 32 lines

--

Jason Dillaman

----- Original Message -----

Quoted 24 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 29 lines
Quoted 29 lines
Quoted 29 lines
Quoted 18 lines
Quoted 13 lines
Quoted 6 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 6 lines
Quoted 4 lines

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): [email protected]

#8 lore raw

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency setting. I'm guessing that the info command does some sort of read and then a write. In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1 min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1 min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest: failed to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed to open image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 0
set pool 12 min_read_recency_for_promote to 0
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 221 lines

-----Original Message-----
From: Nick Fisk [mailto:nick-ksME7r3P/[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 30 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <nick-ksME7r3P/[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 1 line · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency fix on Infernalis. Initially I thought this was a flushing issue as I just assumed those objects shouldn't get flushed out at all. But after reading your email where you said it forced the promotion, it struck me that the broken recency behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above again and this time it worked. Does this make sense?

Nick

Quoted 155 lines

sage

Quoted 50 lines

-Sam

Quoted 48 lines

--

Jason Dillaman

----- Original Message -----

Quoted 42 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <nick-ksME7r3P/[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 15 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can
someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 39 lines
Quoted 39 lines
Quoted 39 lines

Jason? Sam?
sage

Quoted 33 lines
Quoted 33 lines

--

Jason Dillaman

----- Original Message -----

Quoted 25 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 31 lines
Quoted 31 lines
Quoted 31 lines
Quoted 19 lines
Quoted 14 lines
Quoted 7 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 6 lines
Quoted 4 lines

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): [email protected]

#10 lore raw

What's your cache mode? In the master branch, I would expect that class method ops should force a promotion to the cache tier if the base tier is an EC pool [1].

[1] https://github.com/ceph/ceph/blob/master/src/osd/OSD.cc#L8905

Signature · 4 lines
Jason Dillaman 


----- Original Message -----
Quoted 279 lines

From: "Nick Fisk" <[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency setting. I'm guessing that the info command does some sort of read and then a write. In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1 min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1 min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest: failed
to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed to open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 0
set pool 12 min_read_recency_for_promote to 0
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 227 lines

-----Original Message-----
From: Nick Fisk [mailto:[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 30 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 1 line · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may
have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency
fix on Infernalis. Initially I thought this was a flushing issue as I just assumed
those objects shouldn't get flushed out at all. But after reading your email
where you said it forced the promotion, it struck me that the broken recency
behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above
again and this time it worked. Does this make sense?

Nick

Quoted 155 lines

sage

Quoted 50 lines

-Sam

Quoted 48 lines

--

Jason Dillaman

----- Original Message -----

Quoted 42 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 15 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 39 lines
Quoted 39 lines
Quoted 39 lines

Jason? Sam?
sage

Quoted 33 lines
Quoted 33 lines

--

Jason Dillaman

----- Original Message -----

Quoted 25 lines

From: "Nick Fisk" <[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 31 lines
Quoted 31 lines
Quoted 31 lines
Quoted 19 lines
Quoted 14 lines
Quoted 7 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 6 lines
Quoted 4 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): 271250224.21879902.1455215992099.JavaMail.zimbra-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org

#12 lore raw

I'm trying to reproduce this.

Jason, I found your commit marks certain cls ops and requiring promotion, but that doesn't include rbd... and I'm not sure why info would need to be promoted. Working on reproducing this under hammer with the appropriate recency settings.

sage

Quoted 295 lines · Jason Dillaman

What's your cache mode? In the master branch, I would expect that class method ops should force a promotion to the cache tier if the base tier is an EC pool [1].

[1] https://github.com/ceph/ceph/blob/master/src/osd/OSD.cc#L8905

Signature · 4 lines
Jason Dillaman 


----- Original Message -----
Quoted 37 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency setting. I'm guessing that the info command does some sort of read and then a write. In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1 min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1 min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest: failed
to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed to open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 0
set pool 12 min_read_recency_for_promote to 0
Quoted 242 lines
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 227 lines

-----Original Message-----
From: Nick Fisk [mailto:nick-ksME7r3P/[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 30 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <nick-ksME7r3P/[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 1 line · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may
have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency
fix on Infernalis. Initially I thought this was a flushing issue as I just assumed
those objects shouldn't get flushed out at all. But after reading your email
where you said it forced the promotion, it struck me that the broken recency
behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above
again and this time it worked. Does this make sense?

Nick

Quoted 155 lines

sage

Quoted 50 lines

-Sam

Quoted 48 lines

--

Jason Dillaman

----- Original Message -----

Quoted 42 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <nick-ksME7r3P/[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 15 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can
someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 39 lines
Quoted 39 lines
Quoted 39 lines

Jason? Sam?
sage

Quoted 33 lines
Quoted 33 lines

--

Jason Dillaman

----- Original Message -----

Quoted 25 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 31 lines
Quoted 31 lines
Quoted 31 lines
Quoted 19 lines
Quoted 14 lines
Quoted 7 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 6 lines
Quoted 4 lines

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#13 lore raw

That class method flag to force promotion was to prevent proxying lock/unlock class ops. What was happening was that the cache tier OSD would become the owner of the lock instead of the client (retrieved via cls_get_request_origin).

Signature · 4 lines
Jason Dillaman 


----- Original Message -----
Quoted 336 lines

From: "Sage Weil" <[email protected]>
To: "Jason Dillaman" <[email protected]>
Cc: "Nick Fisk" <[email protected]>, "Samuel Just" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 2:04:03 PM
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

I'm trying to reproduce this.

Jason, I found your commit marks certain cls ops and requiring promotion, but that doesn't include rbd... and I'm not sure why info would need to be promoted. Working on reproducing this under hammer with the appropriate recency settings.

sage

Quoted 316 lines · Jason Dillaman

What's your cache mode? In the master branch, I would expect that class method ops should force a promotion to the cache tier if the base tier is an EC pool [1].

[1] https://github.com/ceph/ceph/blob/master/src/osd/OSD.cc#L8905

--

Jason Dillaman

----- Original Message -----

Quoted 42 lines

From: "Nick Fisk" <[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency setting.
I'm guessing that the info command does some sort of read and then a write.
In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1 min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1 min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest:
failed
to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed to
open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 0
set pool 12 min_read_recency_for_promote to 0
Quoted 256 lines
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 241 lines

-----Original Message-----
From: Nick Fisk [mailto:[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 33 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <[email protected]>;
[email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 2 lines · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman
<[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to
reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think
I may
have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that
recency
fix on Infernalis. Initially I thought this was a flushing issue as I just
assumed
those objects shouldn't get flushed out at all. But after reading your email
where you said it forced the promotion, it struck me that the broken recency
behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above
again and this time it worked. Does this make sense?

Nick

Quoted 163 lines

sage

Quoted 54 lines

-Sam

Quoted 52 lines

--

Jason Dillaman

----- Original Message -----

Quoted 46 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 16 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 5 lines

Are you running with an EC pool behind the cache tier? I know
there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 7 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the
client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 40 lines
Quoted 40 lines
Quoted 40 lines

Jason? Sam?
sage

Quoted 34 lines
Quoted 34 lines

--

Jason Dillaman

----- Original Message -----

Quoted 26 lines

From: "Nick Fisk" <[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone
confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 32 lines
Quoted 32 lines
Quoted 32 lines
Quoted 19 lines
Quoted 14 lines
Quoted 7 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 7 lines
Quoted 5 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#14 lore raw
In reply to a message not in the archive

Hi Jason,

It's in writeback mode.

Nick

Quoted 314 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Jason Dillaman
Sent: 11 February 2016 18:40
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: Sage Weil <[email protected]>; Samuel Just <[email protected]>; ceph- [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

What's your cache mode? In the master branch, I would expect that class method ops should force a promotion to the cache tier if the base tier is an EC pool [1].

[1] https://github.com/ceph/ceph/blob/master/src/osd/OSD.cc#L8905

--

Jason Dillaman

----- Original Message -----

Quoted 11 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency

setting.

Quoted 1 line

I'm guessing that the info command does some sort of read and then a

write.

Quoted 21 lines

In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1
min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1
min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99 rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest:
Quoted 8 lines
failed to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed
to open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1
min_read_recency_for_promote 0 set pool 12
min_read_recency_for_promote to 0 nick@Ceph-Test:~$ rbd -p cache1

info

Quoted 43 lines

Test99 rbd image 'Test99':

        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 31 lines

-----Original Message-----
From: Nick Fisk [mailto:nick-ksME7r3P/[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 23 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <nick-ksME7r3P/[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 2 lines · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or

v9.2.0.

Quoted 69 lines
Quoted 69 lines
Quoted 9 lines

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency fix on Infernalis. Initially I thought this was a flushing issue as I just assumed those objects shouldn't get flushed out at all. But after reading your email where you said it forced the promotion, it struck me that the broken recency behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above again and this time it worked. Does this make sense?

Nick

Quoted 36 lines

sage

Quoted 32 lines

-Sam

Quoted 30 lines

--

Jason Dillaman

----- Original Message -----

Quoted 24 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <nick-ksME7r3P/[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 16 lines · Nick Fisk
Quoted 15 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be

evicted.

Quoted 88 lines
Quoted 88 lines
Quoted 88 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 39 lines
Quoted 39 lines
Quoted 39 lines

Jason? Sam?
sage

Quoted 33 lines
Quoted 33 lines

--

Jason Dillaman

----- Original Message -----

Quoted 25 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines

failed to bind the UNIX domain socket to
'/var/run/ceph/ceph-client.admin.asok': (17) File
exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95)
Operation not supported

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

Nick

_______________________________________________

Quoted 27 lines
Quoted 27 lines
Quoted 27 lines
Quoted 27 lines
Quoted 25 lines
Quoted 14 lines
Quoted 8 lines
Quoted 7 lines
Quoted 3 lines

ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 7 lines
Quoted 5 lines
Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): 5848cd48.9Ro.9Gf.h0.1onaHAyHUe-ImYt9qTNe79BDgjK7y7TUQ@public.gmane.org

#16 lore raw

I think I see the problem. It looks like you are performing ops directly against the cache tier instead of the base tier (assuming cache1 is your cache pool). Here are my steps against master where the object is successfully promoted upon 'rbd info':

# ceph osd erasure-code-profile set teuthologyprofile ruleset-failure-domain=osd m=1 k=2
# ceph osd pool delete rbd rbd --yes-i-really-really-mean-it
pool 'rbd' removed
# ceph osd pool create rbd 4 4 erasure teuthologyprofile
pool 'rbd' created
# ceph osd pool create cache 4
pool 'cache' created
# ceph osd tier add rbd cache
pool 'cache' is now (or already was) a tier of 'rbd'
# ceph osd tier cache-mode cache writeback
set cache-mode for pool 'cache' to writeback
# ceph osd tier set-overlay rbd cache
overlay for 'rbd' is now (or already was) 'cache'
# ceph osd pool set cache hit_set_type bloom
set pool 2 hit_set_type to bloom
# ceph osd pool set cache hit_set_count 8
set pool 2 hit_set_count to 8
# ceph osd pool set cache hit_set_period 60
set pool 2 hit_set_period to 60
# ceph osd pool set cache target_max_objects 250
set pool 2 target_max_objects to 250
# rbd -p rbd create test --size=1M
# for x in {0..10}; do rbd -p rbd info test > /dev/null 2>/dev/null ; done
# rados -p cache ls
rbd_id.test
test.rbd
rbd_directory
rbd_header.101944ba7335
# rados -p cache cache-flush rbd_id.test
# rados -p cache cache-evict rbd_id.test
# rados -p cache ls
test.rbd
rbd_directory
rbd_header.101944ba7335
# rbd -p rbd info test
rbd image 'test':
	size 1024 kB in 1 objects
	order 22 (4096 kB objects)
	block_name_prefix: rbd_data.101944ba7335
	format: 2
	features: layering
	flags: 
# rados -p cache ls
rbd_id.test
test.rbd
rbd_directory
rbd_header.101944ba7335
Signature · 7 lines
Jason Dillaman 
Red Hat Ceph Storage Engineering 
[email protected] 
http://www.redhat.com 


----- Original Message -----
Quoted 279 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency setting. I'm guessing that the info command does some sort of read and then a write. In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1 min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1 min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest: failed
to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed to open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 0
set pool 12 min_read_recency_for_promote to 0
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 227 lines

-----Original Message-----
From: Nick Fisk [mailto:nick-ksME7r3P/[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 30 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <nick-ksME7r3P/[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 1 line · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may
have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency
fix on Infernalis. Initially I thought this was a flushing issue as I just assumed
those objects shouldn't get flushed out at all. But after reading your email
where you said it forced the promotion, it struck me that the broken recency
behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above
again and this time it worked. Does this make sense?

Nick

Quoted 155 lines

sage

Quoted 50 lines

-Sam

Quoted 48 lines

--

Jason Dillaman

----- Original Message -----

Quoted 42 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <nick-ksME7r3P/[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 15 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <nick-ksME7r3P/[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can
someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 39 lines
Quoted 39 lines
Quoted 39 lines

Jason? Sam?
sage

Quoted 33 lines
Quoted 33 lines

--

Jason Dillaman

----- Original Message -----

Quoted 25 lines

From: "Nick Fisk" <nick-ksME7r3P/[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 31 lines
Quoted 31 lines
Quoted 31 lines
Quoted 19 lines
Quoted 14 lines
Quoted 7 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 6 lines
Quoted 4 lines

--
To unsubscribe from this list: send the line "unsubscribe
ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

#17 lore raw

I was able to reproduce this on master:

Quoted 25 lines · Jason Dillaman

I think I see the problem. It looks like you are performing ops directly against the cache tier instead of the base tier (assuming cache1 is your cache pool). Here are my steps against master where the object is successfully promoted upon 'rbd info':

# ceph osd erasure-code-profile set teuthologyprofile ruleset-failure-domain=osd m=1 k=2
# ceph osd pool delete rbd rbd --yes-i-really-really-mean-it
pool 'rbd' removed
# ceph osd pool create rbd 4 4 erasure teuthologyprofile
pool 'rbd' created
# ceph osd pool create cache 4
pool 'cache' created
# ceph osd tier add rbd cache
pool 'cache' is now (or already was) a tier of 'rbd'
# ceph osd tier cache-mode cache writeback
set cache-mode for pool 'cache' to writeback
# ceph osd tier set-overlay rbd cache
overlay for 'rbd' is now (or already was) 'cache'
# ceph osd pool set cache hit_set_type bloom
set pool 2 hit_set_type to bloom
Quoted 8 lines
# ceph osd pool set cache hit_set_count 8
set pool 2 hit_set_count to 8
# ceph osd pool set cache hit_set_period 60
set pool 2 hit_set_period to 60
# ceph osd pool set cache target_max_objects 250
set pool 2 target_max_objects to 250

set pool cache min_read_recency_for_promote 4

Quoted 19 lines
# rbd -p rbd create test --size=1M
# for x in {0..10}; do rbd -p rbd info test > /dev/null 2>/dev/null ; done
# rados -p cache ls
rbd_id.test
test.rbd
rbd_directory
rbd_header.101944ba7335
# rados -p cache cache-flush rbd_id.test
# rados -p cache cache-evict rbd_id.test
# rados -p cache ls
test.rbd
rbd_directory
rbd_header.101944ba7335
Quoted 8 lines
# rbd -p rbd info test
rbd image 'test':
	size 1024 kB in 1 objects
	order 22 (4096 kB objects)
	block_name_prefix: rbd_data.101944ba7335
	format: 2
	features: layering
	flags: 

And then I get EOPNOSUPP too.

The problem is the get_id op does sync_read, which files.

I think Nick's suggestion is the right one: if we get EOPNOSUPP we force a promotion. Not sure how tricky that will be to get right, though. A workaround for rbd might be to put the info in an xattr instead of in the data payload.. that's probably more efficient anyway.

sage

Quoted 301 lines
# rados -p cache ls
rbd_id.test
test.rbd
rbd_directory
rbd_header.101944ba7335
Signature · 7 lines
Jason Dillaman 
Red Hat Ceph Storage Engineering 
[email protected] 
http://www.redhat.com 


----- Original Message -----
Quoted 37 lines

From: "Nick Fisk" <[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency setting. I'm guessing that the info command does some sort of read and then a write. In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1 min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1 min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1 librbd::image::OpenRequest: failed
to retrieve image id: (95) Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState: failed to open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 0
set pool 12 min_read_recency_for_promote to 0
Quoted 242 lines
nick@Ceph-Test:~$ rbd -p cache1 info Test99
rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 227 lines

-----Original Message-----
From: Nick Fisk [mailto:[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 30 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 1 line · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman <[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or v9.2.0.

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real IO?

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may
have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency
fix on Infernalis. Initially I thought this was a flushing issue as I just assumed
those objects shouldn't get flushed out at all. But after reading your email
where you said it forced the promotion, it struck me that the broken recency
behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above
again and this time it worked. Does this make sense?

Nick

Quoted 155 lines

sage

Quoted 50 lines

-Sam

Quoted 48 lines

--

Jason Dillaman

----- Original Message -----

Quoted 42 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 15 lines · Nick Fisk
Quoted 10 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]] On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 4 lines

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't be evicted.

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in the EC pool.

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 39 lines
Quoted 39 lines
Quoted 39 lines

Jason? Sam?
sage

Quoted 33 lines
Quoted 33 lines

--

Jason Dillaman

----- Original Message -----

Quoted 25 lines

From: "Nick Fisk" <[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer map it.

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 31 lines
Quoted 31 lines
Quoted 31 lines
Quoted 19 lines
Quoted 14 lines
Quoted 7 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 7 lines

Nick

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 4 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

Quoted 6 lines

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 6 lines
Quoted 4 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Quoted 3 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

A message that is not in the archive (sent off-list or not yet received): alpine.DEB.2.11.1602111557000.28396-Wo5lQnKln9t9PHm/[email protected]

#19 lore raw

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

Quoted 408 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 11 February 2016 21:00
To: Jason Dillaman <[email protected]>
Cc: Nick Fisk <[email protected]>; Samuel Just <[email protected]>; ceph- [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

I was able to reproduce this on master:

Quoted 1 line · Jason Dillaman

I think I see the problem. It looks like you are performing ops directly

against the cache tier instead of the base tier (assuming cache1 is your cache pool). Here are my steps against master where the object is successfully promoted upon 'rbd info':

Quoted 25 lines
# ceph osd erasure-code-profile set teuthologyprofile
ruleset-failure-domain=osd m=1 k=2
# ceph osd pool delete rbd rbd --yes-i-really-really-mean-it pool
'rbd' removed
# ceph osd pool create rbd 4 4 erasure teuthologyprofile pool 'rbd'
created
# ceph osd pool create cache 4
pool 'cache' created
# ceph osd tier add rbd cache
pool 'cache' is now (or already was) a tier of 'rbd'
# ceph osd tier cache-mode cache writeback set cache-mode for pool
'cache' to writeback
# ceph osd tier set-overlay rbd cache
overlay for 'rbd' is now (or already was) 'cache'
# ceph osd pool set cache hit_set_type bloom set pool 2 hit_set_type
to bloom
Quoted 8 lines
# ceph osd pool set cache hit_set_count 8 set pool 2 hit_set_count to
8
# ceph osd pool set cache hit_set_period 60 set pool 2 hit_set_period
to 60
# ceph osd pool set cache target_max_objects 250 set pool 2
target_max_objects to 250

set pool cache min_read_recency_for_promote 4

Quoted 20 lines
# rbd -p rbd create test --size=1M
# for x in {0..10}; do rbd -p rbd info test > /dev/null 2>/dev/null ;
done
# rados -p cache ls
rbd_id.test
test.rbd
rbd_directory
rbd_header.101944ba7335
# rados -p cache cache-flush rbd_id.test
# rados -p cache cache-evict rbd_id.test
# rados -p cache ls
test.rbd
rbd_directory
rbd_header.101944ba7335
Quoted 8 lines
# rbd -p rbd info test
rbd image 'test':
	size 1024 kB in 1 objects
	order 22 (4096 kB objects)
	block_name_prefix: rbd_data.101944ba7335
	format: 2
	features: layering
	flags:

And then I get EOPNOSUPP too.

The problem is the get_id op does sync_read, which files.

I think Nick's suggestion is the right one: if we get EOPNOSUPP we force a promotion. Not sure how tricky that will be to get right, though. A workaround for rbd might be to put the info in an xattr instead of in the data payload.. that's probably more efficient anyway.

sage

Quoted 9 lines
# rados -p cache ls
rbd_id.test
test.rbd
rbd_directory
rbd_header.101944ba7335

--

Quoted 9 lines

Jason Dillaman
Red Hat Ceph Storage Engineering
[email protected]
http://www.redhat.com

----- Original Message -----

Quoted 2 lines

From: "Nick Fisk" <[email protected]>
To: "Sage Weil" <[email protected]>, "Samuel Just"

<[email protected]>

Quoted 9 lines
Quoted 9 lines

Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Thursday, February 11, 2016 12:46:38 PM
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Hi Sage,

Do you think this will get fixed in time for the Jewel release? It still seems to happen in Master and is definitely related to the recency

setting.

Quoted 1 line
Quoted 1 line

I'm guessing that the info command does some sort of read and then a

write.

Quoted 71 lines
Quoted 71 lines

In the old behaviour the read would have always triggered a promotion?

nick@Ceph-Test:~$ ceph osd pool get cache1
min_read_recency_for_promote
min_read_recency_for_promote: 8
nick@Ceph-Test:~$ ceph osd pool get cache1
min_write_recency_for_promote
min_write_recency_for_promote: 8
nick@Ceph-Test:~$ rbd -p cache1 create Test99 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test99 rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test99
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test99
nick@Ceph-Test:~$ rbd -p cache1 info Test99
2016-02-11 17:39:40.942030 7f0006eb3700 -1
librbd::image::OpenRequest: failed to retrieve image id: (95)
Operation not supported
2016-02-11 17:39:40.942205 7f00066b2700 -1 librbd::ImageState:
failed to open
image: (95) Operation not supported
rbd: error opening image Test99: (95) Operation not supported
nick@Ceph-Test:~$ ceph osd pool set cache1
min_read_recency_for_promote 0 set pool 12
min_read_recency_for_promote to 0 nick@Ceph-Test:~$ rbd -p cache1
info Test99 rbd image 'Test99':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.e8e734689a5e
        format: 2
        features: layering
        flags:
Quoted 29 lines

-----Original Message-----
From: Nick Fisk [mailto:[email protected]]
Sent: 05 February 2016 19:58
To: 'Sage Weil' <[email protected]>; 'Samuel Just' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; [email protected]; [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 20 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 05 February 2016 18:45
To: Samuel Just <[email protected]>
Cc: Jason Dillaman <[email protected]>; Nick Fisk <[email protected]>; [email protected]; [email protected]
Subject: Re: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 2 lines · Samuel Just

On Fri, Feb 5, 2016 at 7:53 AM, Jason Dillaman
<[email protected]>

Quoted 5 lines · wrote:
Quoted 5 lines

#1 and #2 are awkward for existing pools since we would need a tool to inject dummy omap values within existing images. Can the cache tier force-promote it from the EC pool to the cache when an unsupported op is encountered? There is logic like that in jewel/master for handling the proxied writes.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

That sounded familiar but I couldn't find this in the code or history between infernalis and master. And then I went back and was unable to reproduce the a problem on either infernalis branch or

v9.2.0.

Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines

Nick, I was doing

 1013  ./rbd -p ec create foo --size 10
 1014  ./rbd -p ec info foo
 1015  ./rados -p ec-cache cache-flush rbd_id.foo
 1016  ./rados -p ec-cache cache-evict rbd_id.foo
 1017  ./rbd -p ec info foo
 1018  ./rados -p ec-cache ls -
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

The rbd.get_id is successfully forcing a promotion.

Which makes me think something else is going on... Nick, can you try to reproduce this with a userspace librbd client? 'rbd info' will do a few basic operations, but if that isn't problematic, try 'rbd bench-write' or 'rbd export', which will do real

IO?

Quoted 55 lines
Quoted 55 lines
Quoted 55 lines

Hi Sage,

Just tried again and I can confirm its definitely not working, but I think I may have stumbled on the reason why.

First apologies for not mentioning it before, but I am still running that recency fix on Infernalis. Initially I thought this was a flushing issue as I just assumed those objects shouldn't get flushed out at all. But after reading your email where you said it forced the promotion, it struck me that the broken recency behaviour may have been masking this issue. With the fix it would only promote if the object was hot enough, which it probably in most cases wouldn't be. As a test I set my recency's down to 0 and tried the steps above again and this time it worked. Does this make sense?

Nick

Quoted 36 lines

sage

Quoted 32 lines

-Sam

Quoted 30 lines

--

Jason Dillaman

----- Original Message -----

Quoted 24 lines

From: "Sage Weil" <[email protected]>
To: "Nick Fisk" <[email protected]>
Cc: "Jason Dillaman" <[email protected]>, [email protected], [email protected]
Sent: Friday, February 5, 2016 10:42:17 AM
Subject: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 16 lines · Nick Fisk
Quoted 15 lines

-----Original Message-----
From: ceph-users [mailto:[email protected]]
On Behalf Of Jason Dillaman
Sent: 27 January 2016 14:25
To: Nick Fisk <[email protected]>
Cc: [email protected]
Subject: Re: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Are you running with an EC pool behind the cache tier? I know there was an issue with the first Infernalis release where unsupported ops were being proxied down to the EC pool, resulting in that same error.

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines

Hi Jason, yes I am. 3x Replicated pool on top of an EC pool.

It's probably something similar to what you mention. Either the client should be able to access the RBD header object on the base pool, or it should be flagged so that it can't

be evicted.

Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines

I just confirmed that the rbd_id.$name object doesn't have any omap, so from rados's perspective, flushing and evicting it is fine. But yeah, the cls_rbd ops aren't permitted in

the EC pool.

Quoted 43 lines
Quoted 43 lines
Quoted 43 lines
Quoted 43 lines
Quoted 10 lines
Quoted 10 lines
Quoted 10 lines

In master/jewel we have a cache-pin function that prevents an object from being flushed.

A few options are:

1) Have cls_rbd cache-pin it's objects.

2) Have cls_rbd put an omap key on the object to indirectly do the

same.

Quoted 7 lines
Quoted 7 lines
Quoted 7 lines

3) Add a requires-cls type object flag that keeps hte object out of an EC pool *until* it eventually supports cls ops.

I'd lean toward 1 since it's simple and explicit, and when we eventually make classes work we can remove the cache-pin behavior

from cls_rbd.

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

It's harder to fix in infernalis unless we also backport cache-pin/unpin ops, too, so maybe #2 would be a simple infernalis

workaround?

Quoted 20 lines
Quoted 20 lines
Quoted 20 lines

Jason? Sam?
sage

Quoted 14 lines
Quoted 14 lines

--

Jason Dillaman

----- Original Message -----

Quoted 6 lines

From: "Nick Fisk" <[email protected]>
To: [email protected]
Sent: Wednesday, January 27, 2016 8:46:53 AM
Subject: [ceph-users] Possible Cache Tier Bug - Can someone confirm

Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
Quoted 6 lines

Hi All,

I think I have stumbled on a bug. I'm running Infernalis (Kernel 4.4 on the
client) and it seems that if the RBD header object gets evicted from the cache pool then you can no longer

map it.

Quoted 36 lines
Quoted 36 lines
Quoted 36 lines
Quoted 36 lines
Quoted 14 lines
Quoted 14 lines
Quoted 14 lines
Quoted 14 lines
Quoted 14 lines
Quoted 14 lines

Steps to reproduce

rbd -p cache1 create Test --size=10G rbd - p cache1 map Test

/dev/rbd1 <-Works!!

rbd unmap /dev/rbd1

rados -p cache1 cache-flush rbd_id.Test rados -p cache1 cache-evict rbd_id.Test rbd - p cache1 map Test

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

rbd: sysfs write failed
rbd: map failed: (95) Operation not supported

or with the rbd-nbd client

2016-01-27 13:39:52.686770 7f9e54162b00 -1

asok(0x561837b88360)
AdminSocketConfigObs::init: failed:

AdminSocket::bind_and_listen:

Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines

failed to bind the UNIX domain socket to '/var/run/ceph/ceph-client.admin.asok': (17) File exists

2016-01-27 13:39:52.703987 7f9e32ffd700 -1

librbd::image::OpenRequest:

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

failed to retrieve image id: (95) Operation not supported
rbd-nbd: failed to map, status: (95) Operation not supported

2016-01-27 13:39:52.704138 7f9e327fc700 -1

librbd::ImageState: failed to open image: (95) Operation not supported

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
Quoted 3 lines

Nick

_______________________________________________

Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 4 lines

ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.co
m

_______________________________________________

Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 25 lines
Quoted 15 lines
Quoted 15 lines
Quoted 15 lines
Quoted 9 lines
Quoted 2 lines

ceph-users mailing list [email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

Quoted 7 lines
Quoted 5 lines

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

Quoted 7 lines
Quoted 4 lines
Quoted 2 lines

majordomo

Quoted 1 line

info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More

Quoted 8 lines

majordomo

Quoted 3 lines

info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected] More majordomo info at
http://vger.kernel.org/majordomo-info.html

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

A message that is not in the archive (sent off-list or not yet received): [email protected]

#21 lore raw
Quoted 2 lines · Nick Fisk

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

https://github.com/ceph/ceph/pull/7617

The tangled logic in maybe_handle_cache wasn't respecting the force promotion bool.

sage

#22 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Is this only a problem with EC base tiers or would replicated base tiers see this too?
- ----------------
Robert LeBlanc
PGP Fingerprint 79A2 9CA4 6CC4 45DD A904 C70E E654 3BB2 FA62 B9F1

Quoted 6 lines · Sage Weil
Quoted 2 lines · Nick Fisk

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

https://github.com/ceph/ceph/pull/7617

Quoted 9 lines

The tangled logic in maybe_handle_cache wasn't respecting the force promotion bool.

sage
_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

-----BEGIN PGP SIGNATURE-----
Version: Mailvelope v1.3.4
Comment: https://www.mailvelope.com

wsFcBAEBCAAQBQJWvVgFCRDmVDuy+mK58QAAepwQAIYDDy9BKOqCN6AYg6QK XOipjXIAwU+lwJA9dV6GOLSeztyg03i1h0Nvibww9JuRYoWWDfPmRCqWWCyl qHoa1q3RgByUTlrxQwl2j0oqVdj2Gn238yyZLqqkhvJS4icc1Xl42710xQa8 OZCMmrJZQ6ZF4n9rU4tUZy6+4l+FjhmqGCu4PHw6SK2TiA6SJR4pcMsbFb6Y h5yWHLNJaCNxe3JVI4sd/tDFxU+pnalz4u2/QkUg2I22C1rYOelbvQ8qeVsR TFy3wc62GGqjaZ9+cjvY3VwrsScFh9skz/cBg7ANRs20rdwX74xfdsIUeAdW f1zfNaobOBt0ZbrYcrp28BhjpIik7GriBiFSUaJ/xIWc8wDNSYhAApGUMNhc oLcsl11zpHzAce8z/Jv5uVRH7VG0jqJKQg8t2l09V/LryxcTktrEQctq+6LS zqh46uToc2jpvTvhIwUiT5fhg9NA2j2cOo1lhMgWJBpT41qambgBWAeIXliE oHMexkdpN80Fqv+yXjEyDocDH1c1bTlyXI71btHptQNvC2VtTqoviz96CtEt jOAFV3nfYz36XkAeayH22ExAwwvF8d9FWpnzEnI3cf63QChN3LAk1C52T5Lw T5rp/4kNF3UnTlJ/ejf3twGaR+FSUWMeum4pKpakfpntRH/ZxpU1VSKSL0TM BdYi
=gvlV
-----END PGP SIGNATURE-----
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#23 lore raw
Quoted 5 lines · Robert LeBlanc

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Is this only a problem with EC base tiers or would replicated base tiers see this too?

In general proxying to the base tier will work just fine if its replicated, so this is mostly an EC-only issue. The exception to that is Jason's commit I mentioned earlier that ensures the locking happens in the cache tier.

This was broken while fixing an op reordering issue a few months back, and I believe that fix was backported, so we'll need to do this one as well once it's reviewed and tested.

Thanks, Nick, for figuring out how to reproduce it!

sage

Quoted 46 lines

- ----------------
Robert LeBlanc
PGP Fingerprint 79A2 9CA4 6CC4 45DD A904 C70E E654 3BB2 FA62 B9F1

Quoted 6 lines · Sage Weil
Quoted 2 lines · Nick Fisk

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

https://github.com/ceph/ceph/pull/7617

Quoted 9 lines

The tangled logic in maybe_handle_cache wasn't respecting the force promotion bool.

sage
_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

-----BEGIN PGP SIGNATURE-----
Version: Mailvelope v1.3.4
Comment: https://www.mailvelope.com

wsFcBAEBCAAQBQJWvVgFCRDmVDuy+mK58QAAepwQAIYDDy9BKOqCN6AYg6QK XOipjXIAwU+lwJA9dV6GOLSeztyg03i1h0Nvibww9JuRYoWWDfPmRCqWWCyl qHoa1q3RgByUTlrxQwl2j0oqVdj2Gn238yyZLqqkhvJS4icc1Xl42710xQa8 OZCMmrJZQ6ZF4n9rU4tUZy6+4l+FjhmqGCu4PHw6SK2TiA6SJR4pcMsbFb6Y h5yWHLNJaCNxe3JVI4sd/tDFxU+pnalz4u2/QkUg2I22C1rYOelbvQ8qeVsR TFy3wc62GGqjaZ9+cjvY3VwrsScFh9skz/cBg7ANRs20rdwX74xfdsIUeAdW f1zfNaobOBt0ZbrYcrp28BhjpIik7GriBiFSUaJ/xIWc8wDNSYhAApGUMNhc oLcsl11zpHzAce8z/Jv5uVRH7VG0jqJKQg8t2l09V/LryxcTktrEQctq+6LS zqh46uToc2jpvTvhIwUiT5fhg9NA2j2cOo1lhMgWJBpT41qambgBWAeIXliE oHMexkdpN80Fqv+yXjEyDocDH1c1bTlyXI71btHptQNvC2VtTqoviz96CtEt jOAFV3nfYz36XkAeayH22ExAwwvF8d9FWpnzEnI3cf63QChN3LAk1C52T5Lw T5rp/4kNF3UnTlJ/ejf3twGaR+FSUWMeum4pKpakfpntRH/ZxpU1VSKSL0TM BdYi
=gvlV
-----END PGP SIGNATURE-----
_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

#24 lore raw
In reply to Sage Weil
Quoted 8 lines · Sage Weil
Quoted 2 lines · Nick Fisk

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

https://github.com/ceph/ceph/pull/7617

The tangled logic in maybe_handle_cache wasn't respecting the force promotion bool.

So, the cause on hammer was entirely different than on master. There we broke things during a refactor, but on hammer we just hadn't backported a fix. I've prepared a pull request for that:

	https://github.com/ceph/ceph/pull/7622

Nick, do you mind verifying that this fixes things for you?

sage

A message that is not in the archive (sent off-list or not yet received): alpine.DEB.2.11.1602120730010.4107-Wo5lQnKln9t9PHm/[email protected]

#26 lore raw
Quoted 20 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 12 February 2016 13:15
To: Nick Fisk <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; 'Samuel Just' <[email protected]>; [email protected]; ceph- [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 8 lines · Sage Weil
Quoted 2 lines · Nick Fisk

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

https://github.com/ceph/ceph/pull/7617

The tangled logic in maybe_handle_cache wasn't respecting the force promotion bool.

Quoted 7 lines

So, the cause on hammer was entirely different than on master. There we broke things during a refactor, but on hammer we just hadn't backported a fix. I've prepared a pull request for that:

	https://github.com/ceph/ceph/pull/7622

Nick, do you mind verifying that this fixes things for you?

Yeah sure, I'm just running a few promotion benchmarks, but will get on it afterwards.

Quoted 2 lines

sage

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

A message that is not in the archive (sent off-list or not yet received): [email protected]

#28 lore raw
Quoted 33 lines

-----Original Message-----
From: Nick Fisk [mailto:[email protected]]
Sent: 12 February 2016 13:31
To: 'Sage Weil' <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; 'Samuel Just' <[email protected]>; [email protected]; ceph- [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 24 lines

-----Original Message-----
From: [email protected] [mailto:ceph-devel- [email protected]] On Behalf Of Sage Weil
Sent: 12 February 2016 13:15
To: Nick Fisk <[email protected]>
Cc: 'Jason Dillaman' <[email protected]>; 'Samuel Just' <[email protected]>; [email protected]; ceph- [email protected]
Subject: RE: cls_rbd ops on rbd_id.$name objects in EC pool

Quoted 8 lines · Sage Weil
Quoted 2 lines · Nick Fisk

That’s a relief, I was sensing a major case of face palm occuring when I read Jason's email!!!

https://github.com/ceph/ceph/pull/7617

The tangled logic in maybe_handle_cache wasn't respecting the force promotion bool.

So, the cause on hammer was entirely different than on master. There we broke things during a refactor, but on hammer we just hadn't backported a fix. I've prepared a pull request for that:

Quoted 6 lines
Quoted 3 lines
	https://github.com/ceph/ceph/pull/7622

Nick, do you mind verifying that this fixes things for you?

Yeah sure, I'm just running a few promotion benchmarks, but will get on it afterwards.

Sorry for the delay, but all looks good to me

nick@Ceph-Test:~$ rbd -p ecpool create Test12 --size=10G
nick@Ceph-Test:~$ rbd -p cache1 info Test12
rbd image 'Test12':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.f2b484c56c6ba
        format: 2
        features: layering
        flags:
nick@Ceph-Test:~$ rados -p cache1 cache-flush rbd_id.Test12
nick@Ceph-Test:~$ rados -p cache1 cache-evict rbd_id.Test12
nick@Ceph-Test:~$ ceph osd pool set cache1 min_read_recency_for_promote 8
set pool 12 min_read_recency_for_promote to 8
nick@Ceph-Test:~$ rbd -p cache1 info Test12
rbd image 'Test12':
        size 10240 MB in 2560 objects
        order 22 (4096 kB objects)
        block_name_prefix: rbd_data.f2b484c56c6ba
        format: 2
        features: layering
        flags:
Quoted 3 lines
Quoted 3 lines

sage

_______________________________________________
ceph-users mailing list
[email protected]
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com