#==============================================================================
# Set IP address defaults with respect to IPV6 support
#
# This file determines the level of support for IPV4, IPV4 mapped or IPV6, then
# sets the appropriate localhost IP format to use for'connect()' commands.
#
# Input: $my_socket_debug - Print results of IP version check (optional)
# Output: $my_localhost - Default localhost IP
#==============================================================================
let $check_ipv6_just_check= 1;
#--source include/check_ipv6.inc
#==============================================================================
# Determine if IPV6 supported
#
# Parameters:
# $check_ipv6_just_check - Don't skip the test if IPv6 is unsupported,
# just set the variable $check_ipv6_supported
#==============================================================================
--disable_query_log
--disable_result_log
--disable_connect_log
--disable_abort_on_error
let $check_ipv6_supported= 1;
connect (checkcon123456789,::1,root,,test);
if($mysql_errno)
{
let $check_ipv6_supported=0; if(!$check_ipv6_just_check)
{
skip No IPv6 support;
}
}
#==============================================================================
#
# Determine if IPV4 mapped to IPV6 supported
#
let $check_ipv4_mapped_just_check= 1;
#--source include/check_ipv4_mapped.inc
#==============================================================================
# Check if ipv4 mapped to ipv6 is available.
#
# Parameters:
# $check_ipv4_mapped_just_check - Don't skip the test if IPv4 mapped is unsupported,
# just set the variable $check_ipv4_mapped_supported
#==============================================================================
--disable_query_log
--disable_result_log
--disable_connect_log
--disable_abort_on_error
#==============================================================================
# Set the localhost IP default to use when establishing connections
#
#==============================================================================
let $my_localhost=127.0.0.1;
if($check_ipv6_supported)
{
let $my_localhost=::1;
}
if($check_ipv4_mapped_supported)
{
let $my_localhost=::ffff:127.0.0.1;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.