[chef] Re: Re: Re: Re: Re: Re: Re: Re: "knife-vsphere vm vmdk add" cannot find VM


Chronological Thread 
  • From: Anna Redding < >
  • To: " " < >
  • Cc: " " < >
  • Subject: [chef] Re: Re: Re: Re: Re: Re: Re: Re: "knife-vsphere vm vmdk add" cannot find VM
  • Date: Thu, 20 Mar 2014 14:24:18 -0500

Robert

Thank you for your line command. Unfortunately, it did not answer the issue but it told me that the next thing I was going to try wasn't going to work.  
When I printed the code for 0.9.8, I noticed references to the variable specifying the target lun was defined with an underscore as  "target_lun". 
I thought the might be the problem as I have been using a dash not an underscore ... but your example negated that because you use the 'dash' not the underscore. 

I cannot give exact command bc the system is in a secured area but I did write down the various pieces so here it is:

strace  -o  /tmp/strace-vsphere.out  knife  vsphere  vm  vmdk  add  annaVM  4   --vmdk-type  thick   --vsdc  ISP   --vshost  <vcIP>  --target-lun  ds03   --vsport  443   --vsinsecure  -VV 

When I looked at the strace, the DEBUG sections appeared to reflect the correct values.

After reviewing the 22k+ lines of strace info, I could not find any messages that jumped out, definitely none that were  preceded by the DEBUG flag. 

Any other ideas?
Anna



Sent from  my iPhone

On Mar 20, 2014, at 12:17 PM, Robert Tsai < "> > wrote:

Hi Anna,

Sorry to hear its still not working for you.  The command I used was knife vsphere vm vmdk add vmname 3 --target-lun SSDGuest

 knife vsphere vm vmdk  vmname 3 --target-lun SSDGuest
[fog][WARNING] Unable to load the 'unf' gem. Your AWS strings may not be properly encoded.
Digest::Digest is deprecated; use Digest
DEBUG: value for config item vsphere_host: 2.2.2.2
DEBUG: value for config item vshere_path:
DEBUG: value for config item vsphere_port: 443
DEBUG: value for config item vsphere_nossl:
DEBUG: value for config item vsphere_user: testuser
DEBUG: value for config item vsphere_pass: testpassword
DEBUG: value for config item vsphere_insecure: true
DEBUG: value for config item proxy_host:
DEBUG: value for config item proxy_port:
DEBUG: value for config item vsphere_host: 2.2.2.2
DEBUG: value for config item vshere_path:
DEBUG: value for config item vsphere_port: 443
DEBUG: value for config item vsphere_nossl:
DEBUG: value for config item vsphere_user: testuser
DEBUG: value for config item vsphere_pass: testpassword
DEBUG: value for config item vsphere_insecure: true
DEBUG: value for config item proxy_host:
DEBUG: value for config item proxy_port:
DEBUG: value for config item folder:
DEBUG: value for config item vsphere_dc: testdc

DEBUG: value for config item vsphere_dc: testdc
this is point1   * I added the puts to see what vm name would return
VirtualMachine("vm-981") *
this is point2  *
DEBUG: value for config item target_lun:
Datastore: SSDGuest (741.57 GB(796250865664) / 2.00 TB)
DEBUG: value for config item vsphere_dc: testbed
Choosing: SSDGuest
DEBUG: value for config item vmdk_type: thin
Next vmdk name is => [SSDGuest] vmname/vmname_1.vmdk
Creating VMDK
Capacity: 3 GB
Disk: [SSDGuest] vmname/vmname_1.vmdk
DEBUG: value for config item noop:
DEBUG: value for config item vsphere_dc: testbed
Attaching VMDK to vmname
using SCSI controller 0
using SCSI ID 1
DEBUG: value for config item noop:
D, [2014-03-20T10:11:57.458010 #26166] DEBUG -- : Shutdown completed cleanly

Can you output the command you used and the results?

Thanks,
Robert



On Thu, Mar 20, 2014 at 9:34 AM, Anna Redding < " target="_blank"> > wrote:
Robert,

Would you share your line command (substituting the proprietary info of course)?

I upgraded to 0.9.8 and still not working. It just has to be something with the command format/content. 

The "knife vsphere vm 'list' ..." works fine. The 'vmdk add' does not. 

Much appreciated,

Anna


Sent from my iPhone
What version of the pluggin are you using?  I am using 0.9.8 and I am able to use the knife vsphere vm vmdk add VM SIZE command with no issues.


On Tue, Mar 18, 2014 at 9:38 AM, Robert Tsai < " target="_blank"> > wrote:
btw Does the "knife vsphere vm state" command work for you?


On Tue, Mar 18, 2014 at 8:51 AM, Anna Redding < " target="_blank"> > wrote:
Yes I have tried that and it was either an invalid option or it failed (don't remember which). I have also tried --dest-folder which I used in the cloning step ... Also a no-go 


Sent from my iPhone
Hi Anna,

Have you tried adding the --folder FOLDER option where the vm resides? I haven't used the "knife vsphere vm vmdk add" command yet.  I'll test it and let you know if get the same results.
-Robert


On Tue, Mar 18, 2014 at 8:16 AM, Anna Redding < " target="_blank"> > wrote:
Thank you for replying.
> Post a verbose output
   Unfortunately I am running this in a closed area without Internet access.

> which call fails
The best I can tell using strace and the -vv option is the calls to PropertyFilterSpec.rb
TypeName.rb
PropertyPath.rb
ObjectSpec.rb
All fail with -1 return code and error "No such file or directory"
Then several lines of data that looks like registry or pointer values print out followed by the message
"Could not find <VMname>"


>
> Did you try knife-vsphere devs:
No, but now that I know there's a specific support group, I definitely will.


Let me know if the above triggers any ideas.

Thanks
Anna

Sent from my iPhone

On Mar 17, 2014, at 4:02 PM, Aimelyne Mochiron < " target="_blank"> > wrote:

> Hi Anna,
>
> Could you please post a verbose output (-VV flag)? At the least, knowing which call fails would be useful.
>
> Did you try and run your issue past the knife-vsphere devs: https://github.com/ezrapagel/knife-vsphere?
>
> am
>
> On 17 Mar 2014, at 19:25, Anna Redding < " target="_blank"> > wrote:
>
>> Hello all,
>>
>> I have not heard anything back so re-posting.
>>
>> I 'really' need to get this resolved (see atached email) as the automation code I've written needs to be used to build out an environment tomorrow or Wed. We will have to have manual intervention if I don't get this working and that is what we are trying to eliminate.
>>
>> So ANY' ideas are most welcome!!!!
>>
>> I've tried putting the VM directly under the data center level; I've tried referencing via  IPaddr; I've tried the long form of the hostname; I've verified spelling; I've verified the VM is really on the data store I'm pointing to on the command line... no matter what, I receive the same error indicating it cannot find the VM...yet it was created using the "knife vsphere vm clone" command.
>>
>> What else can it be???
>>
>> Even if you think it's an 'obvious' answer, please run it past me.
>>
>> Thank you in advance.
>> Anna
>>
>>
>> Sent from my iPhone
>>
>> On Mar 14, 2014, at 11:14 AM, Anna Redding < " target="_blank"> > wrote:
>>
>>> All
>>>
>>> Once again, I am perplexed. After cloning my VMs from template (via a script using 'knife vsphere vm clone...'), I am trying to add additional vmdks to each VM so we can create additional mount points on different virtual disks.
>>>
>>> Again, I am using 'knife vsphere' but with the vm vmdk add' arguments. It is erroring stating it cannot find the VM.
>>>
>>> I have verified the VM is on the data store.  I have verified in vcenter, the VM is under the expected folder.
>>>
>>> When I issue the command 'knife vsphere vm vmdk list --recursive ...', I see the VM and it is under the expected folder (called VMbuildout)....
>>> But when I execute the command:
>>> 'knife vsphere vm vmdk add  <VM>...'
>>> It errors with "Cannot find <VM>"
>>>
>>> Oh, also, there are NO special characters in the VM's name.
>>>
>>> So...what am I missing here???
>>>
>>> Thanks in advance,
>>> Anna
>>>
>>>
>>> Sent from my iPhone
>







Archive powered by MHonArc 2.6.16.

§