cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
6014
Views
0
Helpful
8
Comments
rekkrish
Level 4
Level 4
Task NameISO Mounting and Unmounting onto VM Custom Task
DescriptionThe purpose of the ISO Mounting on VM is to mount the iso files on the Virtual Machine without using a physical drive. An ISO is generally a disk image which once mounted in your virtual machine you can open, extract, and use those files from  virtual drive/CD without a physical disk.
Prerequisites
  1. Datastore must have the .iso image for mounting.
Compatible UCS Director VersionsUCSD 4.1.X.X
CategoryVirtualization
ComponentsvSphere 5.x


Instructions for Use:

  1. Download the attached .ZIP file below to your computer. *Remember the location of the saved file on your computer.
  2. Unzip the file on your computer. Should end up with a .WFDX file.
  3. Log in to UCS Director as a user that has "system-admin" privileges.
  4. Navigate to "Policies-->Orchestration-->Custom Workflow Tasks" and click on "Import".
  5. Click "Browse" and navigate to the location on your computer where the .WFDX file resides. Choose the .WFDX file and click "Open".
  6. Click "Upload" and then "OK" once the file upload is completed. Then click "Next".
  7. Click "Submit".
  8. A new Task should appear in "Policies-->Orchestration-->Custom Workflow Tasks" that contains the imported Custom Task.
  9. Create a basic workflow. For more information, see the Creating a Workflow section in the Cisco UCS Director Orchestration Guide, Release 4.1.
  10. Add the imported workflow task to the workflow. For more information see the Adding Tasks to a Workflow section in the Cisco UCS Director Orchestration Guide, Release 4.1.
  11. In the Workflow Task Basic Information screen, enter the following details:vCenter IP, Username, Password, Virtual Machine name, Datastore name and ISO name
  12. Click Submit.
  13. Double Click the workflow, the workflow designer opens.
  14. In the workflow designer window, click the Execute Now button.
  15. A service request is created for the workflow.
Comments
rpjose001
Community Member

Hi Rekha,

I'm having this error when mounting ISO in UCS Director version 4.1.0.2.

Oct 17, 2014 16:36:21 PHT Error occured at line # 67

Oct 17, 2014 16:36:21 PHT [Line#67] cdDeviceBacking.setDatastore(dsSummary.getDatastore());

Oct 17, 2014 16:36:21 PHT Handler failed with error - sun.org.mozilla.javascript.internal.EcmaError: TypeError: Cannot call method 'getDatastore' of null (<Unknown source>#67) in <Unknown source> at line number 67, selectedContext=<None>

Oct 17, 2014 16:36:21 PHT Task #1 (ISO Mounting - test (custom_ADD CDROM For ISO Mounting WF)) failed after 0 seconds

Oct 17, 2014 16:36:21 PHT Input/Output values for Task #1 (ISO Mounting - test (custom_ADD CDROM For ISO Mounting WF)):

Regards,

abpujari
Community Member

Task is not able to find the datastore with provided datastore name. Please provide an existing datastore name

rpjose001
Community Member

Hi Abhilash,

I just created a new workflow again and validated the datastore name where ISO file is located. The same error appeared after executing the workflow task.

Service Request ID: 793

Nov 04, 2014 14:43:05 PHT Request submitted

Nov 04, 2014 14:43:10 PHT Executing workflow item number 1

Nov 04, 2014 14:43:10 PHT Completed workflow item number 1, with status Completed

Nov 04, 2014 14:43:16 PHT Executing workflow item number 2

Nov 04, 2014 14:43:16 PHT Trigger context executeWorkFlowStep called

Nov 04, 2014 14:43:16 PHT Executing custom action ISO Mounting - test (custom_ADD CDROM For ISO Mounting WF)

Nov 04, 2014 14:43:16 PHT Executing custom action ISO Mounting - test (custom_ADD CDROM For ISO Mounting WF)

Nov 04, 2014 14:43:16 PHT Executing custom script for ADD CDROM For ISO Mounting WF

Nov 04, 2014 14:43:17 PHT input.ipaddress =172.17.1.100, username =*@vcloud , password =*

Nov 04, 2014 14:43:17 PHT VM testVM found

Nov 04, 2014 14:43:17 PHT vm Power state poweredOff

Nov 04, 2014 14:43:17 PHT No action required

Nov 04, 2014 14:43:17 PHT ds name : VPC01-STD01-LUN1 iso : w2K8R2STD

Nov 04, 2014 14:43:17 PHT Error occured at line # 67

Nov 04, 2014 14:43:17 PHT [Line#67] cdDeviceBacking.setDatastore(dsSummary.getDatastore());

Nov 04, 2014 14:43:17 PHT Handler failed with error - sun.org.mozilla.javascript.internal.EcmaError: TypeError: Cannot call method 'getDatastore' of null (<Unknown source>#67) in <Unknown source> at line number 67, selectedContext=<None>

Nov 04, 2014 14:43:17 PHT Task #1 (ISO Mounting - test (custom_ADD CDROM For ISO Mounting WF)) failed after 0 seconds

Nov 04, 2014 14:43:17 PHT Input/Output values for Task #1 (ISO Mounting - test (custom_ADD CDROM For ISO Mounting WF)):

Nov 04, 2014 14:43:17 PHT [Local Input: VCenter IP = 172.17.1.100]

Nov 04, 2014 14:43:17 PHT [Local Input: User Name = *@vcloud]

Nov 04, 2014 14:43:17 PHT [Local Input: Password = **masked-value**]

Nov 04, 2014 14:43:17 PHT [Local Input: Virtual Machine Name = testVM]

Nov 04, 2014 14:43:17 PHT [Local Input: Datastore Name = VPC01-STD01-LUN1]

Nov 04, 2014 14:43:17 PHT [Local Input: ISO Name = w2K8R2STD]

Nov 04, 2014 14:43:17 PHT Completed workflow item number 2, with status Failed

abpujari
Community Member

Hi Russel,

Provide the datastore name that belongs to the VM.

The ISO file must be located on a datastore(local/shared datastore) accessible to the host where the VM is running.

Thanks

Abhilash

rpjose001
Community Member

Hi Abhilash,

VM is located at shared datastore VPC01-STD01-LUN2 and the ISO file is

located on different shared datastore VPC01-STD01-LUN1.

Regards,

abpujari
Community Member

Hi Russel,

I gone through the script for ISO mounting. It will mount If the image file located in datastores accessible to the VM. Please try to mount having VM and image file in same datastore.

Thanks

Abhilash

rpjose001
Community Member

Hi Abhilash,

Thanks for the help, mount was successful when I transferred it on the same

datastore. Also, I notice that credentials are visible in logs. How can I

hide it from other users?

Regards,

On Thu, Nov 6, 2014 at 10:15 PM, Abhilash Pujari <community@cisco.com>

abpujari
Community Member

Hi Russel,

Modify the custom task and change the ‘Input Field Type’ and ‘Map to Input Type’ as ‘Password’. It will mask the credential value.

Thanks

Abhilash

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Quick Links

Review Cisco Networking for a $25 gift card