Configure my Linode to use IPv6
I recently added an IPv6 pool to my Linode. After reading through your IPv6 Guide, I found that the critical change is to modify this file /etc/network/interfaces (my Linode is a Ubuntu).
But in the example provided in this web page, I could not find the mapping from the host name to the IPv6 address. Please keep in mind that I am looking for a solution to map my 2 websites to a different IPv6 address, while keep my another 1 website mapping to the original IPv4 address.
Could you please give me more advice on how to modify this file. Thank you!
If I'm understanding your question correctly, you are looking to direct requests for 2 of your domains to different IPv6 addresses, while keeping your DNS record for your IPv4 address active. If this is the case, then you will need to create a AAAA record (this is the IPv6 equivalent of an A record) for each address that points to the IPv6 address on which you are hosting your site. You'll need to create a separate record for each domain. I have linked our guide on DNS records, specifically the section on A and AAAA records.
As for the /etc/network/interfaces file, you are correct that this is how you enable IPv6. I found this post about configuring IPv6 on an Ubuntu machine. The main thing I'd like to point out about this particular guide is that you want to pay close attention to the wording, as some of the commands are redundant and in some cases even deprecated. This is presumably to help users who have different/older versions of Ubuntu installed. Some examples I would like to call out:
ifconfig eth0 ip -6 address show eth0
'ifconfig' is a deprecated command, used in older distributions and has mostly been replaced by the 'ip' command. Most distributions still have both installed (or at least available in their repositories) for backwards compatibility, but 'ip' is the preferred command in most cases. Also:
/etc/init.d/networking restart systemctl restart networking
The guide gives some explanation of the difference between the 2 commands, but it's essentially the same deal: '/etc/init.d/<service> <command>' is a deprecated format and is left in the guide for backwards compatibility. Most systems in use these days will allow you to use either the 'systemctl' or 'service' commands. 'service' is a wrapper for both '/etc/init.d' and 'systemctl', so in most cases this will work just fine. Examples of the 2 commands in action:</service>
systemctl restart networking service networking restart
As you can see, they are both invoked following a similar syntax, but the action/service name go in different places, depending which command you are using.
I hope this gets you pointed in the right direction! Just let us know if you encounter any issues or need clarification on anything and we'll be happy to help out in any way that we're able!
Linode Support Team
I followed the steps and went to 'DNS Manager', click 'Edit' on the host name where I want to change the mapping, and did the following:
At the 'A/AAAA Records' section, remove all current mappings to and change all mappings to the new ipv6 address.
And then I rebooted the machine.
But after some time, when the change started to take effect, I found that I could not ping the host name again. Here is the error from 'ping xxxx':
"Ping request could not find host xxxx. Please check the name and try again."
Looks like the DNS manager has problem doing the resolution. Could you please advise?