Error while setting up AWS instance

I have requested ec2 limit increase and it is granted but when I run setup_p2.sh , I’m getting this error

True

An error occurred (InstanceLimitExceeded) when calling the RunInstances operation: You have requested more instances (1) than your current instance limit of 0 allows for the specified instance type. Please visit http://aws.amazon.com/contact-us/ec2-request to request an adjustment to this limit.

An error occurred (MissingParameter) when calling the CreateTags operation: The request must contain the parameter resourceIdSet
Waiting for instance start…

Waiter InstanceRunning failed: Max attempts exceeded
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --instance-id: expected one argument

An error occurred (MissingParameter) when calling the RebootInstances operation: The request must contain the parameter InstancesSet

All done. Find all you need to connect in the fast-ai-commands.txt file and to remove the stack call fast-ai-remove.sh
Connect to your instance: ssh -i /home/bithu/.ssh/aws-key-fast-ai.pem ubuntu@None

Have you configures aws command line with correct region name? The set limits for the region which you requested.
When you go to AWS Management Console web interface, EC2 -> Limits section, what limit is displayed for p2.xlarge?

The default limit is 20 instances (I believe this is across regions). Do you have other instances running?

As intstructed in the video , I have asked for a limit increase in g2.2xlarge and it is allocated, but the script shows this error

No instances are running

Upon closer inspection of the error I see the problem.

“An error occurred (InstanceLimitExceeded) when calling the RunInstances operation: You have requested more instances (1) than your current instance limit of 0 allows for the specified instance type.”

So AWS will not allow you to setup any instances of that type right now without an increase. If your request went through, I would suggest starting with a p2.xlarge and not g2.2xlarge.

2 Likes

Info in the video could be outdated. Now the AWS install walkthrough video has an overlay that says "Ignore what I’m saying here - instead request “p2.xlarge”, and for limit value, choose “1"”

setup_p2.sh script operates with P2 instances:

export instanceType=“p2.xlarge”

Try to request increasing a limit for p2.xlarge.

If this works, please edit info on the Lesson 1 wiki page. I don’t have edit permissions there.

1 Like

I’m using MacOs, and ran into the same problem. In the directory in which setup_p2.sh was housed, I ran the command “rm aws-key-fast-ai.pem” to delete the file, and then ran" rm -r .ssh" to remove the folder it was housed in, though I’m not sure if that’s necessary.

I’m getting this error as well… I’ve been following this guide: AWS EC2 | Practical Deep Learning for Coders