摘要 |
The present invention discloses a packet transmission method and apparatus, and a server, and belongs to the field of Internet technologies. The method includes: receiving at least one first IPv4 packet sent by at least one user equipment, where each first IPv4 packet carries an IPv4 address and a source port that are allocated to each user equipment; determining, according to a correspondence between a source port of an IPv4 packet and an output port of an IPv6 packet, an output port corresponding to the source port of each first IPv4 packet; updating the source port of each first IPv4 packet with the corresponding output port; converting, according to a set algorithm, the IPv4 address carried in each first IPv4 packet into a same target global unicast IPv6 address, to obtain a first IPv6 packet corresponding to each first IPv4 packet; and transmitting, to an IPv6 network, each first IPv6 packet by using the output port of each first IPv6 packet. According to the present invention, IPv4 addresses carried in received first IPv4 packets are converted into a same target IPv6 address, thereby reducing resource consumption during packet transmission, and improving packet transmission efficiency. |