Skip to contentSkip to conversation

occasional failure to unmap rbd

ceph-users Shinobu Kinjo 3 participants 9 messages Sep 26, 2015 – Nov 24, 2015 6 messages not in the archive

lore
Share & tools
lore
#5 lore raw
In reply to a message not in the archive

I think it's more helpful to put returned value in:

# ./src/krbd.cc
530       cerr << "rbd: sysfs write failed" << std::endl;

like:

530 cerr << "rbd: sysfs write failed (" << r << ")" << std::endl;

So that we exactly know what **write** complains about. Because **write** has some return values in case of error.

What do you think?

Shinobu

----- Original Message -----
From: "Jeff Epstein" <[email protected]>
To: "Jan Schermer" <[email protected]>
Cc: [email protected]
Sent: Saturday, September 26, 2015 2:44:00 AM
Subject: Re: [ceph-users] occasional failure to unmap rbd

Quoted 3 lines · Jan Schermer

What are you looking for in lsof? Did you try looking for the major/minor number of the rbd device?
Things that could hold the device are devicemapper, lvm, swraid and possibly many more, not sure if all that shows in lsof output...

I searched for the rbd's mounted block device name, of course, which didn't turn up anything. Just now I tried searching for the minor device number, but I didn't see anything obviously useful. lsof usually just shows processes, so if the the device is being held by a kernel module or inaccurate refcount, lsof wouldn't help.

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

#6 lore raw
Quoted 5 lines · Shinobu Kinjo

I think it's more helpful to put returned value in:

# ./src/krbd.cc
530       cerr << "rbd: sysfs write failed" << std::endl;
Quoted 8 lines

like:

530 cerr << "rbd: sysfs write failed (" << r << ")" << std::endl;

So that we exactly know what **write** complains about. Because **write** has some return values in case of error.

What do you think?

It's already doing that:

rbd: sysfs write failed
rbd: unmap failed: (16) Device or resource busy

sysfs_write_rbd_remove() return value is propagated up and reported. The code is written in such a way that return values are preserved and never overwritten (hopefully!).

Thanks,

Ilya

#7 lore raw

Thanks!
I completely overlooked that -;

Shinobu

----- Original Message -----
From: "Ilya Dryomov" <[email protected]>
To: "Shinobu Kinjo" <[email protected]>
Cc: "Ceph Development" <[email protected]>
Sent: Saturday, September 26, 2015 5:52:50 PM
Subject: Re: [CEPH-DEVEL] [ceph-users] occasional failure to unmap rbd

Quoted 5 lines · Shinobu Kinjo

I think it's more helpful to put returned value in:

# ./src/krbd.cc
530       cerr << "rbd: sysfs write failed" << std::endl;
Quoted 8 lines

like:

530 cerr << "rbd: sysfs write failed (" << r << ")" << std::endl;

So that we exactly know what **write** complains about. Because **write** has some return values in case of error.

What do you think?

It's already doing that:

rbd: sysfs write failed
rbd: unmap failed: (16) Device or resource busy

sysfs_write_rbd_remove() return value is propagated up and reported. The code is written in such a way that return values are preserved and never overwritten (hopefully!).

Thanks,

Ilya

#8 lore raw

I am having the same issue here.

root@paris3:/etc/neutron# rbd unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy
root@paris3:/etc/neutron# rbd info -p volumes
volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2
2015-11-23 22:42:06.842697 7f2d57e49700  0 -- :/2760503703 >>
10.90.90.4:6789/0 pipe(0x1773250 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x17734e0).fault
rbd image 'volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2':
size 500 GB in 128000 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.1b6d9e2aaa998b
format: 2
features: layering
root@paris3:/etc/neutron# rados -p volumes listwatchers
rbd_header.1b6d9e2aaa998b
2015-11-23 22:42:58.546723 7fec94fec700  0 -- :/2519796249 >>
10.90.90.4:6789/0 pipe(0x9cf260 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x9cf4f0).fault
watcher=10.90.90.3:0/3293327848 client.8471177 cookie=1
root@paris3:/etc/neutron# ps ax | grep rbd
 7814 ?        S      0:00 [jbd2/rbd0-8]
11003 ?        S      0:00 [jbd2/rbd1-8]
14042 ?        S      0:00 [jbd2/rbd2p1-8]
24228 ?        S      0:00 [jbd2/rbd3-8]
root@paris3:/etc/neutron# ceph --version
ceph version 0.80.11 (8424145d49264624a3b0a204aedb127835161070)
root@paris3:/etc/neutron# ls /sys/block/rbd0/holders/
returns nothing
root@paris3:/etc/neutron# fuser -amv /dev/rbd0
                     USER        PID ACCESS COMMAND
/dev/rbd0:
root@paris3:/etc/neutron# lsof /dev/rbd0
returns nothing

Please advise,
Markus

Quoted 44 lines · Shinobu Kinjo

Thanks!
I completely overlooked that -;

Shinobu

----- Original Message -----
From: "Ilya Dryomov" <[email protected]>
To: "Shinobu Kinjo" <[email protected]>
Cc: "Ceph Development" <[email protected]>
Sent: Saturday, September 26, 2015 5:52:50 PM
Subject: Re: [CEPH-DEVEL] [ceph-users] occasional failure to unmap rbd

Quoted 5 lines · Shinobu Kinjo

I think it's more helpful to put returned value in:

# ./src/krbd.cc
530       cerr << "rbd: sysfs write failed" << std::endl;
Quoted 8 lines

like:

530 cerr << "rbd: sysfs write failed (" << r << ")" << std::endl;

So that we exactly know what **write** complains about. Because **write** has some return values in case of error.

What do you think?

It's already doing that:

rbd: sysfs write failed
rbd: unmap failed: (16) Device or resource busy

sysfs_write_rbd_remove() return value is propagated up and reported. The code is written in such a way that return values are preserved and never overwritten (hopefully!).

Thanks,

Ilya
--
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

#10 lore raw
In reply to a message not in the archive
Quoted 1 line · Markus Kienast

I am having the same issue here.

Which kernel are you running? Could you attach your dmesg?

Quoted 5 lines
root@paris3:/etc/neutron# rbd unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy
Quoted 15 lines
root@paris3:/etc/neutron# rbd info -p volumes
volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2
2015-11-23 22:42:06.842697 7f2d57e49700  0 -- :/2760503703 >>
10.90.90.4:6789/0 pipe(0x1773250 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x17734e0).fault
rbd image 'volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2':
size 500 GB in 128000 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.1b6d9e2aaa998b
format: 2
features: layering
root@paris3:/etc/neutron# rados -p volumes listwatchers
rbd_header.1b6d9e2aaa998b
2015-11-23 22:42:58.546723 7fec94fec700  0 -- :/2519796249 >>
10.90.90.4:6789/0 pipe(0x9cf260 sd=3 :0 s=1 pgs=0 cs=0 l=1 c=0x9cf4f0).fault

Did you root cause these faults?

Quoted 4 lines

watcher=10.90.90.3:0/3293327848 client.8471177 cookie=1

root@paris3:/etc/neutron# ps ax | grep rbd
 7814 ?        S      0:00 [jbd2/rbd0-8]

Was there an ext filesystem involved? How was it umounted - do you have a "umount <mountpoint>" process stuck in D state?

Quoted 7 lines
11003 ?        S      0:00 [jbd2/rbd1-8]
14042 ?        S      0:00 [jbd2/rbd2p1-8]
24228 ?        S      0:00 [jbd2/rbd3-8]
root@paris3:/etc/neutron# ceph --version
ceph version 0.80.11 (8424145d49264624a3b0a204aedb127835161070)
Quoted 6 lines
root@paris3:/etc/neutron# ls /sys/block/rbd0/holders/
returns nothing
root@paris3:/etc/neutron# fuser -amv /dev/rbd0
                     USER        PID ACCESS COMMAND
/dev/rbd0:

What's the output of "cat /sys/bus/rbd/devices/0/client_id"?

What's the output of "sudo cat /sys/kernel/debug/ceph/*/osdc"?

Thanks,

Ilya

#11 lore raw

Kernel Version

elias@paris3:~$ uname -a
Linux paris3.sfe.tv 3.16.0-28-generic #38-Ubuntu SMP Sat Dec 13
16:13:28 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

Output of dmesg and /var/log/dmesg attached. But does not show much except for one mon being down. The mon is down for hardware reasons.

Quoted 27 lines · Ilya Dryomov
Quoted 1 line · Markus Kienast

I am having the same issue here.

Which kernel are you running? Could you attach your dmesg?

Quoted 5 lines
root@paris3:/etc/neutron# rbd unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy
Quoted 15 lines
root@paris3:/etc/neutron# rbd info -p volumes
volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2
2015-11-23 22:42:06.842697 7f2d57e49700  0 -- :/2760503703 >>
10.90.90.4:6789/0 pipe(0x1773250 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x17734e0).fault
rbd image 'volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2':
size 500 GB in 128000 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.1b6d9e2aaa998b
format: 2
features: layering
root@paris3:/etc/neutron# rados -p volumes listwatchers
rbd_header.1b6d9e2aaa998b
2015-11-23 22:42:58.546723 7fec94fec700  0 -- :/2519796249 >>
10.90.90.4:6789/0 pipe(0x9cf260 sd=3 :0 s=1 pgs=0 cs=0 l=1 c=0x9cf4f0).fault
Quoted 1 line

Did you root cause these faults?

Hardware failure caused these faults.

Quoted 8 lines
Quoted 5 lines

watcher=10.90.90.3:0/3293327848 client.8471177 cookie=1

root@paris3:/etc/neutron# ps ax | grep rbd
 7814 ?        S      0:00 [jbd2/rbd0-8]

Was there an ext filesystem involved? How was it umounted - do you have a "umount <mountpoint>" process stuck in D state?

Yes, all these RBDs are formatted with ext4. I am regularly using them with openstack and have never had any problems.
I did "unmount <mountpoint>" and the unmount process did actually finish just fine.
Where can I look up, if it is stuck in "D" state?

Quoted 8 lines
Quoted 8 lines
11003 ?        S      0:00 [jbd2/rbd1-8]
14042 ?        S      0:00 [jbd2/rbd2p1-8]
24228 ?        S      0:00 [jbd2/rbd3-8]
root@paris3:/etc/neutron# ceph --version
ceph version 0.80.11 (8424145d49264624a3b0a204aedb127835161070)
Quoted 8 lines
Quoted 6 lines
root@paris3:/etc/neutron# ls /sys/block/rbd0/holders/
returns nothing
root@paris3:/etc/neutron# fuser -amv /dev/rbd0
                     USER        PID ACCESS COMMAND
/dev/rbd0:

What's the output of "cat /sys/bus/rbd/devices/0/client_id"?

root@paris3:~# cat /sys/bus/rbd/devices/0/client_id
client8471177
Quoted 2 lines

What's the output of "sudo cat /sys/kernel/debug/ceph/*/osdc"?

root@paris3:~# ls -l /sys/kernel/debug/ceph/
total 0
drwxr-xr-x 2 root root 0 Feb  4  2015
32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711
drwxr-xr-x 2 root root 0 Nov 23 11:41
32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177/osdc
has no output
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711/osdc
hangs with no output

BTW, I have mapped these RBDs as user cinder not as admin.

But using -n produces the same error:

root@paris3:~# rbd -n client.cinder  unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy

I appreciate your help!
Markus

Quoted 4 lines

Thanks,

Ilya

#12 lore raw
Quoted 88 lines · Markus Kienast

Kernel Version

elias@paris3:~$ uname -a
Linux paris3.sfe.tv 3.16.0-28-generic #38-Ubuntu SMP Sat Dec 13
16:13:28 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

Output of dmesg and /var/log/dmesg attached. But does not show much except for one mon being down. The mon is down for hardware reasons.

Quoted 27 lines · Ilya Dryomov
Quoted 1 line · Markus Kienast

I am having the same issue here.

Which kernel are you running? Could you attach your dmesg?

Quoted 5 lines
root@paris3:/etc/neutron# rbd unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy
Quoted 15 lines
root@paris3:/etc/neutron# rbd info -p volumes
volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2
2015-11-23 22:42:06.842697 7f2d57e49700  0 -- :/2760503703 >>
10.90.90.4:6789/0 pipe(0x1773250 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x17734e0).fault
rbd image 'volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2':
size 500 GB in 128000 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.1b6d9e2aaa998b
format: 2
features: layering
root@paris3:/etc/neutron# rados -p volumes listwatchers
rbd_header.1b6d9e2aaa998b
2015-11-23 22:42:58.546723 7fec94fec700  0 -- :/2519796249 >>
10.90.90.4:6789/0 pipe(0x9cf260 sd=3 :0 s=1 pgs=0 cs=0 l=1 c=0x9cf4f0).fault
Quoted 1 line

Did you root cause these faults?

Hardware failure caused these faults.

Quoted 8 lines
Quoted 5 lines

watcher=10.90.90.3:0/3293327848 client.8471177 cookie=1

root@paris3:/etc/neutron# ps ax | grep rbd
 7814 ?        S      0:00 [jbd2/rbd0-8]

Was there an ext filesystem involved? How was it umounted - do you have a "umount <mountpoint>" process stuck in D state?

Yes, all these RBDs are formatted with ext4. I am regularly using them with openstack and have never had any problems.
I did "unmount <mountpoint>" and the unmount process did actually finish just fine.
Where can I look up, if it is stuck in "D" state?

Quoted 8 lines
Quoted 8 lines
11003 ?        S      0:00 [jbd2/rbd1-8]
14042 ?        S      0:00 [jbd2/rbd2p1-8]
24228 ?        S      0:00 [jbd2/rbd3-8]
root@paris3:/etc/neutron# ceph --version
ceph version 0.80.11 (8424145d49264624a3b0a204aedb127835161070)
Quoted 8 lines
Quoted 6 lines
root@paris3:/etc/neutron# ls /sys/block/rbd0/holders/
returns nothing
root@paris3:/etc/neutron# fuser -amv /dev/rbd0
                     USER        PID ACCESS COMMAND
/dev/rbd0:

What's the output of "cat /sys/bus/rbd/devices/0/client_id"?

root@paris3:~# cat /sys/bus/rbd/devices/0/client_id
client8471177
Quoted 2 lines

What's the output of "sudo cat /sys/kernel/debug/ceph/*/osdc"?

root@paris3:~# ls -l /sys/kernel/debug/ceph/
total 0
drwxr-xr-x 2 root root 0 Feb  4  2015
32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711
drwxr-xr-x 2 root root 0 Nov 23 11:41
32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177
Quoted 3 lines
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177/osdc
has no output

This means there are no outstanding/hung rbd I/Os. According to you, umount completed successfully, and yet there is a jbd2/rbd0-8 kthread hanging around, keeping /dev/rbd0 open and holding a ref to it. A quick search produced two similar reports:

[1] https://ask.fedoraproject.org/en/question/7572/how-to-stop-kernel-ext4-journaling-thread/
[2] http://lists.openwall.net/linux-ext4/2015/10/24/11

The only difference as far I can tell is those people noticed the jbd2 thread because they wanted to run fsck, while you ran into it because you tried to do "rbd unmap". Neither mentions rbd.

Look at [2], did you at any point see any similar errors in dmesg?

Quoted 4 lines
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711/osdc
hangs with no output

It shouldn't hang, so it could be unrelated. Given the "Feb 4 2015" timestamp, I'm going to assume you haven't rebooted this box in a long time? If so, do you remember what happened around that date?

Do you keep syslog archives? I'd be interested in seeing everything you have for Feb 3 - Feb 5.

To try to figure out where it's hanging, can you do

# cat >/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711/osdc
< it'll hang, grab its PID from ps output >
# cat /proc/$PID/stack

Thanks,

Ilya

#13 lore raw
Quoted 105 lines · Ilya Dryomov
Quoted 88 lines · Markus Kienast

Kernel Version

elias@paris3:~$ uname -a
Linux paris3.sfe.tv 3.16.0-28-generic #38-Ubuntu SMP Sat Dec 13
16:13:28 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

Output of dmesg and /var/log/dmesg attached. But does not show much except for one mon being down. The mon is down for hardware reasons.

Quoted 27 lines · Ilya Dryomov
Quoted 1 line · Markus Kienast

I am having the same issue here.

Which kernel are you running? Could you attach your dmesg?

Quoted 5 lines
root@paris3:/etc/neutron# rbd unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy
Quoted 15 lines
root@paris3:/etc/neutron# rbd info -p volumes
volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2
2015-11-23 22:42:06.842697 7f2d57e49700  0 -- :/2760503703 >>
10.90.90.4:6789/0 pipe(0x1773250 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x17734e0).fault
rbd image 'volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2':
size 500 GB in 128000 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.1b6d9e2aaa998b
format: 2
features: layering
root@paris3:/etc/neutron# rados -p volumes listwatchers
rbd_header.1b6d9e2aaa998b
2015-11-23 22:42:58.546723 7fec94fec700  0 -- :/2519796249 >>
10.90.90.4:6789/0 pipe(0x9cf260 sd=3 :0 s=1 pgs=0 cs=0 l=1 c=0x9cf4f0).fault
Quoted 1 line

Did you root cause these faults?

Hardware failure caused these faults.

Quoted 8 lines
Quoted 5 lines

watcher=10.90.90.3:0/3293327848 client.8471177 cookie=1

root@paris3:/etc/neutron# ps ax | grep rbd
 7814 ?        S      0:00 [jbd2/rbd0-8]

Was there an ext filesystem involved? How was it umounted - do you have a "umount <mountpoint>" process stuck in D state?

Yes, all these RBDs are formatted with ext4. I am regularly using them with openstack and have never had any problems.
I did "unmount <mountpoint>" and the unmount process did actually finish just fine.
Where can I look up, if it is stuck in "D" state?

Quoted 8 lines
Quoted 8 lines
11003 ?        S      0:00 [jbd2/rbd1-8]
14042 ?        S      0:00 [jbd2/rbd2p1-8]
24228 ?        S      0:00 [jbd2/rbd3-8]
root@paris3:/etc/neutron# ceph --version
ceph version 0.80.11 (8424145d49264624a3b0a204aedb127835161070)
Quoted 8 lines
Quoted 6 lines
root@paris3:/etc/neutron# ls /sys/block/rbd0/holders/
returns nothing
root@paris3:/etc/neutron# fuser -amv /dev/rbd0
                     USER        PID ACCESS COMMAND
/dev/rbd0:

What's the output of "cat /sys/bus/rbd/devices/0/client_id"?

root@paris3:~# cat /sys/bus/rbd/devices/0/client_id
client8471177
Quoted 2 lines

What's the output of "sudo cat /sys/kernel/debug/ceph/*/osdc"?

root@paris3:~# ls -l /sys/kernel/debug/ceph/
total 0
drwxr-xr-x 2 root root 0 Feb  4  2015
32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711
drwxr-xr-x 2 root root 0 Nov 23 11:41
32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177
Quoted 3 lines
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177/osdc
has no output

This means there are no outstanding/hung rbd I/Os. According to you, umount completed successfully, and yet there is a jbd2/rbd0-8 kthread hanging around, keeping /dev/rbd0 open and holding a ref to it. A quick search produced two similar reports:

[1] https://ask.fedoraproject.org/en/question/7572/how-to-stop-kernel-ext4-journaling-thread/
[2] http://lists.openwall.net/linux-ext4/2015/10/24/11

The only difference as far I can tell is those people noticed the jbd2 thread because they wanted to run fsck, while you ran into it because you tried to do "rbd unmap". Neither mentions rbd.

Quoted 8 lines

Look at [2], did you at any point see any similar errors in dmesg?

Quoted 4 lines
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711/osdc
hangs with no output

It shouldn't hang, so it could be unrelated. Given the "Feb 4 2015"

It should read "so it could be related", of course.

Thanks,

Ilya

#14 lore raw

Unfortunately I have rebooted the server, as I needed the services back online. I did try mapping and unmapping again after reboot and did not see the problem anymore.

However, I will search through my logs and send you everything from Feb 3 - Feb 5.

And if I see the issue again, I will follow all the debug steps described in this thread and post it here.

In the mean time, I have upgraded to the next minor revision from your dragonfly-debian archives. So maybe I do not see the problem anymore due to that.

Many thanks for your help!

Regards,
Markus

Quoted 120 lines · Ilya Dryomov
Quoted 105 lines · Ilya Dryomov
Quoted 88 lines · Markus Kienast

Kernel Version

elias@paris3:~$ uname -a
Linux paris3.sfe.tv 3.16.0-28-generic #38-Ubuntu SMP Sat Dec 13
16:13:28 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

Output of dmesg and /var/log/dmesg attached. But does not show much except for one mon being down. The mon is down for hardware reasons.

Quoted 27 lines · Ilya Dryomov
Quoted 1 line · Markus Kienast

I am having the same issue here.

Which kernel are you running? Could you attach your dmesg?

Quoted 5 lines
root@paris3:/etc/neutron# rbd unmap /dev/rbd0
rbd: failed to remove rbd device: (16) Device or resource busy
rbd: remove failed: (16) Device or resource busy
Quoted 15 lines
root@paris3:/etc/neutron# rbd info -p volumes
volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2
2015-11-23 22:42:06.842697 7f2d57e49700  0 -- :/2760503703 >>
10.90.90.4:6789/0 pipe(0x1773250 sd=3 :0 s=1 pgs=0 cs=0 l=1
c=0x17734e0).fault
rbd image 'volume-f3ab6892-f35e-4b98-8832-efbaaa2f4ca2':
size 500 GB in 128000 objects
order 22 (4096 kB objects)
block_name_prefix: rbd_data.1b6d9e2aaa998b
format: 2
features: layering
root@paris3:/etc/neutron# rados -p volumes listwatchers
rbd_header.1b6d9e2aaa998b
2015-11-23 22:42:58.546723 7fec94fec700  0 -- :/2519796249 >>
10.90.90.4:6789/0 pipe(0x9cf260 sd=3 :0 s=1 pgs=0 cs=0 l=1 c=0x9cf4f0).fault
Quoted 1 line

Did you root cause these faults?

Hardware failure caused these faults.

Quoted 8 lines
Quoted 5 lines

watcher=10.90.90.3:0/3293327848 client.8471177 cookie=1

root@paris3:/etc/neutron# ps ax | grep rbd
 7814 ?        S      0:00 [jbd2/rbd0-8]

Was there an ext filesystem involved? How was it umounted - do you have a "umount <mountpoint>" process stuck in D state?

Yes, all these RBDs are formatted with ext4. I am regularly using them with openstack and have never had any problems.
I did "unmount <mountpoint>" and the unmount process did actually finish just fine.
Where can I look up, if it is stuck in "D" state?

Quoted 8 lines
Quoted 8 lines
11003 ?        S      0:00 [jbd2/rbd1-8]
14042 ?        S      0:00 [jbd2/rbd2p1-8]
24228 ?        S      0:00 [jbd2/rbd3-8]
root@paris3:/etc/neutron# ceph --version
ceph version 0.80.11 (8424145d49264624a3b0a204aedb127835161070)
Quoted 8 lines
Quoted 6 lines
root@paris3:/etc/neutron# ls /sys/block/rbd0/holders/
returns nothing
root@paris3:/etc/neutron# fuser -amv /dev/rbd0
                     USER        PID ACCESS COMMAND
/dev/rbd0:

What's the output of "cat /sys/bus/rbd/devices/0/client_id"?

root@paris3:~# cat /sys/bus/rbd/devices/0/client_id
client8471177
Quoted 2 lines

What's the output of "sudo cat /sys/kernel/debug/ceph/*/osdc"?

root@paris3:~# ls -l /sys/kernel/debug/ceph/
total 0
drwxr-xr-x 2 root root 0 Feb  4  2015
32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711
drwxr-xr-x 2 root root 0 Nov 23 11:41
32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177
Quoted 3 lines
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client8471177/osdc
has no output

This means there are no outstanding/hung rbd I/Os. According to you, umount completed successfully, and yet there is a jbd2/rbd0-8 kthread hanging around, keeping /dev/rbd0 open and holding a ref to it. A quick search produced two similar reports:

[1] https://ask.fedoraproject.org/en/question/7572/how-to-stop-kernel-ext4-journaling-thread/
[2] http://lists.openwall.net/linux-ext4/2015/10/24/11

The only difference as far I can tell is those people noticed the jbd2 thread because they wanted to run fsck, while you ran into it because you tried to do "rbd unmap". Neither mentions rbd.

Quoted 8 lines

Look at [2], did you at any point see any similar errors in dmesg?

Quoted 4 lines
root@paris3:~# cat
/sys/kernel/debug/ceph/32ba3117-e320-49fc-aabd-f100d5a7e94b.client7663711/osdc
hangs with no output

It shouldn't hang, so it could be unrelated. Given the "Feb 4 2015"

It should read "so it could be related", of course.

Thanks,

Ilya