Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined method `[]' for nil:NilClass in close_vsphere action #124

Closed
jreslock opened this issue Mar 25, 2015 · 3 comments
Closed

undefined method `[]' for nil:NilClass in close_vsphere action #124

jreslock opened this issue Mar 25, 2015 · 3 comments

Comments

@jreslock
Copy link

I have encountered an issue that appears to be intermittent in nature with vagrant up --provider=vsphere and multi-machine configuration.

Here are some details plus a link to a gist for files.

vagrant version 1.7.2
vagrant-vsphere version 1.0.1
vsphere version 5.5.0
guest OS is CentOS 6.4.

Just after 'Setting hostname...' is posted to stdout I receive an error which stops the rest of the vagrant machines from being started.

ERROR:

INFO interface: Machine: error-exit ["VagrantPlugins::VSphere::Errors::VSphereError", "undefined method `[]' for nil:NilClass"]

Gist: https://gist.github.com/jreslock/a3b1ba8e3f9cc6c1af3b

@jreslock
Copy link
Author

I was able to resolve this issue by downgrading from vagrant 1.7.2 to 1.6.4.

@jkugler
Copy link

jkugler commented Mar 12, 2019

I am also getting this as well with vagrant-vsphere 1.13.2 and vagrant 2.2.4. This is what I get in my test kichen output:

-----> Creating <source-centos-6-bento>...
       Bringing machine 'default' up with 'vsphere' provider...
       ==> default: Calling vSphere CloneVM with the following settings:
       ==> default:  -- Template VM: B5 Lab - Folder/vm/CICD/bento-centos-6.10-x86_64-LATEST
       ==> default:  -- Target VM: B5 Lab - Folder/vm/CICD/source-centos-6-bento-app-access-1551294901-dc
       ==> default: New virtual machine successfully cloned
       ==> default: Waiting for the machine to report its IP address...
           default: Timeout: 240 seconds
           default: IP: 10.199.251.66
       ==> default: Waiting for machine to boot. This may take a few minutes...
           default: SSH address: 10.199.251.66:22
           default: SSH username: vagrant
           default: SSH auth method: private key
           default: 
           default: Vagrant insecure key detected. Vagrant will automatically replace
           default: this with a newly generated keypair for better security.
           default: 
           default: Inserting generated public key within guest...
           default: Removing insecure key from the guest if it's present...
           default: Key inserted! Disconnecting and reconnecting using new SSH key...
       ==> default: Machine booted and ready!
       ==> default: Setting hostname...
       undefined method `[]' for nil:NilClass

What would be the best way to go about debugging this?

@jreslock
Copy link
Author

@jkugler You should probably open a new issue for this as my original report is from 2015 and sort of abandoned because I found a workaround. I'm going to close this issue as I wasn't aware it was still open.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants