Feature #1163
closed
zpool destroy should prompt user
Added by Roy Sigurd Karlsbakk almost 11 years ago.
Updated about 1 year ago.
Description
Hi all
Destroying a beadm will prompt the admin:
root@mime:~# beadm destroy oi-likewise
Are you sure you want to destroy oi-likewise?
This action cannot be undone (y/[n]):
In my opinion, changing zpool and perhaps zfs to do the same would be a jolly good idea....
roy
- Assignee set to sham pavman
I have the fix for this.. So assigned it to myself.
We will need the 'force' flag then so zpool/zfs commands would still be usable for scripting.
Well on second thought do we really need this as a feature.
Reason being there are a lot of scripts that that currently are written to work with only "zpool destroy"/ "zfs destroy" [ without user interaction ].
There is a "very good" possibility that these might break a lot of tasks elsewhere.
THIS IS A TERRIBLE IDEA.
Zpool force avoids a bunch of checks. It should not be used just because you want to use scripting. Don't break the interface here.
This bug gets a heartfelt -1 in my opinion.
Commands should not need to prompt for verification. If you have permission to run these commands (e.g. as root), then you better know what you're doing.
I guess I'll better throw in the towel here. You're right, it'll break scripting.
roy
Garrett D'Amore wrote:
THIS IS A TERRIBLE IDEA.
Zpool force avoids a bunch of checks. It should not be used just because you want to use scripting. Don't break the interface here.
I haven't said anything about existing 'force' behavior, what I meant is that we'll need an option to bypass interactive prompt if the feature was to be implemented.
we should go ahead and close this issue then..
Thanks
- Status changed from New to Closed
Also available in: Atom
PDF