rendev command

Purpose

You can rename an existing virtual target device (VTD), on the Virtual I/O Server, that maps the virtual Small Computer Serial Interface (vSCSI) adapter with the logical volume, tape, optical device, physical disk, or shared storage pool (SSP) logical unit.

Syntax

To rename a VTD:

rendev –dev devName -new devNewName [-force]

Description

The rendev command is used to rename a VTD. The VTD that you want to rename must be specified by using the -dev flag and the new name of the VTD must be specified by using the -new flag. The new name that you provide for the VTD must not have special characters and must not exceed 15 characters in length.

If the -force flag is specified, the state of the VTD is ignored and the rename operation is executed. If the VTD is in an available state, the -force flag unconfigures the VTD, renames and re-configures the VTD.
Note: All the I/O operations on the backing device that is linked to a VTD will fail on the virtual machine until the rename operation completes.

During the rename operation if the VTD is already in the defined state, the rename operation retains the current state of the VTD.

If the VTD is in a defined state the -force flag is not required to rename a VTD. If the -force flag is not specified and the VTD is in an available state, the rename operation fails.

If the rename operation is successful with the -force flag and the virtual target device is still in the defined state, you must wait for sometime because the configuration process of the VTD is running in the background. If the VTD is still in the defined state, you must refer to the error logs in the database primary node (DBN).
Note: To protect the configuration database, the rendev command cannot be interrupted after it has started. Trying to stop this command before completion, could result in a corrupted database.
The rename operation can fail due to the following reasons:
  • The new name for the VTD is already used or is available in the /dev directory.
  • The new name for the VTD is formed by appending the name of the VTD that is already used as a device name or is available in the /dev directory.

Flags

Flag name Description
-dev Specifies the VTD that needs to be renamed.
-new Specifies the new name of the VTD.
-force Forces to reconfigure the VTD.

Exit Status

Return code Description
0 Success
-1 Failure

Examples

  1. To rename the VTD vtscsi0 that is in an available state, run the following command:
    rendev -dev vtscsi0 -new vtscsi0_new -force

    The system displays a message that is similar to the following example:

    VTD 'vtscsi0' has been successfully renamed to 'vstsci0_new'.

  2. To rename the VTD vtscsi1 that is in a defined state, run the following command:
    rendev -dev vtscsi1 -new vtscsi1_new

    The system displays a message that is similar to the following example:

    VTD 'vtscsi1' has been successfully renamed to 'vtscsi1_new'.

  3. To rename the virtual optical device vtopt0 that is in an available state, run the following command:
    rendev -dev vtopt0 -new vtopt0_new -force

    The system displays a message that is similar to the following example:

    Virtual optical device 'vtopt0' has been successfully renamed to 'vtopt0_new'.