Skip to content
This repository has been archived by the owner on Nov 29, 2017. It is now read-only.

Knife solo fails with "ERROR: ArgumentError: wrong number of arguments (1 for 0)" #63

Open
temujin9 opened this issue Aug 26, 2014 · 6 comments

Comments

@temujin9
Copy link

Trying to build a Cloudfoundry setup, but the inception server predictably fails to build in my environment (this reoccurs even after an inception delete):

∵ temujin9@takni:~/Projects/Bazaarvoice/project/DaaS ∴ inception deploy

Confirming: Using AWS/us-west-2

Preparing deployment settings

Using your git user.name (Nathaniel Eliot)
Acquiring a public IP address... 54.214.43.245

Provision inception server

Reusing security group ssh
Booting m1.small inception server... i-b36435be
Confirming ssh access to server... done
Provisioning 16Gb persistent disk for inception server... i-b36435be

Prepare inception server

knife solo prepare [email protected] -i /home/temujin9/.inception_server/ssh/inception -j '{"disk":{"mounted":true,"device":"/dev/xvdf"},"git":{"name":"Nathaniel Eliot","email":"[email protected]"},"user":{"username":"ubuntu"},"fog":{"aws_access_key_id":"REDACTED","aws_secret_access_key":"REDACTED"}}' -r 'bosh_inception'
WARNING: No knife configuration file found
Bootstrapping Chef...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16519  100 16519    0     0  48230      0 --:--:-- --:--:-- --:--:-- 50057
Downloading Chef 11.14.6 for ubuntu...
downloading https://www.opscode.com/chef/metadata?v=11.14.6&prerelease=false&nightlies=false&p=ubuntu&pv=13.04&m=x86_64
  to file /tmp/install.sh.2064/metadata.txt
trying wget...
url     https://opscode-omnibus-packages.s3.amazonaws.com/ubuntu/13.04/x86_64/chef_11.14.6-1_amd64.deb
md5     8f6735d01eeeb37e979aa2443ecee8c8
sha256  a0a53055f77baafd8ad254a391557618c3af7367a2b69b703d2ef06de41699be
downloaded metadata file looks valid...
downloading https://opscode-omnibus-packages.s3.amazonaws.com/ubuntu/13.04/x86_64/chef_11.14.6-1_amd64.deb
  to file /tmp/install.sh.2064/chef_11.14.6-1_amd64.deb
trying wget...
Comparing checksum with sha256sum...
Installing Chef 11.14.6
installing with dpkg...
Selecting previously unselected package chef.
(Reading database ... 52215 files and directories currently installed.)
Unpacking chef (from .../chef_11.14.6-1_amd64.deb) ...
Setting up chef (11.14.6-1) ...
Thank you for installing Chef!
Generating node config 'nodes/ec2-50-112-52-174.us-west-2.compute.amazonaws.com.json'...
knife solo cook [email protected] -i /home/temujin9/.inception_server/ssh/inception -j '{"disk":{"mounted":true,"device":"/dev/xvdf"},"git":{"name":"Nathaniel Eliot","email":"[email protected]"},"user":{"username":"ubuntu"},"fog":{"aws_access_key_id":"REDACTED","aws_secret_access_key":"REDACTED"}}' -r 'bosh_inception'
WARNING: No knife configuration file found
Running Chef on ec2-50-112-52-174.us-west-2.compute.amazonaws.com...
Checking Chef version...
Installing Berkshelf cookbooks to '/home/temujin9/.berkshelf/knife-solo/0c041c64b878b586438f82e0dd637de0f435861c'...
DEPRECATED: Your Berksfile contains a site location pointing to the Opscode Community Site (site :opscode). Site locations have been replaced by the source location. Change this to: 'source "https://supermarket.getchef.com"' to remove this warning. For more information visit https://github.com/berkshelf/berkshelf/wiki/deprecated-locations
ERROR: ArgumentError: wrong number of arguments (1 for 0)
/usr/lib/ruby/vendor_ruby/rake/file_utils.rb:53:in `block in create_shell_runner': Command failed with status (100): [knife solo cook [email protected]...] (RuntimeError)
        from /usr/lib/ruby/vendor_ruby/rake/file_utils.rb:45:in `call'
        from /usr/lib/ruby/vendor_ruby/rake/file_utils.rb:45:in `sh'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/inception_server_cookbook.rb:39:in `knife_solo'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/inception_server_cookbook.rb:26:in `block in converge'
        from /usr/lib/ruby/1.9.1/fileutils.rb:125:in `chdir'
        from /usr/lib/ruby/1.9.1/fileutils.rb:125:in `cd'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/inception_server_cookbook.rb:25:in `converge'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/cli.rb:143:in `converge_cookbooks'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/cli.rb:35:in `deploy'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/bin/inception:8:in `<top (required)>'
        from /usr/local/bin/inception:23:in `load'
        from /usr/local/bin/inception:23:in `<main>'

Retrying after this failure results in:

 ∵ temujin9@takni:~/Projects/Bazaarvoice/project/DaaS ∴ inception deploy

Confirming: Using AWS/us-west-2

Preparing deployment settings

Using your git user.name (Nathaniel Eliot)

Provision inception server

Reusing security group ssh
Confirming ssh access to server... /var/lib/gems/1.9.1/gems/fog-core-1.24.0/lib/fog/core/wait_for.rb:11:in `wait_for': The specified wait_for timeout (60 seconds) was exceeded (Fog::Errors::TimeoutError)
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/inception_server.rb:271:in `attach_persistent_disk'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/inception_server.rb:67:in `create'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/cli.rb:119:in `perform_deploy'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/lib/inception/cli.rb:34:in `deploy'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
        from /var/lib/gems/1.9.1/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
        from /var/lib/gems/1.9.1/gems/inception-server-0.3.0/bin/inception:8:in `<top (required)>'
        from /usr/local/bin/inception:23:in `load'
        from /usr/local/bin/inception:23:in `<main>'

However, inception ssh works just fine, after the initial deploy failure.

@temujin9
Copy link
Author

This appears to be an issue with host key checking and/or known hosts: running with an appropriate ssh config block

Host "REDACTED"
  User ubuntu
  UserKnownHostsFile /dev/null
  StrictHostKeyChecking no

sidesteps this issue. There should be some way to force these configuration options from within Fog.

@aeneasr
Copy link

aeneasr commented Mar 2, 2015

in what file did you put these values? @temujin9


nevermind, I overread "ssh config block" :)

@aeneasr
Copy link

aeneasr commented Mar 3, 2015

I tried it on mac os:

echo '
Host "ec2*.amazonaws.com"
  User ubuntu
  UserKnownHostsFile /dev/null
  StrictHostKeyChecking no' >> ~/.ssh/config

It didn't solve the issue however.

@aeneasr
Copy link

aeneasr commented Mar 3, 2015

I've tried it on ubuntu/trusty32 as well, no luck.

@temujin9
Copy link
Author

temujin9 commented Mar 3, 2015

Unfortunately, this was months ago, and I've not touched this particular project since then. I can't provide any more help here than I already have. Sorry!

@aeneasr
Copy link

aeneasr commented Mar 3, 2015

sure, no harm taken :)

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

No branches or pull requests

2 participants