What happens if an IPv4 client tries to access an IPv6-only server (SOLVED)
April 9, 2022
Question:
Hey! The article says that IPv6 is a completely different protocol, I had a question. If my recipient's email works only on IPv6 (that is, his mail server listens only through the IPv6 protocol), does this mean that when sending a letter from a mail server that is connected only to IPv4, the letter simply will not reach the recipient, that is, I will have to choose some kind of mail service whose mail server works with both IPv6 and IPv4 so that my friend can read my letter?
Answer:
The considered situation, when one server has only an IPv4 address, and the second server has only an IPv6 address, is purely theoretical. ISPs that use IPv6 and provide IPv6 addresses to customers also provide IPv4 addresses at the same time.
For example, this router is connected to an ISP that supports IPv6. However, a router has two types of IP addresses:
- 10.241.24.29
- 2001:fb1:fc0:135:20e8:31d0:4821:6624
My computer is connected to this router, so it also has two types of IP addresses:
- 192.168.1.58
- 2001:fb1:139:20d8:82c0:cb25:b750:24d4
Note that IPv4 and IPv6 are such separate networks that for IPv6, the router has its own DNS server IP – 2001:fb0:100::207:49.
The same is true for hosting providers. For example, ISPs in my country do not support IPv6. But at the same time, hosting providers in my country have been supporting IPv6 for a very long time (for example, I set up IPv6 for SuIP.biz back in 2016, while one rented VPS server came with one free IPv4 and 3 free IPv6).
You can search for websites with IPv6 support and look at their DNS records – you will see that in addition to the AAAA record (IPv6 address of the site), there is also an A record for the site (IPv4 address of the site).
That is, yes, if one of the computers (client or server1) is connected only to an IPv4 network, and the second computer (server or server2) is connected only to an IPv6 network, then theoretically it is simply impossible to build a network route between them from the first to the second. But in practice, this problem does not arise simply for the reason that absolutely all clients and servers support IPv4, and some also support IPv6. That is, all possible combinations work according to one of the following options:
- client and server support IPv6 – IPv6 is used
- client supports IPv6 and server does not support IPv6 – IPv4 is used
- client does not support IPv6 and server supports IPv6 – IPv4 is used
- client does not support IPv6 and server does not support IPv6 – IPv4 is used
However, it is possible to isolate an IPv6-enabled server from an IPv4 network, which is what I talk about in the section “How to configure SSH to work with IPv6 only”.
In short: IPv4 and IPv6 are two different networks, even though they run on the same wires and on the same hardware.
If you're interested in a specific error, when you try to open an IPv6-only site from an IPv4-only client, you get the “Network is unreachable” error.
Another example of an error: if you try to run the following command from an IPv6-enabled network:
sudo nmap -6 suip.biz
then the host suip.biz will be scanned.
If you run the same command from a network without IPv6 support, an error will be displayed: “setup_target: failed to determine route to suip.biz (2a02:f680:1:1100::3d60)”.
See also detailed IPv6 guides:
- Introduction to IPv6 Addresses: How to Use and How to Explore the Network (Part 1)
- Introduction to IPv6 Addresses: How to Use and How to Explore the Network (Part 2)
Online services with IPv6 support:
- Do I have IPv6
- Online whois service with IPv6 support
- Find out the location and Internet service provider by IPv6
- IPv6 Subnet Calculator
- Decompression (full form) IPv6
- Scanning IPv6 addresses for open port
- IP, IPv6, web-sites ping
- Traceroute the path to IP and IPv6 addresses, as well as websites
Related articles:
- How to check if my router supports IPv6 (70.7%)
- How to configure Squid to use IPv4 (69.6%)
- Script to connect and disconnect from OpenVPN depending on server availability (56.3%)
- How to block by Referer, User Agent, URL, query string, IP and their combinations in mod_rewrite (53.9%)
- How to protect my website from bots (53.9%)
- Windows guest OS freezes in VirtualBox 7 (SOLVED) (RANDOM - 50.5%)