Skip to content

1.X version in AL2 Ipv 6 rules get deleted for secondary ENI #132

Description

@joeysk2012

When using multiple ENI with ipv6, the ipv6 rule gets deleted when using the code in the 1.x branch.
It seems likely this is being deleted by this code and
it would be possible to avoid this by using 2.x like is described here.

Customers are advised to switch to the latest 2.x version.
A workaround for this issue is to copy all of the ip6 rules to a separate table from 10000 + device number with 2000 + device number using a script and save it under /etc/dhcp/dhcpclient.d

PATTERN="/etc/sysconfig/network-scripts/route6-*"
shopt -s nullglob
files=( $PATTERN )

# Replace Table 10000 + device number with 20000 + device number, and turn it into a ip cmd
sed 's/table 1/table 2/g; s/^/ip -6 route replace /g' "${files[@]}" | while IFS= read -r cmd; do
    # Skip Empty Lines
    [[ -z "$cmd" ]] && continue
    eval "$cmd"
done

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions