I have a similar table (ip_lookup) with 5.2 million rows.
CREATE TABLE `ip_lookup` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`start` varbinary(16) DEFAULT NULL,
`end` varbinary(16) DEFAULT NULL,
`continent` varchar(45) DEFAULT NULL,
`country` varchar(45) DEFAULT NULL,
`area` varchar(45) DEFAULT NULL,
`city` varchar(145) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `idx_iplookup_ip` (`start`,`end`),
KEY `idx_ip_lookup_end` (`end`)
) ENGINE=InnoDB AUTO_INCREMENT=5277083 DEFAULT CHARSET=utf8;
FYI, here's a benchmark comparison of those two queries
mysql> SELECT id, country, area, city
-> FROM ip_lookup
-> WHERE INET6_ATON('72.168.144.181') BETWEEN start AND end;
+--------+---------------+------------+------------+
| id | country | area | city |
+--------+---------------+------------+------------+
| 806584 | United States | California | Littlerock |
+--------+---------------+------------+------------+
1 row in set (3.49 sec)
mysql> SELECT t.id, country, area, city FROM
-> ( SELECT g.*
-> FROM ip_lookup AS g
-> WHERE g.start <= INET6_ATON('72.168.144.181')
-> ORDER BY g.start DESC, g.end DESC
-> LIMIT 1
-> ) AS t
-> WHERE t.end >= INET6_ATON('72.168.144.181');
+--------+---------------+------------+------------+
| id | country | area | city |
+--------+---------------+------------+------------+
| 806584 | United States | California | Littlerock |
+--------+---------------+------------+------------+
1 row in set (0.07 sec)