IP Redirect using DNS Server - server

For my current project I have an ADDS set up. The ADDS also has a DNS Server installed as a role. The name of my ADDS is corp.nikali.lan. I have to use the DNS Server role to redirect.
The IP address of outlook.com should be reachable by typing email.corp.nikali.lan.
At the moment all I have is the basic set-up after downloading the DNS feature. No added records or anything else.

CNAME record - records refer to an alias or redirect for a specific site or subdomain.
Two CNAME fields:
Name
Destination
Common CNAME entries:
Name: www
Destination: #
(or "yourwebsite.com")
Best example :
www.facebook.com and fb.com , some people are using a shortcut word like fb.com , you need to configure in your (NS) Name server , like the example above CNAME entries.

Related

AWS Route53 | Alias record from other DNS providers

My client has a domain address on Godaddy and I would like to just connect A record to AWS Api Gateway without changing NS records because my client using other records such as MX and etc on Godaddy and would stay on it.
In Route53 we can create records by alias directly but in this case I'm not sure how could it be possible.
I just did something similar with Amplify and I just imported the domain, changed the CNAME (following the Amplify docs - https://docs.aws.amazon.com/amplify/latest/userguide/to-add-a-custom-domain-managed-by-a-third-party-dns-provider.html).
For API gateway, it might be a little different but I think you can go to Route 53 resolver and look for the inbound query link and then send it to your VPC of your Api Gateway endpoint.
Base on my recent searches on AWS documents and also Evan's document, there is no way without ANAME (Alias Name Record) that must provided by your DNS provider.
I'm not sure that my customer accept migration from existing DNS provider but I'm going to suggest below as our second solution:
example.com couldn't set by ANAME but www.example.com could set CNAME then we can make a simple redirect from example.com to www.example.com.
I think Godaddy providing url redirect by default otherwise we must run an EC2 just for this redirection.
I know it sucks but it seems that there is no any other way.
I will appreciated If someone knows better solution.

Subdomain created but not running properly

I'm not sure if this question belongs here but because it is a technical question so I'm asking it here. Feel free to move it to any appropriate website of Stack exchange.
My problem is I have created a subdomain successfully on my website through cpanel and also put an index.html file in it to test it. But when I run it in browser it is not showing contents of index.html file. It shows following errors:
DNS address could not be found and ERR_NAME_NOT_RESOLVED errors. Can someone please tell me how to resolve this problem?
You must be missing A record pointing to your sub domain in your domain panel.
Record Point to TTL
A sub 300
Please check the DNS servers for your domain. You might be using external DNS servers. When you create a subdomain on cPanel, a DNS entry is created in the DNS zone for that subdomain pointing to your server ip. If your domain uses external DNS servers then those servers will be queried to find the ip address for that subdomain. In this case you should manually edit your DNS zone and add an A record for that subdomain to point to your server's ip).
Thanks for all the answers. Here is how solved my problem. The problem was that I have purchased a hosting with one domain name. I also have another domain purchase but there is no hostng on it. I had pointed the second domain to first domain which also has hosting support. So what I was doing is I was creating subdomain on second one on the first domain. But it was not recognising it and showing DNS problem. So I made an entry A record entry in the second domain about the subdomain which I wanted to create on it. And then in 5 minutes DNS was updated and issue was resolved.
After adding the subdomain, go to the DNS editor of the domain and add a CNAME record for the subdomain.
For example:
NAME TYPE VALUE
--------------------------------------------------
subdomain.example.com. CNAME example.com.

Redirecting sub-domain to specific URI

I want to redirect my subdomain to specific URI without making any changes to my code.
I found the domain forwarding services from Bigrock, they have a sub-domain forwarding service which specifies all subdomains will be redirected as "subdomain.mydomain.com to yourdestinationurl/subdomain/"
I replaced yourdestinationurl, with www.mydomain.com but it's not working.
Am I doing something wrong?Is there any alternative way to do this?
You may create the subdomain in the DNS Manager/Domain name zone file and point it to any URL using 'URL-Redirect' DNS record.
In other words, you need to login into the account of your domain name registrar (if the domain name is delegated to the default nameservers) or into your hosting cPanel (if you have a hosting plan). Then you need to find where to configure DNS records and configure URL-Redirect (also called URL-Forwarding) for your subdomain.
There is no need to have any plugins.

Basic setup of Google Cloud DNS for Tomcat container

I've recently setup a new Tomcat instance on Google Compute Engine and I can access my Tomcat instance via its IP address in the browser.
I've now setup a Cloud DNS entry and had my domain registrar point my domain name to the Cloud DNS servers. However this was 2 days ago and I still can't access my website via the domain name.
The WHOIS record shows the following Name Server entries
Name Server ns-cloud-e1.googledomains.com
Name Server ns-cloud-e2.googledomains.com
Name Server ns-cloud-e3.googledomains.com
Name Server ns-cloud-e4.googledomains.com
I've also setup an A record in the Cloud DNS console based on the feedback of my domain registrar. Is there anything else I need to setup in order for all this to work?
[EDIT 1] Having a look again at the instructions provided by Google it seems the name server names they wanted me to use have changed to
ns-cloud-d1.googledomains.com.
ns-cloud-d2.googledomains.com.
ns-cloud-d3.googledomains.com.
ns-cloud-d4.googledomains.com.
I've asked my registrar to make the change in case this is the problem.
[EDIT 2] My registrar has updated my DNS records and they resolve to Google's servers. However my website still doesn't show when entered into a browser I get an NXDOMAIN error, which implies my domain doesn't exist. Does anyone have a basic example of what the Cloud DNS settings should look like? Do I need to setup A records or CNAME records?
[EDIT3] My setup is shown here (domain name and IP addresses have been faked for screenshot)
Thanks in advance.
Andy.
OK, I finally worked out the problem.
In the screenshot in my question the following changes were required.
1) Replace the A record for *.andtest.com.au with an A record for just andtest.com.au
2) Replace the www.andtest.com.au A record with a CNAME record for www.andtest.com.au which points to andtest.com.au
Now when I enter www.andtest.com.au in a browser, I see my Tomcat web page.

How do I redirect a naked (apex) domain to www using Route 53?

I need to do a 301 redirect from example.com to www.example.com using Route 53 (and S3 if necessary). There are a few solutions for similar problems but they either do not address how to redirect from the apex or they simply don't work.
When I follow the steps here, Route 53 tells me I can't add a CNAME to the apex domain. Therefore, I'm stuck in the mud.
This seems dumb simple but Amazon is making it hard. Any help would be appreciated.
I just managed to figure this out yesterday:
Go to your S3 console at https://console.aws.amazon.com/s3/home and click Create bucket. For Bucket name enter in your naked domain name, e.g. for www.example.com, you would put just example.com. Then click Create.
Click on the name of the new bucket, then click Properties > Static website hosting. On the menu that appears select Redirect requests. For Target bucket or domain enter in the full domain, such as www.example.com. For Protocol put in the desired protocol, http or https. Click Save.
Open your Route 53 hosted zone by navigating to https://console.aws.amazon.com/route53/home and clicking Hosted zones in the menu to the left. Select your domain and click on Create Record Set. Leave the Name area blank, and leave the default type at A - IPv4 address. Select Yes for Alias, and click on the Alias Target textbox. You may have to wait a few moments for the values in the dropdown menu that appears to populate. At this point the menu should contain the S3 Website Endpoint you created in steps 1 and 2. Select it.
Lastly, click Create, and enjoy your new routing set-up!
Try making an alias record instead of CNAME.
Per this answer:
RRSet of type CNAME with DNS name foo.com. is not permitted at apex in zone bar.com
If you are using an Application Load Balancer, they added support for redirects. You point your zone apex at your ELB (using an Alias) and have ELB do the redirect to www.example.com
This seems like a much better solution than setting up a bucket, adding static hosting, redirect, etc.
https://aws.amazon.com/about-aws/whats-new/2018/07/elastic-load-balancing-announces-support-for-redirects-and-fixed-responses-for-application-load-balancer/
The necessary steps are as follows:
Create a new Bucket and call it exactly as your naked domain name (eg: example.com).
In the Bucket properties, select "Static Website Hosting" and make it redirect to your www.example.com domain. Click "save".
Go to your Route53 hosted zone, and create an A record. Mark it as an Alias, and from the dropdown select your recently created bucket.
You're ready.
For those who need to redirect a naked domain example.com to www.example.com
The best practice is to create a new Load Balancer
with Listener on port 80 http that redirect 301 to www.example.com
In case you have https running just add another listener on port 443 that redirect 301 to www.example.com
Once you have finished with the listeners go to
Route 53 > your domain> Create Record
that points your new load balancer with the redirect listeners
record name: example.com
Record Type: A
Alias: Yes
Alias to Application and Load Balancer...
Select your location
Select your new Load Balancer
Save it and wait some minutes and now all request for naked example.com redirect 301 to www.example included for https request.
Note:
If you want to redirect http request to https request you need to do the same procedure but instead of a redirect listener you need to set-up a forward listener to https.