Project

General

Profile

Bug #1628

segfault attempting to map an rbd snapshot

Added by John Leach over 12 years ago. Updated over 12 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
librbd
Target version:
% Done:

0%

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

Description

# gdb --args rbd -n client.srv-3ucz4 --snap=two map test --user srv-3ucz4 --secret secret 
Reading symbols from /usr/bin/rbd...(no debugging symbols found)...done.
(gdb) run
Starting program: /usr/bin/rbd -n client.srv-3ucz4 --snap=two map test --user srv-3ucz4 --secret secret
[Thread debugging using libthread_db enabled]
[New Thread 0x7ffff5f75700 (LWP 1321)]

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff7bcb170 in librbd::snap_set(librbd::ImageCtx*, char const*) () from /usr/lib/librbd.so.1
(gdb) bt
#0  0x00007ffff7bcb170 in librbd::snap_set(librbd::ImageCtx*, char const*) () from /usr/lib/librbd.so.1
#1  0x000000000044dd88 in main ()
(gdb) 

same with the test@two useage

device maps fine on it's own, just not snapshot (not sure if I'm supposed to be able to map a snapshot, but it certainly shouldn't segfault!)

this a build from master from a couple of days ago.

History

#1 Updated by Josh Durgin over 12 years ago

  • Target version set to v0.38

This is a bug in the rbd command line tool - it accepts snapname but doesn't use it for map/unmap. Additionally, it doesn't check which command it's using before calling image.snap_set(). Mapping/unmapping shouldn't call any librbd functions.

#2 Updated by Josh Durgin over 12 years ago

  • Assignee set to Josh Durgin

#3 Updated by Sage Weil over 12 years ago

  • Status changed from New to Resolved

Also available in: Atom PDF