Project

General

Profile

Actions

Bug #2352

closed

ceph -s without a conf file doesn't work when it should

Added by Greg Farnum almost 12 years ago. Updated almost 12 years ago.

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

0%

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

Description

Hi,

I tried to connect to a small Ceph setup on my desktop without cephx and
that failed:

root@stack01:~# ceph -m wido-desktop.widodh.nl:6789 -s
global_init: unable to open config file.
root@stack01:~#

I however worked with:

root@stack01:~# ceph -m wido-desktop.widodh.nl:6789 -c /dev/null -s
2012-04-26 14:55:33.828524 pg v148: 594 pgs: 594 active+clean; 0
bytes data, 7740 KB used, 70571 MB / 76800 MB avail
2012-04-26 14:55:33.829622 mds e1: 0/0/1 up
2012-04-26 14:55:33.836144 osd e14: 3 osds: 3 up, 3 in
2012-04-26 14:55:33.886429 log 2012-04-26 14:52:50.674430 osd.1
[2a00:f10:11c:ab:52e5:49ff:fec2:c976]:6807/28366 12 : [INF] 1.2b scrub ok
2012-04-26 14:55:33.892423 mon e1: 1 mons at
{desktop=[2a00:f10:11c:ab:52e5:49ff:fec2:c976]:6789/0}
root@stack01:~#

I quick look at global_init.cc showed me why this happened, it simply
looks for a configuration file to open and when it can't it fails.

But if a monitor address is set, a config file shouldn't be mandatory.

It could be accomplished rather simple by setting the flag
CINIT_FLAG_NO_DEFAULT_CONFIG_FILE if a mon_host has been set, but to do
that conf->parse_argv(args); should move a few lines up.

Comments? Thoughts?

Wido

Related issues 1 (0 open1 closed)

Has duplicate Ceph - Feature #2213: rbd: shouldn't need config file to get helpResolved03/26/2012

Actions
Actions #1

Updated by Greg Farnum almost 12 years ago

  • Status changed from New to In Progress

I've got a stupid hack that makes this work, but I'm going to see if I can generalize our common config stuff so this can be dealt with generically.

Actions #2

Updated by Greg Farnum almost 12 years ago

  • Status changed from In Progress to Resolved

Okay, just made it not care about config files in wip-2352.

Actions

Also available in: Atom PDF