Anand Soni
Anand Soni

Reputation: 5110

Knife - ERROR: Must pass an FQDN or ip to bootstrap

I am creating an EC2 server using knife-ec2 gem. I have created a server using following command:

$ knife ec2 server create --image ami-379ea943 -x ubuntu -d ubuntu10.04-gems -f
 m1.small -i ~/.ssh/mykey --region eu-west-1 -Z eu-west-1a -r "role[
base],role[webserver]"

and i am seeing this info in my command line:

openpath: pathname too long (ignored)
        Directory ""
        File "chcp"
Instance ID: XXXXXXX
Flavor: m1.small
Image: ami-379ea943
Region: eu-west-1
Availability Zone: eu-west-1a
Security Groups: default
SSH Key: mykey

Waiting for server..............................................................
................................................................................
................................................................................
...................................

Waiting for sshddone
ERROR: Must pass an FQDN or ip to bootstrap

The instance is created in terminated status. What is the problem in command? Where is the problem? I don't know where to give the FQDN or ip in this command.

Upvotes: 0

Views: 1630

Answers (1)

MattJ
MattJ

Reputation: 7924

Apparently this happens when the EC2 server simply fails to start. knife times out on 'waiting for server', and so it doesn't have an address for the server. This causes the subsequent SSH attempt to fail immediately, with the error you see.

If the failure was an AWS issue, you might be able to see the reason by going to the EC2 console, selecting the failed instance and looking at the 'State Transition Reason' property there.

Upvotes: 1

Related Questions