Binary package “iptables-optimizer” in ubuntu xenial

sort iptables rules by packet counters

 iptables-optimizer is a shell and Python based tool for sorting
 iptables rules by packet/byte counters according to the
 administrators policy, ip6tables-optimizer works similar just
 for ip6tables chains.