A flow table multi-leveling method, comprising: generating a second flow table, separating a target logic rule in a first flow table as well as forwarding actions corresponding to the target logic rule to the second flow table, to make the first flow table and the second flow table orthogonal to form a ternary content addressable memory (TCAM) flow table; wherein the first flow table comprises a plurality of logic rules as well as all forwarding actions corresponding to the plurality of logic rules respectively; continuously generating new flow tables in a same manner of generating the second flow table, until a number of flow tables reaches a preset upper limit, wherein, logic rules in the first flow table and the second flow table comprise one or more match fields, and each match field corresponds to one or more forwarding actions; the step of separating the target logic rule in the first flow table as well as forwarding actions corresponding to the target logic rule to the second flow table comprises: calculating mapping gains of all logic rules in the first flow table, and determining a logic rule with a maximum mapping gain as the target logic rule; wherein calculating the mapping gains comprises calculating repetition degrees of the matching fields, and the maximum mapping gain indicates the highest repetition degree of the matching fields; separating the target logic rule in the first flow table as well as all forwarding actions corresponding to the target logic rule to the second flow table; wherein, a same match field of the target logic rule is not repeatedly saved in the second flow table. generating a second flow table, separating a target logic rule in a first flow table as well as forwarding actions corresponding to the target logic rule to the second flow table, to make the first flow table and the second flow table orthogonal to form a ternary content addressable memory (TCAM) flow table; wherein the first flow table comprises a plurality of logic rules as well as all forwarding actions corresponding to the plurality of logic rules respectively; continuously generating new flow tables in a same manner of generating the second flow table, until a number of flow tables reaches a preset upper limit, wherein, logic rules in the first flow table and the second flow table comprise one or more match fields, and each match field corresponds to one or more forwarding actions; the step of separating the target logic rule in the first flow table as well as forwarding actions corresponding to the target logic rule to the second flow table comprises: calculating mapping gains of all logic rules in the first flow table, and determining a logic rule with a maximum mapping gain as the target logic rule; wherein calculating the mapping gains comprises calculating repetition degrees of the matching fields, and the maximum mapping gain indicates the highest repetition degree of the matching fields; separating the target logic rule in the first flow table as well as all forwarding actions corresponding to the target logic rule to the second flow table; wherein, a same match field of the target logic rule is not repeatedly saved in the second flow table. calculating mapping gains of all logic rules in the first flow table, and determining a logic rule with a maximum mapping gain as the target logic rule; wherein calculating the mapping gains comprises calculating repetition degrees of the matching fields, and the maximum mapping gain indicates the highest repetition degree of the matching fields; separating the target logic rule in the first flow table as well as all forwarding actions corresponding to the target logic rule to the second flow table; wherein, a same match field of the target logic rule is not repeatedly saved in the second flow table.