mirror of
https://github.com/ceph/ceph
synced 2024-12-18 09:25:49 +00:00
ceph-disk: add 'zap' command
Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
parent
99bd5c8f7b
commit
10ba60cd08
@ -1869,6 +1869,9 @@ def main_suppress(args):
|
||||
def main_unsuppress(args):
|
||||
unset_suppress(args.path)
|
||||
|
||||
def main_zap(args):
|
||||
for dev in args.dev:
|
||||
zap(dev)
|
||||
|
||||
###########################
|
||||
|
||||
@ -2028,6 +2031,17 @@ def parse_args():
|
||||
func=main_unsuppress,
|
||||
)
|
||||
|
||||
zap_parser = subparsers.add_parser('zap', help='Zap/erase/destroy a device\'s partition table (and contents)')
|
||||
zap_parser.add_argument(
|
||||
'dev',
|
||||
metavar='DEV',
|
||||
nargs='*',
|
||||
help='path to block device',
|
||||
)
|
||||
zap_parser.set_defaults(
|
||||
func=main_zap,
|
||||
)
|
||||
|
||||
args = parser.parse_args()
|
||||
return args
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user