[ 
https://issues.apache.org/jira/browse/HDDS-15772?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18095771#comment-18095771
 ] 

Chia-Chuan Ho commented on HDDS-15772:
--------------------------------------

Hi [~smeng], I found another IPv6 blocker not mentioned in the description.
In ozone-functions.sh, ozone_os_tricks exits on Linux when 
net.ipv6.bindv6only=1, unless the undocumented developer hook 
OZONE_ALLOW_IPV6=yes is set:

{code:java}
if [[ "${bindv6only}" -eq "1" ]] &&
    [[ "${OZONE_ALLOW_IPV6}" != "yes" ]]; then
   ...
   exit 1
 fi
{code}

Therefore, removing the default -Djava.net.preferIPv4Stack=true from OZONE_OPTS 
and Surefire alone would still not allow Ozone to start normally on some 
IPv6-only hosts.

Could you clarify the intended scope?
1. Should this Jira also remove the net.ipv6.bindv6only / OZONE_ALLOW_IPV6 
startup guard?
2. For Surefire, is the preferred change to remove the java.net.preferIPv4Stack 
system property entirely and rely on the JVM default, while still allowing an 
explicit -Djava.net.preferIPv4Stack=true when needed?
3. Should this Jira only remove the global IPv4/IPv6 blockers, with 
service-specific IPv6 issues discovered by tests?

Thanks!

> Stop forcing java.net.preferIPv4Stack=true for Ozone daemons and tests
> ----------------------------------------------------------------------
>
>                 Key: HDDS-15772
>                 URL: https://issues.apache.org/jira/browse/HDDS-15772
>             Project: Apache Ozone
>          Issue Type: Task
>            Reporter: Siyao Meng
>            Priority: Major
>
> Ozone starts every daemon with IPv4-only networking and runs all tests the 
> same way, so an IPv6-only host cannot start Ozone at all and no test ever 
> exercises IPv6.
> - hadoop-ozone/dist/src/shell/ozone/ozone-functions.sh:639 sets OZONE_OPTS to 
> default "-Djava.net.preferIPv4Stack=true".
> - pom.xml:2385 sets <java.net.preferIPv4Stack>true</java.net.preferIPv4Stack> 
> for Surefire.
> - hadoop-hdds/common/src/main/conf/ozone-env.sh:89-91 documents "We do not 
> support IPv6 yet/still".
> Proposed:
> - Make the JVM stack preference configurable rather than hardcoded, and 
> default to dual-stack (do not force preferIPv4Stack).
> - Remove the forced IPv4 stack from the Surefire configuration, or gate it so 
> IPv6 test profiles can override it.
> - Update the ozone-env.sh comment once support lands.
> This is a prerequisite for any other IPv6 work to be testable or deployable.
> Parent epic: HDDS-15763.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to