From: Alfredo Deza Date: Wed, 8 Nov 2017 19:50:16 +0000 (-0500) Subject: ceph-volume simple.activate only check for missing id and uuid if file is not passed in X-Git-Tag: v13.0.1~256^2~6 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=826c2709dd5ab0fbf6eb419a735d15e718a7712c;p=ceph.git ceph-volume simple.activate only check for missing id and uuid if file is not passed in Signed-off-by: Alfredo Deza --- diff --git a/src/ceph-volume/ceph_volume/devices/simple/activate.py b/src/ceph-volume/ceph_volume/devices/simple/activate.py index 1a15718e2ee9..e6959aa18060 100644 --- a/src/ceph-volume/ceph_volume/devices/simple/activate.py +++ b/src/ceph-volume/ceph_volume/devices/simple/activate.py @@ -124,10 +124,11 @@ class Activate(object): print(sub_command_help) return args = parser.parse_args(self.argv) - if not args.osd_id and not args.osd_fsid: - terminal.error('ID and FSID are required to find the right OSD to activate') - terminal.error('from a scanned OSD location in /etc/ceph/osd/') - raise RuntimeError('Unable to activate without both ID and FSID') + if not args.file: + if not args.osd_id and not args.osd_fsid: + terminal.error('ID and FSID are required to find the right OSD to activate') + terminal.error('from a scanned OSD location in /etc/ceph/osd/') + raise RuntimeError('Unable to activate without both ID and FSID') # don't allow a CLI flag to specify the JSON dir, because that might # implicitly indicate that it would be possible to activate a json file # at a non-default location which would not work at boot time if the