The invention discloses a method and device for rapidly configuring POTN services based on an
OpenFlow flow table, and relates to the technical field of POTN
service configuration. The method comprises the steps of: creating an
OpenFlow matching flow table; sending the
OpenFlow matching flow table to a switch by an SDN controller; when the switch receives a data packet, matching the port number of the data packet in a port matching table of the OpenFlow matching flow table, so that the service type corresponding to the data packet is obtained; according to the service type, performing
label matching in the corresponding
label matching table; and finally, according to the current
label state, matching the
processing action corresponding to the data packet in a
processing action matching table according to corresponding service requirements, and correspondingly encapsulating the data packet according to the matched
processing action. By means of the method and the device disclosed by the invention, rapid configuration of
Ethernet services, MPLS-TP services and ODUK services can be realized; the frequent bandwidth and path adjustment requirements can be satisfied; and thus, management, operation and maintenance of a network are simple and high-efficiency.