vm.relocateVM_Task does not work when moving between clusters

Hi all

I have a Scriptable who suppose to migrate virtual machines (datastore and host) to another cluster. When I test it within the cluster, everything works perfectly. But when I'm trying to move a VM between clusters, I get:

"specified incorrect setting '

I can manually move the virtual machine via vSphere Web Client without problem.

This is the code in the script task:

//Get VM's number of VMDKs
diskIDArray = new Array();
var devices = vm.config.hardware.device;
for (var j in devices) {
    if (devices[j] instanceof VcVirtualDisk)
  {
         diskIDArray.push(devices[j].key);
  System.log("VM Disk ID:" + devices[j].key);
     }
}
//Migrate
var spec = new VcVirtualMachineRelocateSpec();
spec.datastore = destDatastore;
spec.host = destHost;
spec.disk = new Array();
for (var i=0;i< diskIDArray.length;i++)
  {
  var disk = new VcVirtualMachineRelocateSpecDiskLocator();
  disk.diskId = diskIDArray[i];
  disk.datastore = destDatastore;
  spec.disk[i] = disk;
  }
//vcTask = System.getModule("dk.atea.extra").XvMotion(vm,destHost,destDatastore);
vcTask = vm.relocateVM_Task(spec, VcVirtualMachineMovePriority.defaultPriority);  // VirtualMachine

Any ideas?

Dan.

Hi Dan,.

You must set the target resourcepool (spec.pool).

Maachah

Tags: VMware

Similar Questions

  • Flex app does not work when moved from the original location

    I'm doing a gallery of images in flex. It works when I run it in Flex Builder perfectly fine. Files html and swf works perfectly well open in any browser too, but ONLY when these files and all related files are open to the default location where the application has been generated in bin-debug folder. When I export a generation to another folder, the swf file loads but no other information from the display of the xml file. I tried to set all paths reference files (that is, the xml language) in the flex application to the absolute exact location on the server, and it did not work when I downloaded it on the server.

    I tried several approaches from scratch and they all arrive at the same question. I work with a teaching for Flex Builder License, I'm not sure if they jip you on those and ruin the compiled swf.

    Help, please! I'm losing my mind on that. I think it has to do with something else, in addition to the code because it works fine when I click 'Run', but if someone thinks it is helps for the zip code let me know.

    Often this is because you must add the - use-network = true compiler option in FlexBuilder menu bar:

    Project - Properties - Flex Compiler - additional compiler arguments:

    Add - use-network = true, and then recompile and post back to the server, should work fine.

    Note: If you create a "Release" version and move elsewhere on your local computer, you may need to add - use-network = true, and then recompile the application to access local resources outside the Flex Builder environment.

    If this post answers your question or assistance, please mark it as such.

  • As I installed Sierra, my Trusteer account to my Bank quit and does not work when I reinstall. Neither will Quickbooks!

    As I installed Sierra, my Trusteer account to my Bank quit and does not work when I reinstall. Neither will Quickbooks! Help!

    Trusteer (report) has caused a lot of problems Mac users such noted search Apple Support communities here.

  • Satellite A660 - Webcam does not work when using Skype

    I recently bought a Satellite A660-15J. I am running Windows 7 64 bit.

    I have the latest version of Skype (5.3.0.111).

    The integrated Webcam does not work when you run Skype. If I run the Toshiba Web Camera Application the webcam works fine. However, when I test it in Skype, I get a message saying "cannot start video. Try quitting other programs that use the webcam '.

    However, as far as I can tell there no other programs available. I have tried Skype with the Web Camera Application clised & open. I also confirmed that I do run the latest version of the program.

    One of the main reasons we have this laptop is to use Skype video... Help, please.

    Disable webcam application start-up and exit this application before you start Skype.

    I used Skype many different models of laptops, including friends A660 and it worked correctly.

    When you open Skype video settings is listed as default camera USB webcam?

  • The slide show feature does not work when I used my Apple TV new 4th gen. I have all the minimum requirements for Macbook and Macbook OSX the Airport express. The slide show starts and stops after that 7 photos are displayed on the TV. If I change the

    The slide show feature does not work when I used my Macbook with new Apple TV 4th gen. The slide show stops after that display 7 photos and display to select the options for the slide show is displayed on the screen. The selected interval was 5 seconds. If the interval is spent in 3 seconds the slide show would work for a time and then to display random images. Has worked with Apple on this issue Support Mike and he managed to reproduce the problem. Since I'm in the return period of 14 days for this product, I returned it to the Apple store

    Welcome to the Apple community.

    After returning, I'm not really clear on what your question.

  • Event does not work when I have my variable of variable mutual FUND!

    Hello

    I programmed a labview vi to add a field to a list view when a Boolean variable value is changed. I used a case Event (value change event) structure to determine if a variable value is changed, it works when I force the Boolean control with my mouse click, but it does not work when the value of the variable is modified by the mutual FUND. What should I use instead?

    Value change events are based on the interaction of the user (or the same ejection programmatically based on the value property node (signaling).)  It is not based on a control change via a regular, variable property node local, terminal or any other connecito0n programmatic or binding.

    You must simply query the variable and determine when it changes.  In this case, you can then use the node value property (signs) in the case of event fire.

  • Microsoft Pinball Arcade, everything works except the right flipper does not work when you run the game. __Keyboard is very good

    Microsoft Pinball Arcade, everything works except the right flipper does not work when you run the game.
    Keyboard is fine.  Is this a compatibility issue?

    ---------------

  • Sound does not work when it is connected to the TV with HDMI

    I have a HP Pavilion Notebook PC, DV7 - 6813EV, running windows 7 Home Premium 64-bit SP1. My problem is that I have no sound when connected to my TV HDMI connection and press. Please could someone help me? Thanks in advance

    Hello gematz,

    The sound does not work when it is connected to the TV via HDMI.

    Go to start.

    Type sound.

    Click sound

    On the playback tab, click with the right button on the HDMI interface, and then select set as default device.

    If you do not see the HDMI, right click and select devices see off, then set as default.

    I would like to know how everything goes.

  • Here's a strange. I have a HTML page with this time a wmv video. It works perfectly from a USB stick or SD card, but does not work when they are copied to the hard drive

    I have an HTML page created with web expression 4. It contains only a wmv video. It works perfectly when it is called from a USB stick or SD card, but does not work when they are copied to the hard drive. The results are the same with IE and Firefox. It don't make no difference if I use Media Player V9 or V11. He has no control on the page Media Player. Video and html files are in the same directory. Here is the code snippet:

    LIFT, DRAG, THRUST and GRAVITY










    If I run it on a machine with Win 7 there is no problem.

    Richard Grosser

    Hi Richard c. Grosser,.

    Your question is more complex than what is generally answered in the Microsoft Answers forums. It is better suited for the IT Pro TechNet public. Please post your question in the Microsoft Expression forums.

    http://social.expression.Microsoft.com/forums/en-us/categories

  • AutoPlay feature does not work when you insert a CD-ROM into the CD drive

    Original title: computer disc drive

    Download or CD extract of music reading, record music, download CD etc... Before my hard drive had to be replaced, when a disc is inserted into my computer, a window appears, asking what you want to do... Burn music, Rip, copy in folder etc... now when I insert a disk, the window no longer appears, which gives you options and you get to this site... How can I get that back?

    Hey Big-Mack,

    Try the steps of troubleshooting mentioned in the following article and check the result.
    See the enforcement function automatic or AutoPlay feature does not work when you insert a CD-ROM into the CD drive

    If the problem persists, run the Autoplay Repair Wizard and check the result.
    See Autoplay Repair Wizard

    Play functionality; New in Windows Media Player 12 makes it easy to listen to the music, video and photos from your computer to other computers, TVs or stereo on your home network.
    For more information, see play in

    Visit our Microsoft answers feedback Forum and let us know what you think.

  • LAN does not work when the Cisco E1000 router hangs

    Original title: Download sp3

    Remember - this is a public forum so never post private information such as numbers of mail or telephone! I bought recently a new Cisco E1000 router. My computer is a laptop model Lenovo 0769.

    I am running windows XP with sp2. The cisco software requires sp3. I called support of cisco and even they couldn't get to download sp3. My network is wireless on the router and I had to install from another laptop computer on the system. My LAN does not work when hooked. What do you suggest to me.

    Ideas:

    • You have problems with programs
    • Error messages
    • Recent changes to your computer
    • What you have already tried to solve the problem

    Hi mdenrique,

    1. what exactly do you mean by LAN (Local Area Network) does not work? You get the error message?

    If you have not installed Service Pack 3, try the following steps:
    Step 1: Download Service Pack 3
    see How to obtain the latest Windows XP service pack .
    b. scroll the window and click on "Download now the Windows XP Service Pack 3 package" to download the service pack.
    c. save the file on the desktop.

    Step 2: Install Service Pack 3
    a. open the file downloaded and follow the instructions in the wizard to complete the installation.
    b. restart the computer once the installation is complete.

    For more information, see steps to take before you install Windows XP Service Pack 3

    Note: Once you have installed service pack 3, install the router and check if the problem persists.

    Step 3: To troubleshoot LAN, run home and small Office Networking Troubleshooter
    a. Click Start and then click Help and Support.
    b. under Pick a help topic, click Network and Internet.
    c. under network and the Web, click on resolution of networking or Web problems and then click on home and small Office Networking convenience store.
    d. answer the questions in the troubleshooter to try to find a solution.

    For more information, see the following articles:
    1 see How to troubleshoot a network in Windows XP
    2 see two resources to solve the problems of connection network in Windows XP

    Visit our Microsoft answers feedback Forum and let us know what you think.

  • Windows Media Player does not work when I Google Chrome on pagers Web in Google Chrome

    Windows Media Player does not work when I go on Google Chrome on WebPagers in Google Chrome please help me

    Hello

    1 What is this problem occurs with the Google chrome or windows media player?

    2 are you able to play another song from Player Windows Media outside the Google Chrome?

    3. have you made changes on your computer?

    4. have you received an error message?

    I suggest you to follow the steps and check.

    http://support.Google.com/chrome/bin/answer.py?hl=en&answer=95697

  • Keyboard does not work when I start windows

    my keyboard does not work when I boot my laptop.   When I do any changes inside through properties keybord (even the spped blinking cursor) he started working. but when I press capslock, it stops working again and I have to still to change the settings in the keyboard properties to make work.i have tried to install the new software, I got my laptop to format but it still does not.

    need help with this and please tell me the solution if r there all

    If by "I got my laptop to format", you mean you have reinstalled Windows and the problem persists, it is probably a hardware problem. If you have a keyboard that can be plugged into your laptop, there the same problem?

  • I have my button to right click on my mouse hp laptop pavilion 2008 does not work when I click on it might

    Can I get help with a problem please? my button to right click on my mouse hp laptop pavilion 2008 does not work when I click on it. I tried to delete some files, but it wouldn't let me not make a right click on it to remove

    could you please email me at * address email is removed from the privacy *.

    Thank you very much. I hope hear from you soon. Thank you once again :)

    Can I get help with a problem please? my button to right click on my mouse hp laptop pavilion 2008 does not work when I click on it. I tried to delete some files, but it wouldn't let me not make a right click on it to remove

    could you please email me at e-mail removed for privacy

    Thank you very much. I hope hear from you soon. Thank you once again :)

    You have a laptop. So try the right button on your touchpad. It work?
    If so, the only remaining possibilities are:
    1. bad mouse. Get a new one.
    2. defective UBS port. Plug the mouse into a different port. See if the right click of the mouse works this time.

    P.S. We do give advice to users via e-mail. All responses must be published and remained in this forum so that others with the same problem will use the answer.
    For the benefits of others looking for answers, please mark as answer suggestion if it solves your problem.

  • My nvidia graphics card does not work when I install microsoft visual stedio

    as say the title my nvidia graphics card does not work when I install microsoft visual studio 2013
    How can I stop this from happening

    We know what to do?

    Yes and Yes, but it's good for now
    I restore the Windows STILL and installation of visual studio without emulator windows 8.1 phone

    and it worked

    Thanks for the reply.

Maybe you are looking for

  • BSOD KERNEL_MODE_EXCEPTION_NOT_HANDLED on developers preview WIndows

    Original title: BSOD KERNEL_MODE_EXCEPTION_NOT_HANDLEDHello world. I have a problem with my copy of Windows Developer Preview. I get about 3 - 4 times on the day a Blue Screen Of Death with "BSOD KERNEL_MODE_EXCEPTION_NOT_HANDLED" whenever I wake the

  • The new keyboard shortcuts available in Windows 8.

    Hello fans forum! Previously, I did a post with the new pop-up menu (Windows key + X) in Windows 8 (visible here).  However, Windows 8 offers in terms of many new keyboard shortcuts useful that everyone should take note of. This Microsoft article cov

  • Recover Windows 8.0 on hp pc

    I would like to reinstall my windows 8 pro system, but I have lost my recovery CD. So, how to do a reinstall or recovery of windows 8 and delete all my files, I supported those upward and its ok to remove them. I'm selling this computer because I don

  • I am owner of a photosmart b9180, red head stepchild of it's hp

    Each article in the mag of each pc has always said 'buy the best printer, you can, you will save money long term supplies. " I bet they never possessed the b9180, lol. I paid $695 for the printer. To fill it with ink, it's 8 cartridges to $38.95 each

  • Microsoft Visual Studio Express 2013 for windows contains errors trying to repair or uninstall!

    I made a thread on Stack Overflow, but I don't have real solutions because I have a peculiar problem which is not as widespread and I need more experienced people who know a lot about windows and microsoft products to help me with this problem First