ovn_adoption: fix scp with IPv6 addresses in cluster-to-standalone#1410
ovn_adoption: fix scp with IPv6 addresses in cluster-to-standalone#1410rebtoor wants to merge 1 commit into
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Build failed (check pipeline). Post ✔️ noop SUCCESS in 0s |
|
|
||
| echo "Copying NB database to ansible controller..." | ||
| ${CONTROLLER1_SCP}:/tmp/ovn_standalone_conversion/ovnnb_db.db /tmp/ovn_adoption_dbs/ | ||
| ${CONTROLLER1_SCP} [${CONTROLLER1_HOST}]:/tmp/ovn_standalone_conversion/ovnnb_db.db /tmp/ovn_adoption_dbs/ |
There was a problem hiding this comment.
would need to make this conditional using[] for host when ipv6 enabled.
There was a problem hiding this comment.
actually, does it work it seems :D
The scp command constructed from the SSH command by replacing "ssh" with "scp" does not account for IPv6 addresses. When the controller host is an IPv6 address (e.g. 2620:cf:cf:aaaa::70), scp interprets the colons as the host:path separator, causing it to connect to a bogus IPv4 address derived from the first octet. Fix by splitting the SSH command into the scp options and the host, then wrapping the host in square brackets for the scp remote path. This is compatible with both IPv4 and IPv6 addresses since brackets around an IPv4 address are valid in scp. Update both the test role and the user-facing documentation. Co-authored-by: Cursor <cursoragent@cursor.com>
cdc9fea to
9cac77c
Compare
|
Build failed (check pipeline). Post ✔️ noop SUCCESS in 0s |
|
recheck |
|
Build failed (check pipeline). Post ✔️ noop SUCCESS in 0s |
klgill
left a comment
There was a problem hiding this comment.
The proc_migrating-ovn-data.adoc file lgtm.
|
This PR is stale because it has been for over 15 days with no activity. |
|
@karelyatin and @rebtoor do we need this change ? It is marked stale already |
|
The scp command constructed from the SSH command by replacing "ssh" with "scp" does not account for IPv6 addresses. When the controller host is an IPv6 address (e.g. 2620:cf:cf:aaaa::70), scp interprets the colons as the host:path separator, causing it to connect to a bogus IPv4 address derived from the first octet.
Fix by splitting the SSH command into the scp options and the host, then wrapping the host in square brackets for the scp remote path. This is compatible with both IPv4 and IPv6 addresses since brackets around an IPv4 address are valid in scp.
Update both the test role and the user-facing documentation.
Example of actual behavior: