- 新しい順
- 投票が多い順
- コメントが多い順
Did you purchase the domain through AWS using Route 53 or through a third party? And has your purchase definitely gone through and been completed? Depending on the domain it can take a little while, particularly on a day that is not part of the working week.
It's possible to purchase through another registrar, but administer your domain through Route 53 - see steps 1 to 9 of https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/migrate-dns-domain-in-use.html
(If it was Route 53 then the hosted zone will have been setup as part of registration, and the next bit doesn't apply) As you have identified you first have to setup a public hosted zone in Route 53 with the same name as the domain you have purchased, and make a note of the nameserver (NS) records in this new hosted zone. Then on your registrar's side, update the NS records to match those in the Route 53 hosted zone. This can take some time to propagate through, check with the dig
command if that's available, or a site like Google Admin Toolbox Dig https://toolbox.googleapps.com/apps/dig/ that the NS records now start something like ns-1234.awsdns...
Once this is straightened out you should able to add a record pointing to the elastic IP on your EC2 instance.
The following steps were followed to have the problems resolved:
- I tested each a records route 53 hosted zone by creating two A records in the Hosted Zones and pointing it to the Elastic IP address ignoring the IPv4 associated with the domain name, then I tested records using the AWS record testing tab in the hosted zone, and when it returns no queries I saved the settings in the hosted zone.
- I proceeded to the nslookup.io to validate my DNS settings by inputting the Elastic IP address I created, and it returns the same AWS Elastic IP address. Then I tried again using the domain instead of the Elastic IP address, and it returns the Elastic IP address. Which indicates that the domain and Elastic IP address are linked.
- I Configured a new security group to allow my EC2 C7gn instance to accept connections on the following TCP ports: SSH (port 22), HTTP (port 80), and HTTPS (port 443).
- I set up a putty connection to access my EC2 instance, and it was successful.
- I installed an Apache web server with PHP and MariaDB on my EC2 instance using this aws resources https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/CHAP_Tutorials.WebServerDB.CreateWebServer.html
- After the installation, I opened my Chrome browser and entered my Elastic IP address, and It Works. Then I tried again by entering my domain name, IT WORKS.
- I repeated these same procedures for another AWS account having the same problem, IT Works. Thanks