A method for selecting a network device, comprising: receiving, by a second network device, a network device selection message sent by a first network device, wherein the network device selection message contains a virtual local area network, VLAN, mapping capability identifier of the first network device; selecting, by the second network device, from the first network device and the second network device, according to the VLAN mapping capability identifier and local VLAN mapping capability, a network device for executing VLAN mapping; wherein the network device selection message further contains a device identifier of the first network device; and accordingly, the second network device selects, according to the VLAN mapping capability identifier, the device identifier, the local VLAN mapping capability, and a local device identifier, the network device for executing VLAN mapping; wherein the selecting of the network device for executing VLAN mapping by the second network device, according to the VLAN mapping capability identifier, the device identifier, the local VLAN mapping capability, and the local device identifier, comprises: when the second network device determines, according to the VLAN mapping capability identifier and the local VLAN mapping capability, that both the second network device and the first network device have VLAN mapping capability, selecting, according to sizes or a sequence of the device identifier and the local device identifier, the network device for executing VLAN mapping. receiving, by a second network device, a network device selection message sent by a first network device, wherein the network device selection message contains a virtual local area network, VLAN, mapping capability identifier of the first network device; selecting, by the second network device, from the first network device and the second network device, according to the VLAN mapping capability identifier and local VLAN mapping capability, a network device for executing VLAN mapping; wherein the network device selection message further contains a device identifier of the first network device; and accordingly, the second network device selects, according to the VLAN mapping capability identifier, the device identifier, the local VLAN mapping capability, and a local device identifier, the network device for executing VLAN mapping; wherein the selecting of the network device for executing VLAN mapping by the second network device, according to the VLAN mapping capability identifier, the device identifier, the local VLAN mapping capability, and the local device identifier, comprises: when the second network device determines, according to the VLAN mapping capability identifier and the local VLAN mapping capability, that both the second network device and the first network device have VLAN mapping capability, selecting, according to sizes or a sequence of the device identifier and the local device identifier, the network device for executing VLAN mapping. when the second network device determines, according to the VLAN mapping capability identifier and the local VLAN mapping capability, that both the second network device and the first network device have VLAN mapping capability, selecting, according to sizes or a sequence of the device identifier and the local device identifier, the network device for executing VLAN mapping.