Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 2236501

Summary: Cannot run iptables-restore with iptables 1.8.5-8
Product: Red Hat Enterprise Linux 8 Reporter: bartosz.bezak
Component: iptablesAssignee: Phil Sutter <psutter>
Status: CLOSED ERRATA QA Contact: Tomas Dolezal <todoleza>
Severity: high Docs Contact:
Priority: unspecified    
Version: CentOS StreamCC: bstinson, jpeska, jwboyer, noonedeadpunk, psutter, qe-baseos-daemons, shdunne, todoleza, ykulkarn
Target Milestone: rcKeywords: Triaged
Target Release: 8.9Flags: pm-rhel: mirror+
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: iptables-1.8.5-10.el8_9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-11-14 15:51:50 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description bartosz.bezak 2023-08-31 13:16:13 UTC
Description of problem:
Cannot run iptables-restore with iptables 1.8.5-8

Version-Release number of selected component (if applicable):
iptables-1.8.5-8.el8.x86_64

How reproducible:
all the time

Steps to Reproduce:
1. Run as root:
iptables-restore <<EOF
*filter
:INPUT - [0:0]
COMMIT
EOF

Actual results:
iptables-restore: line 3 failed

Expected results:
added rule

Additional info:
https://www.mail-archive.com/ubuntu-bugs@lists.ubuntu.com/msg5852087.html

looks like this was not backported:
https://git.netfilter.org/iptables/commit/?id=0bd7a8eaf3582159490ab355b1217a4e42ed021f

here:
https://gitlab.com/redhat/centos-stream/rpms/iptables/-/tree/c8s

Comment 1 bartosz.bezak 2023-08-31 13:36:08 UTC
noticed in openstack CI:
https://paste.opendev.org/show/bChNEGSL52bI3R7At4b1/

Comment 2 Phil Sutter 2023-09-01 17:29:40 UTC
Thanks for the report. We're in exception phase already, how urgently do you need this fixed?

Comment 3 Phil Sutter 2023-09-01 17:42:35 UTC
Ah, for a workaround, specify the desired chain policy (i.e., "ACCEPT" or
"DROP") instead of "-". What is the purpose of explicitly specifying base
chains as ':<NAME> - [0:0]' in a flushing restore call, BTW? From my
perspective, it should be a noop, no?

Comment 4 bartosz.bezak 2023-09-04 12:26:30 UTC
Thank you Phil for picking this one up quickly.

We've already pinning iptables to 1.8.4 in our project container build pipeline - in Centos Stream 8 - https://review.opendev.org/c/openstack/kolla/+/893364
so it is not urgent for us. However this looks like a obvious bugfix backport omission, so probably easy fix, and it can be disruptive for users - as you can see in Additional info section - it was fixed almost 3 years ago upstream.

Comment 5 Phil Sutter 2023-09-06 11:05:23 UTC
Hereby requesting exception+ for this regression introduced by the package rebase.

Comment 8 Phil Sutter 2023-09-06 13:51:04 UTC
Jiri, please provide qa_ack+ and perform pre-verification based on either above
scratch build or the c8s MR created for this ticket:
https://gitlab.com/redhat/centos-stream/rpms/iptables/-/merge_requests/47

Thanks!

Comment 10 Phil Sutter 2023-09-07 11:57:37 UTC
Setting Verified:Tested given the scratch build passes CI (and the added test shows up in test logs).

Comment 12 bartosz.bezak 2023-09-08 09:45:08 UTC
tested rpms from https://kojihub.stream.centos.org/koji/buildinfo?buildID=37005, looks good:

dnf install iptables-1.8.5-9.el8.x86_64.rpm iptables-libs-1.8.5-9.el8.x86_64.rpm

iptables-restore <<EOF
> *filter
> :INPUT - [0:0]
> COMMIT
> EOF

echo $?
0

Comment 15 Takashi Kajinami 2023-09-13 05:56:16 UTC
This is now affecting Puppet OpenStack project CI, and is blocking some backport work needed for RHOSP17.1.
I'm wondering if we can get the fixed version released early in CentOS Stream 8 to unblock that, instead of
implementing a tricky workaround to pin and downgrade iptables in multiple CI.

Comment 16 Phil Sutter 2023-09-13 14:33:24 UTC
This ticket has been approved for exception handling and therefore could still be added to the RHEL8.9 y-stream errata. Since you picked up the rebase pre-GA, I assume you're consuming nightly builds, so you should see the fixed package soon.

Comment 23 errata-xmlrpc 2023-11-14 15:51:50 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (iptables bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2023:7184