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 1899757

Summary: aws-vpc-move-ip: Routes get deleted from route table after IP address is assigned [RHEL 8.1.z]
Product: Red Hat Enterprise Linux 8 Reporter: Reid Wahl <nwahl>
Component: resource-agentsAssignee: Oyvind Albrigtsen <oalbrigt>
Status: CLOSED DUPLICATE QA Contact: Brandon Perkins <bperkins>
Severity: high Docs Contact:
Priority: high    
Version: 8.1CC: agk, bperkins, cfeist, cluster-maint, cluster-qe, fdinitto, oalbrigt, sbradley, toneata
Target Milestone: rcKeywords: Regression, Triaged
Target Release: 8.1Flags: pm-rhel: mirror+
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1899756 Environment:
Last Closed: 2020-12-08 14:38:48 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:
Bug Depends On: 1899756, 1905551    
Bug Blocks:    

Description Reid Wahl 2020-11-19 22:49:53 UTC
+++ This bug was initially created as a clone of Bug #1899756 +++

Description of problem:

The 8.1.z (BZ 1822251) and 8.2.z (BZ 1822250) versions of the aws-vpc-move-ip resource agent delete routes (as part of ec2ip_get_and_configure()) **after** assigning the IP address to the interface. They're supposed to delete routes (as part of ec2ip_drop()) **before** assigning the IP address to the interface.

I have no idea how or why this is the case. The upstream history of the resource agent shows that the `ip route` commands have always been part of the ec2ip_drop() function since they were added:
  - https://github.com/ClusterLabs/resource-agents/commit/390d1cb8

Furthermore, resource-agents-4.1.1-68.el8 (RHEL 8.3) contains the `ip route` calls in the correct location. (See BZ 1819021).


These are the lines:

        # delete remaining route-entries if any
        ip route show to exact ${OCF_RESKEY_ip}/32 dev $OCF_RESKEY_interface | xargs -r ip route delete
        ip route show table local to exact ${OCF_RESKEY_ip}/32 dev $OCF_RESKEY_interface | xargs -r ip route delete

They're at the end of ec2ip_get_and_configure() when they should be (and are upstream) at the end of ec2ip_drop().

-----

Version-Release number of selected component (if applicable):

resource-agents-4.1.1-33.el8_1.4

-----

How reproducible:

Always

-----

Steps to Reproduce:
1. Create and start an aws-vpc-move-ip resource.
2. Run `ip route show table all`.

-----

Actual results:

There is no local route to the managed IP address after the start operation.

-----

Expected results:

There is a local route to the managed IP address after the start operation. For example:

$ ip route show table all | grep '10\.29\.255\.'
local 10.29.255.250 dev eth0 table local proto kernel scope host src 10.29.255.250 

-----

Additional info:

I'm flagging this as a regression, because until those lines were added to the end of ec2ip_get_and_configure(), one must assume the routes were present at the end of the start operation.

-----

Potential workaround:

Configure an IPsrcaddr resource with proto=kernel table=local.

--- Additional comment from RHEL Program Management on 2020-11-19 22:47:34 UTC ---

pm_ack is no longer used for this product. The flag has been reset.

See https://issues.redhat.com/browse/PTT-1821 for additional details.

Comment 2 Reid Wahl 2020-11-20 01:10:26 UTC
(In reply to Reid Wahl from comment #0)
> Potential workaround:
> 
> Configure an IPsrcaddr resource with proto=kernel table=local.

This actually is not a valid workaround on RHEL 8.1. The RHEL 8.1 version of the IPsrcaddr resource agent lacks the destination, proto, and table attributes. So as far as I can tell, the only workaround is to copy a newer version of IPsrcaddr to /usr/lib/ocf/resource.d/custom/IPsrcaddr and create an ocf:custom:IPsrcaddr resource.

Comment 3 Reid Wahl 2020-11-20 18:34:52 UTC
Making BZ public to try to avoid more duplicates (e.g., 1899930).

Comment 5 Chris Feist 2020-12-08 14:38:48 UTC

*** This bug has been marked as a duplicate of bug 1905552 ***