From 80ab64b2ae3d1a5920ddd9ac007d6d873af013a5 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 21 Nov 2019 16:48:30 -0600 Subject: [PATCH] ceph-daemon: several commands that can infer fsids still require them Signed-off-by: Sage Weil --- src/ceph-daemon/ceph-daemon | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/ceph-daemon/ceph-daemon b/src/ceph-daemon/ceph-daemon index f9e27179a32..480ce55762a 100755 --- a/src/ceph-daemon/ceph-daemon +++ b/src/ceph-daemon/ceph-daemon @@ -1330,6 +1330,8 @@ def command_shell(): @infer_fsid def command_enter(): # type: () -> int + if not args.fsid: + raise RuntimeError('must pass --fsid to specify cluster') (daemon_type, daemon_id) = args.name.split('.', 1) container_args = [] # type: List[str] if args.command: @@ -1393,6 +1395,8 @@ def command_ceph_volume(): @infer_fsid def command_unit(): # type: () -> None + if not args.fsid: + raise RuntimeError('must pass --fsid to specify cluster') (daemon_type, daemon_id) = args.name.split('.', 1) unit_name = get_unit_name(args.fsid, daemon_type, daemon_id) call_throws([ @@ -1405,6 +1409,8 @@ def command_unit(): @infer_fsid def command_logs(): # type: () -> None + if not args.fsid: + raise RuntimeError('must pass --fsid to specify cluster') cmd = [container_path, 'logs'] if args.follow: cmd.append('-f') -- 2.39.5