Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
utils: suppress errors on missing legacy iptables
When the legacy iptables backend is not installed, iptables-legacy-save and ip6tables-legacy-save binary files are missing. This results in the following error messages: (00.062021) iptables has nft backend: iptables-save v1.8.8 (nf_tables) Error (criu/util.c:626): execvp("iptables-legacy-save", ...) failed: No such file or directory (00.062793) Error (criu/util.c:641): exited, status=1 (00.062800) Error (criu/util.c:1566): iptables-legacy-save -V failed (00.069758) iptables has nft backend: ip6tables-save v1.8.8 (nf_tables) Error (criu/util.c:626): execvp("ip6tables-legacy-save", ...) failed: No such file or directory (00.070615) Error (criu/util.c:641): exited, status=1 (00.070624) Error (criu/util.c:1566): ip6tables-legacy-save -V failed (00.070632) skipping iptables dump - no legacy version present (00.070635) skipping ip6tables dump - no legacy version present The error messages "No such file or directory" can be be ignored. This patch avoids printing out the unnecessary and confusing error messages. Instead only the following messages will be included in the logs: (00.048281) iptables has nft backend: iptables-save v1.8.7 (nf_tables) (00.048905) iptables-legacy-save -V failed (00.050044) iptables has nft backend: ip6tables-save v1.8.7 (nf_tables) (00.050661) ip6tables-legacy-save -V failed (00.050677) skipping iptables dump - no legacy version present (00.050680) skipping ip6tables dump - no legacy version present Signed-off-by: Radostin Stoyanov <rstoyanov@fedoraproject.org>
- Loading branch information