The "RHEVM Shell" command option to remove 'cdrom' is not correct in Command Line Shell Guide

Solution Verified - Updated -

Environment

  • Red Hat Enterprise Virtualization 3.X

Issue

  • The option given to remove attached 'CDROM' from VM in Command Line Shell Guide failed with below errors:
[RHEVM shell (connected)]# remove cdrom --vm-identifier MyVM rhel-server-6.3-x86_64-dvd.iso.iso
error: cdrom rhev-tools-setup.iso does not exist.

[RHEVM shell (connected)]# remove cdrom --vm-identifier MyVM --file-id rhel-server-6.3-x86_64-dvd.iso.iso
error: wrong number of arguments, try 'help remove' for help.
[RHEVM shell (connected)]#

Resolution

  • The correct syntax for removing cdrom using rhev command shell,
# remove cdrom <id> --vm-identifier MyVM --file-id rhel-server-6.3-x86_64-dvd.iso.iso

For example:

[RHEVM shell (connected)]# remove cdrom 00000000-0000-0000-0000-000000000000 --vm-identifier MyVM --file-id rhel-server-6.3-x86_64-dvd.iso.iso

Root Cause

  • This is a documentation bug which tracked by internal bugzilla.

  • The help notes for 'remove cdrom' states that it requires type and id arguments. Below is the snippet of it:

[RHEVM shell (connected)]# help remove cdrom 

USAGE

  remove <type> <id> [parent identifiers] [command options]

DESCRIPTION

  Removes an object. The following arguments are required:

    * type        The type of object to remove
    * id          The object identifier

  Objects can be identified by their name and by their unique id.

Diagnostic Steps

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.