History

openvswitch: Add timeout support to ct action

Add support for fine-grain timeout support to conntrack action. The new OVS_CT_ATTR_TIMEOUT attribute of the conntrack action specifies a timeout to be associated with this connection. If no timeout is specified, it acts as is, that is the default timeout for the connection will be automatically applied. Example usage: $ nfct timeout add timeout_1 inet tcp syn_sent 100 established 200 $ ovs-ofctl add-flow br0 in_port=1,ip,tcp,action=ct(commit,timeout=timeout_1)

Yi-Hung Wei committed 7 years ago

Commit 06bd2bd1 parent 717700d2 files · +32 −1Browse files

Showing the changes to include/uapi/linux (1 of 2 files). Show all

Unified · Split

include/uapi/linux/openvswitch.h+3−0
@@ -734,6 +734,7 @@ struct ovs_action_hash { · 733 unmodified lines
734734 * be received on NFNLGRP_CONNTRACK_NEW and NFNLGRP_CONNTRACK_DESTROY groups,
735735 * respectively. Remaining bits control the changes for which an event is
736736 * delivered on the NFNLGRP_CONNTRACK_UPDATE group.
737+ * @OVS_CT_ATTR_TIMEOUT: Variable length string defining conntrack timeout.
737738 */
738739 enum ovs_ct_attr {
739740 OVS_CT_ATTR_UNSPEC,
@@ -746,6 +747,8 @@ enum ovs_ct_attr { · 6 unmodified lines
746747 OVS_CT_ATTR_NAT, /* Nested OVS_NAT_ATTR_* */
747748 OVS_CT_ATTR_FORCE_COMMIT, /* No argument */
748749 OVS_CT_ATTR_EVENTMASK, /* u32 mask of IPCT_* events. */
750+ OVS_CT_ATTR_TIMEOUT, /* Associate timeout with this connection for
751+ * fine-grain timeout tuning. */
749752 __OVS_CT_ATTR_MAX
750753 };
751754