Recently got four Ali cloud servers, are student machine, proprietary network, respectively, under two accounts. Helpless, cheap things is inconvenient, in two accounts do not say, under the same account of the two servers are not under the same VPC, toss for two days, and finally make this four servers 22 intranet interoperability, midway encountered a lot of pits, in this record.
(as a result of the student machine outside the network speed is too slow, the transmission between the server through the Internet is really undesirable behavior, therefore must realize intranet interworking)
First two accounts are assumed to be AB
Under a, there are two vpcid, respectively, AV1 and AV2.
Under B There are two vpcid, respectively, BV1 and BV2.
First look at the official manual, different VPC can be used to achieve communication through high-speed channels.
1. The same account to achieve high speed Channel
(1) Create a router
(2) Create bidirectional interface
(3) Adding routes to the router configuration, respectively
Configuration of the network segment to fill in the IP network segment on the end of the line
On the next hop, select the interface ID of the currently selected router.
Ping a success, realize the AV1 and AV2 between the intranet interoperability (BV1 and BV2 the same)
2. Cross account to achieve high-speed channel (for example to achieve communication between AV1 and BV1) there are pits ...
(1) Create the AV1 of the initiator and the receiving end of the BV1
(2) Configure the End-to-end information in AV1 and BV1 respectively:
Account ID, router ID, and router interface ID
(3) The initiator of the AV1 initiates the connection
(4) Adding routes in the router configuration respectively, such as 1.
22 so the configuration is OK
If you're lucky, you've already got the job done, but I'm not the lucky one.
I found that the AV1 and BV1 connections were complete and the offset network segment could not be added in the routing configuration. The original two intranet IP just in the same network segment such as 192.168.1.25 and 192.168.1.26 produced a conflict. After some time of pondering. Found that the console has a switch option, you can achieve the intranet IP modification, so the following configuration.
1. To the need to modify the intranet vpc to create a switch, configure a network segment does not conflict.
2. Stop the instance under the VPC
3. Enter the ECS console click the ECS ID of the IP to be replaced
4. Select more-> in the configuration information to modify the private network ip-> Select the switch that you just created-> configure an IP
5. Remove the original switch.
6. Then enter the high-speed channel routing configuration will not conflict, because your original intranet IP and the original switch has ceased to exist.
Summary, although it is not easy to achieve the intranet interoperability, but these 22 configuration is really troublesome.
Ali: Who told you to bargain for the student machine, not to put you under a VPC, busy?