Bug 1569176

Summary: cryptsetup could be more user friendly by offering possible actions instead of 6 lines of advanced flags
Product: Red Hat Enterprise Linux 7 Reporter: Corey Marthaler <cmarthal>
Component: cryptsetupAssignee: Ondrej Kozina <okozina>
Status: CLOSED WONTFIX QA Contact: Storage QE <storage-qe>
Severity: low Docs Contact:
Priority: unspecified    
Version: 7.5CC: agk, jbrassow, mbroz, okozina, prajnoha
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-02-15 07:38:30 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Corey Marthaler 2018-04-18 17:55:51 UTC
Description of problem:
If cryptsetup knows it's an action i got wrong, then why not offer a list of actions I can do, not six lines of advanced flags? If it's the advanced flags i'm looking for, I can 'man cryptsetup'

[root@host-087 ~]# dmsetup ls
cPV1    (253:2)

[root@host-087 ~]# cryptsetup LuksClose cPV1
Usage: cryptsetup [-?vyrq] [-?|--help] [--usage] [--version] [-v|--verbose] [--debug] [-c|--cipher STRING] [-h|--hash STRING] [-y|--verify-passphrase]
        [-d|--key-file STRING] [--master-key-file=STRING] [--dump-master-key] [-s|--key-size BITS] [-l|--keyfile-size bytes] [--keyfile-offset=bytes]
        [--new-keyfile-size=bytes] [--new-keyfile-offset=bytes] [-S|--key-slot INT] [-b|--size SECTORS] [-o|--offset SECTORS] [-p|--skip SECTORS] [-r|--readonly]
        [-i|--iter-time msecs] [-q|--batch-mode] [-t|--timeout secs] [-T|--tries INT] [--align-payload=SECTORS] [--header-backup-file=STRING] [--use-random]
        [--use-urandom] [--shared] [--uuid=STRING] [--allow-discards] [--header=STRING] [--test-passphrase] [--tcrypt-hidden] [--tcrypt-system] [--tcrypt-backup]
        [--veracrypt] [-M|--type STRING] [--force-password] [--perf-same_cpu_crypt] [--perf-submit_from_crypt_cpus] [OPTION...] <action> <action-specific>
cryptsetup: Unknown action.


[root@host-087 ~]# cryptsetup luksClose cPV1


# VDO offers actions/choices, if misspelled or unknown. 
[root@host-073 ~]# vdo statsu
usage: vdo [-h] command ...
vdo: error: argument command: invalid choice: 'statsu' (choose from 'activate', 'changeWritePolicy', 'create', 'deactivate', 'disableCompression', 'disableDeduplication', 'enableCompression', 'enableDeduplication', 'growLogical', 'growPhysical', 'list', 'modify', 'printConfigFile', 'remove', 'start', 'status', 'stop')


Version-Release number of selected component (if applicable):
cryptsetup-1.7.4-4.el7.x86_64
cryptsetup-libs-1.7.4-4.el7.x86_64

Comment 2 Corey Marthaler 2018-04-18 17:58:13 UTC
...and to be pedantic, I actually *did* spell the action correctly :)

Comment 6 RHEL Program Management 2021-02-15 07:38:30 UTC
After evaluating this issue, there are no plans to address it further or fix it in an upcoming release.  Therefore, it is being closed.  If plans change such that this issue will be fixed in an upcoming release, then the bug can be reopened.