Commit 5f51cd4d authored by Saied Kazemi's avatar Saied Kazemi Committed by Pavel Emelyanov

netfilter: add -n to iptables and ip6tables calls

To preload netfilter modules, criu runs "iptables -L" and "ip6tables -L"
before starting to dump or restore a process tree.

On systems with many entries, the above commands without the -n option
take a long time because of lengthy DNS lookups.
Signed-off-by: 's avatarSaied Kazemi <saied@google.com>
Acked-by: 's avatarTycho Andersen <tycho.andersen@canonical.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
parent ef4dbebe
......@@ -39,9 +39,9 @@ void preload_netfilter_modules(void)
pr_perror("failed to open /dev/null, using log fd for net module preload");
}
cr_system(fd, fd, fd, iptable_cmd_ipv4,
(char *[]) { iptable_cmd_ipv4, "-L", NULL}, 0);
(char *[]) { iptable_cmd_ipv4, "-L", "-n", NULL}, 0);
cr_system(fd, fd, fd, iptable_cmd_ipv6,
(char *[]) { iptable_cmd_ipv6, "-L", NULL}, 0);
(char *[]) { iptable_cmd_ipv6, "-L", "-n", NULL}, 0);
close_safe(&fd);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment