How to see the address range of IPv6

Source: Internet
Author: User
Tags unpack
What do you think of IPv6 's address range?
I will not look at the address range of IPv6, such as the following two address range refers to from which address to which address ah?
2406:6200::|32
240e:100::|24
Why are the usual IP libraries separate, and what are the problems in the same table?

------Solution--------------------
This is all 16 binary representations, 2 bytes one:.

:: That means the next 0.

MySQL still can operate, Unhex Ah, substring,replace Ah, see you need.
------Solution--------------------
IP address can be compared to the size of the string, to calculate the range of each IP, you can gmp/bc directly as a large number of operations, I am talking about PHP, you have the need to write an example for you?
------Solution--------------------
PHP Code
[User:root time:09:54:16 path:/home/liangdong/php]$ php ip.php 2406:6200:0000:0000:0000:0000:0000:0000[user:root Time:09:54:17 path:/home/liangdong/php]$ Cat ip.php
  
------Solution--------------------
discuss

PHP Code
[User:root time:09:54:16 path:/home/liangdong/php]$ php ip.php
2406:6200:0000:0000:0000:0000:0000:0000[user:root time:09:54:17 path:/home/liangdong/php]$ Cat ip.php
$IPV 6_start = "2 ...

------Solution--------------------
2400:ff00::|32
should be from
2400:ff00:0000:0000:0000:0000:0000:0000
-
2400:ff00:0000:0000:0000:0000:ffff:ffff
The following CIDR is the number of bits, and 32 bits is FFFF:FFFF


  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.