Actions
Bug #350
closedcosd crash when trying a mkfs with a osdmap as "monmap"
Status:
Resolved
Priority:
Low
Assignee:
-
Category:
OSD
Target version:
-
% Done:
0%
Source:
Tags:
Backport:
Regression:
Severity:
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
(gdb) run -i 6 -c /etc/ceph/ceph.conf --mkfs --monmap monmap Starting program: /usr/bin/cosd -i 6 -c /etc/ceph/ceph.conf --mkfs --monmap monmap [Thread debugging using libthread_db enabled] ** WARNING: Ceph is still under heavy development, and is only suitable for ** ** testing and review. Do not trust it with important data. ** terminate called after throwing an instance of 'ceph::buffer::end_of_buffer*' Program received signal SIGABRT, Aborted. 0x00007ffff68c7a75 in raise () from /lib/libc.so.6 (gdb) bt #0 0x00007ffff68c7a75 in raise () from /lib/libc.so.6 #1 0x00007ffff68cb5c0 in abort () from /lib/libc.so.6 #2 0x00007ffff717c8e5 in __gnu_cxx::__verbose_terminate_handler() () from /usr/lib/libstdc++.so.6 #3 0x00007ffff717ad16 in ?? () from /usr/lib/libstdc++.so.6 #4 0x00007ffff717ad43 in std::terminate() () from /usr/lib/libstdc++.so.6 #5 0x00007ffff717ae3e in __cxa_throw () from /usr/lib/libstdc++.so.6 #6 0x00000000005ca06f in MonMap::decode(ceph::buffer::list::iterator&) () #7 0x00000000005e5e9c in MonMap::decode (this=0x7fffffffdee8, fn=<value optimized out>) at mon/MonMap.h:165 #8 MonMap::read (this=0x7fffffffdee8, fn=<value optimized out>) at mon/MonMap.cc:26 #9 0x00000000005c3f1c in MonClient::build_initial_monmap (this=<value optimized out>) at mon/MonClient.cc:52 #10 0x000000000045715b in main (argc=<value optimized out>, argv=<value optimized out>) at cosd.cc:125
Although this is not really a bug, but just a stupid action of a sysadmin, it might be nice if there would be an error: "<file> is not a valid monmap!" instead of crashing like this.
By accident i pulled the map with "ceph osd getmap" instead of "ceph mon getmap".
Took me some time to find what i did wrong. I'm probably not going to be the last person to make this mistake.
Updated by Sage Weil over 13 years ago
- Status changed from New to Resolved
cdb8a98601ca85ddc345eae519c8e8fc25de253f errors out gracefully with 'unable to decode monmap from file xxx' instead of crashing.
Actions