Setup problems: AWS

just checked and i did have it as ‘text’. Any other thoughts? Thank you.

I was having exactly the same problem.
Rebooting fixed if for me as well!

1 Like

I am getting the following error during the configuration process, when I run
bash setup_p2.sh
As the error says that there are two instances that I am requesting, but I don’t know where I went wrong. I followed the steps as instructed.
Kindly advice.

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

Enter passphrase for key ‘/home/Sai Kiran/.ssh/aws-key.pem’:

I am getting the above message. Kindly advice.

Hi All,
I am excited to have just started taking this class! I watched the setup videos and read the wiki, however I am getting the following error when I try running the setup_t2.sh (which I downloaded from github):

$ bash setup_t2.sh

An error occurred (AuthFailure) when calling the CreateVpc operation: AWS was not able to validate the provided access credentials
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --vpc-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

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

An error occurred (AuthFailure) when calling the CreateInternetGateway operation: AWS was not able to validate the provided access credentials
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --internet-gateway-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --vpc-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --vpc-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --route-table-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --route-table-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --vpc-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --group-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

aws help
aws help
aws help
aws: error: argument --group-id: expected one argument
usage: aws [options] [ …] [parameters]
To see help text, you can run:

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

An error occurred (AuthFailure) when calling the AllocateAddress operation: AWS was not able to validate the provided access credentials
Waiting for instance start…

Waiter InstanceRunning failed: AWS was not able to validate the provided access credentials
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 (AuthFailure) when calling the DescribeInstances operation: AWS was not able to validate the provided access credentials
securityGroupId=
subnetId=
instanceId=
instanceUrl=
To Connect:
ssh -i /home/New User/.ssh/aws-key.pem ubuntu@
alias t2="ssh -i /home/New User/.ssh/aws-key.pem ubuntu@"
source ai_aliases.sh to get t2 command to connect to t2 instance

What am I doing wrong? I followed all the setup instructions in the video (I don’t yet have my p2 instance).

Thanks! :slight_smile:
Christina

1 Like

I had already setup a GPU in Oregon, but realised where the latency was high, so I decided to go for the Ireland solution. As I recall the referenced AMI in the GitHub script for Ireland did not refer to the proper AMI, I searched in the public AMI repository in Ireland for the correct AMI, and fixed that. At that point I realised that the script for Oregon and Irland was different, so i decided to take a copy of the Oregon script, and make the changes necessary for it to work in Irland. The next thing was that the script tried to overwrite my local pem-file for the Oregon setup, so i decided to change the name of the local pem-file to something different. All in all and now have both a working GPU in Oregon and in Irland.

Thank you for making the deep learning course available to the rest of the world, and I am looking forward to take the lessons in the new year.

2 Likes

Hi Christina,

it looks like AWS does not authorize your requests.

Do you have proper access_key and secret_key in ~/.aws/credentials? If not, you need to re-run aws configure and provide proper values for them.

Alex, thanks for the reply!

I checked, and yes I have the valid access_key and secret_key in ~/.aws/credentials. Just to be sure, I re-ran aws configure, got a new credentials file and verified that too. I still get the same error.

Do you think I need to start over and create a new access key?

Thanks Christina

1 Like

I think it will be the fastest solution.

Tip: to quickly check your aws cli working correclty issue aws ec2 describe-instances. You should see the empty output in case you are able to connect and an error if something whent wrong. When you have instances created this command will print information about them.

Alex, thanks again! :slight_smile:

I created a new access key & secret key, and now I no longer get that error. However, I now get a different error:

$ bash setup_t2.sh
rtbassoc-2936cf51
True

An error occurred (InvalidAMIID.NotFound) when calling the RunInstances operation: The image id ‘[ami-f8fd5998]’ does not exist
Waiting for instance start…
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
securityGroupId=sg-ba627fc7
subnetId=subnet-fcf693a7
instanceId=
instanceUrl=ec2-52-23-209-17.compute-1.amazonaws.com
To Connect:
ssh -i /home/New User/.ssh/aws-key.pem ubuntu@ec2-52-23-209-17.compute-1.amazonaws.com
alias t2="ssh -i /home/New User/.ssh/aws-key.pem ubuntu@ec2-52-23-209-17.compute-1.amazonaws.com"
source ai_aliases.sh to get t2 command to connect to t2 instance

The script seems to have completed, but is the > InvalidAMIID.NotFound error something I need to be concerned about?

Thanks again,
Christina

Which region do you use? For script to work it should be Oregon (us-west-2)

You can check your region with this command.

cat ~/.aws/config

Got it. I have been using N. Virginia since I am on the east coast. So I just changed my default region to us-west-2. I re-ran and now get this error:

$ bash setup_t2.sh
rtbassoc-ec88098a
True

An error occurred (InvalidKeyPair.NotFound) when calling the RunInstances operation: The key pair ‘aws-key’ does not exist
Waiting for instance start…
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
securityGroupId=sg-7d579205
subnetId=subnet-0989406e
instanceId=
instanceUrl=ec2-35-164-242-170.us-west-2.compute.amazonaws.com
To Connect:
ssh -i /home/New User/.ssh/aws-key.pem ubuntu@ec2-35-164-242-170.us-west-2.compute.amazonaws.com
alias t2="ssh -i /home/New User/.ssh/aws-key.pem ubuntu@ec2-35-164-242-170.us-west-2.compute.amazonaws.com"
source ai_aliases.sh to get t2 command to connect to t2 instance

This is starting to get frustrating. Do I need to once again regenerate the aws key?

Thanks Christina

It looks like your previous attempts to run the script generated ~/.ssh/aws-key.pem but not created keypair in the cloud. Try deleting the file and running the script again.

2 Likes

Alex, thank you so much! I did that and it worked. I am now up and running on a T2 instance! :slight_smile:

Christina

1 Like

Great! :slight_smile:

@sakiran That means that you have already created a p2 instance, so you should be able to start the instance and ssh into it (you only need to successfully run setup_p2.sh once).

The aws-alias.sh script makes it easier to connect to your instance once it’s setup

Can you tell me what you see if you run aws ec2 describe-route-tables?

What OS are you using? What python?

Hi Mazharul, Everyone,

I am seeing this issue too with nvidia-smi. I tried re-installing/updating the nvidia kernel module but that did not seem to help.

Any ideas to fix this?

ubuntu@ip-10-0-0-4:~$ nvidia-smi
Failed to initialize NVML: Driver/library version mismatch

ubuntu@ip-10-0-0-4:~$ cat /proc/driver/nvidia/version
NVRM version: NVIDIA UNIX x86_64 Kernel Module 367.48 Sat Sep 3 18:21:08 PDT 2016
GCC version: gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.2)

ubuntu@ip-10-0-0-4:~$ nvcc -V
nvcc: NVIDIA ® Cuda compiler driver
Copyright © 2005-2016 NVIDIA Corporation
Built on Sun_Sep__4_22:14:01_CDT_2016
Cuda compilation tools, release 8.0, V8.0.44

ubuntu@ip-10-0-0-4:~$ whereis nvml.h
nvml: /usr/include/nvml.h

ubuntu@ip-10-0-0-4:~$ sudo find / -name ‘libnvidia-ml*’
/usr/lib32/nvidia-367/libnvidia-ml.so.1
/usr/lib32/nvidia-367/libnvidia-ml.so
/usr/lib32/nvidia-367/libnvidia-ml.so.367.57
/usr/lib/nvidia-367/libnvidia-ml.so.1
/usr/lib/nvidia-367/libnvidia-ml.so
/usr/lib/nvidia-367/libnvidia-ml.so.367.57
/usr/local/cuda-8.0/targets/x86_64-linux/lib/stubs/libnvidia-ml.so

thanks
–Krish

thank you for your continued help.

In regard to running the command:
$ aws ec2 describe-route-tables
ROUTETABLES rtb-a05529c5 vpc-11572074
ASSOCIATIONS True rtbassoc-444a0021 rtb-a05529c5
ROUTES 172.31.0.0/16 local CreateRouteTable active
ROUTES 0.0.0.0/0 igw-be50d5db CreateRoute active
ROUTETABLES rtb-c8641eaf vpc-717ad316
ASSOCIATIONS False rtbassoc-5b50d63d rtb-c8641eaf subnet-ead131a3
ROUTES 10.0.0.0/28 local CreateRouteTable active
ROUTETABLES rtb-0fb1cf68 vpc-409c3027
ASSOCIATIONS False rtbassoc-9a02b9fc rtb-0fb1cf68 subnet-cddb3c84
ROUTES 10.0.0.0/28 local CreateRouteTable active
ROUTETABLES rtb-02b1cf65 vpc-409c3027
ASSOCIATIONS True rtbassoc-9702b9f1 rtb-02b1cf65
ROUTES 10.0.0.0/28 local CreateRouteTable active
ROUTETABLES rtb-c3641ea4 vpc-717ad316
ASSOCIATIONS True rtbassoc-4c50d62a rtb-c3641ea4
ROUTES 10.0.0.0/28 local CreateRouteTable active

in regards to OS:
Windos 10 64bit

python
$ python -V
Python 3.5.2 :: Anaconda 4.1.1 (64-bit)

Thanks Alex for the help :slight_smile: