ceph.in: print more detailed error message for 'tell' command
authorKefu Chai <kchai@redhat.com>
Wed, 15 Jul 2015 10:01:52 +0000 (18:01 +0800)
committerLoic Dachary <ldachary@redhat.com>
Tue, 28 Jul 2015 12:56:53 +0000 (14:56 +0200)
* we do not allow user specify a certain daemon when starting an
  interactive session. the existing error message could lead to
  some confusion. so put more details in it.

Fixes: #11101
Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 972dc9145235ff0f60663369ebcab8c16628b89f)

src/ceph.in

index 2b6adf4dc579a43bed4ae60bccc832f579e49e06..4fc4a645e6cb1ed970115a3ae1a95ed08d8f65a0 100755 (executable)
@@ -794,7 +794,9 @@ def main():
             childargs = injectargs
         if not len(childargs):
             print >> sys.stderr, \
-                'Cannot use \'tell\' with interactive mode'
+                'Cannot use \'tell\' with interactive mode.', \
+                'For an interactive shell,', \
+                'please start "{0}" without non-option arguments.'.format(sys.argv[0])
             return errno.EINVAL
 
     # fetch JSON sigs from command