Reputation: 360
The docs for knife say that --node-name is the name of the node to be configured (added to server list of nodes). When I put in "node2", I get a message:
Chef encountered an error attempting to load the node data for "node2"
When I use my chef user name it works. But then my node in the server list of nodes is the user name as well.
I'm missing something pretty basic - can someone help me understand what's going on?
Here's the command I'm using:
# Fails
knife bootstrap myfqdn:port --ssh-user myrootname --ssh-password mypassword --sudo --use-sudo-password --node-name node2 --run-list 'myrunlist'
# works, sort of
knife bootstrap myfqdn:port --ssh-user myrootname --ssh-password mypassword --sudo --use-sudo-password --node-name mychefusername --run-list 'myrunlist'
Upvotes: 0
Views: 456
Reputation: 1
Node names must be unique when specified within the client.rb or knife.rb file wherever you are doing so. This will ensure that the chef-server has only one instance with that particular node name and doesn't hold several instances within the chef-server by the same name. So try changing the node-name and try running this. This should work.
Hope this helps,
Regards
Akshay
Upvotes: 0
Reputation: 11
I think "node2" is already registered in your Chef-Server. Node Name must be unique.
Upvotes: 1