@ilarum I was initially thinking like a quick visual check with a text editor like nano in the Terminal but Keychain is logical too. If it couldn’t open it, my guess is something has to be up with that file. Who knows, maybe you suffered a connection hiccup when it was being downloaded and the file isn’t complete or something like that.
IIRC on security grounds you cannot get a private key from AWS once its created and provided to you in its initial response [to the create key request], which would mean you’re out of luck to recover this file.
Rest assured, deleting everything and starting again is probably one of the most efficient things you can do. Since you haven’t ssh’d into your machine yet I think its safe to assume that you aren’t going to lose any work or anything. When the setup script works, its pretty fast.
Deleting is fast too. Point click done.
Login to the AWS console and ensure you’re in the right region (top right toolbar, to the left of the support dropdown). To delete the instance, go to Services > EC2, find it in the “Instances” section, select it and terminate it. To delete the rest of the infrastructure, go to Services > VPC, find the fast-ai-tagged VPC, select it and delete it.
I’m not sure off-hand if the following gets deleted as well, but I suspect your account might hold onto the Elastic IP that was previously attached to your EC2 instance, and also its “hard drive” on EBS. You can check and make sure they’re deleted too to avoid extra charges. The Services > EC2 dashboard has sections for “Volumes” under the ‘Elastic Block Store’ heading. There’s also an “Elastic IPs” section.
If you’ve run the setup script more than once while troubleshooting, you will likely have multiple things created on AWS that you’ll want to kill. Get rid of anything fast-ai to give yourself a clean slate and assure yourself you’re not going to be paying a higher bill at the end of the month than you intended to.
Finally on your Mac, delete the key, e.g.
Before you re-run the setup script make sure you have your aws default set to one of the 3x supported regions, and meet all other prerequisites.
Then re-run the setup script.