Use IPv6 for created listeners
When listeners are created, use the default values of [::]:3306.
This commit is contained in:
@ -461,7 +461,7 @@ bool runtime_create_listener(SERVICE *service, const char *name, const char *add
|
|||||||
|
|
||||||
if (addr == NULL || strcasecmp(addr, "default") == 0)
|
if (addr == NULL || strcasecmp(addr, "default") == 0)
|
||||||
{
|
{
|
||||||
addr = "0.0.0.0";
|
addr = "::";
|
||||||
}
|
}
|
||||||
if (port == NULL || strcasecmp(port, "default") == 0)
|
if (port == NULL || strcasecmp(port, "default") == 0)
|
||||||
{
|
{
|
||||||
@ -508,7 +508,7 @@ bool runtime_create_listener(SERVICE *service, const char *name, const char *add
|
|||||||
|
|
||||||
if (rval)
|
if (rval)
|
||||||
{
|
{
|
||||||
const char *print_addr = addr ? addr : "0.0.0.0";
|
const char *print_addr = addr ? addr : "::";
|
||||||
SERV_LISTENER *listener = serviceCreateListener(service, name, proto, addr,
|
SERV_LISTENER *listener = serviceCreateListener(service, name, proto, addr,
|
||||||
u_port, auth, auth_opt, ssl);
|
u_port, auth, auth_opt, ssl);
|
||||||
|
|
||||||
|
|||||||
@ -125,7 +125,7 @@ bool runtime_alter_monitor(MXS_MONITOR *monitor, char *key, char *value);
|
|||||||
*
|
*
|
||||||
* @param service Service where the listener is added
|
* @param service Service where the listener is added
|
||||||
* @param name Name of the listener
|
* @param name Name of the listener
|
||||||
* @param addr Listening address, NULL for default of 0.0.0.0
|
* @param addr Listening address, NULL for default of ::
|
||||||
* @param port Listening port, NULL for default of 3306
|
* @param port Listening port, NULL for default of 3306
|
||||||
* @param proto Listener protocol, NULL for default of "MySQLClient"
|
* @param proto Listener protocol, NULL for default of "MySQLClient"
|
||||||
* @param auth Listener authenticator, NULL for protocol default authenticator
|
* @param auth Listener authenticator, NULL for protocol default authenticator
|
||||||
|
|||||||
@ -630,8 +630,8 @@ static int mysql_auth_load_users(SERV_LISTENER *port)
|
|||||||
|
|
||||||
if (loaded < 0)
|
if (loaded < 0)
|
||||||
{
|
{
|
||||||
MXS_ERROR("[%s] Unable to load users for listener %s listening at %s:%d.", service->name,
|
MXS_ERROR("[%s] Unable to load users for listener %s listening at [%s]:%d.", service->name,
|
||||||
port->name, port->address ? port->address : "0.0.0.0", port->port);
|
port->name, port->address ? port->address : "::", port->port);
|
||||||
|
|
||||||
if (instance->inject_service_user)
|
if (instance->inject_service_user)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -1071,7 +1071,7 @@ struct subcommand createoptions[] =
|
|||||||
"Create a new server from the following parameters.\n\n"
|
"Create a new server from the following parameters.\n\n"
|
||||||
"SERVICE Service where this listener is added\n"
|
"SERVICE Service where this listener is added\n"
|
||||||
"NAME Listener name\n"
|
"NAME Listener name\n"
|
||||||
"HOST Listener host address (default 0.0.0.0)\n"
|
"HOST Listener host address (default [::])\n"
|
||||||
"PORT Listener port (default 3306)\n"
|
"PORT Listener port (default 3306)\n"
|
||||||
"PROTOCOL Listener protocol (default MySQLClient)\n"
|
"PROTOCOL Listener protocol (default MySQLClient)\n"
|
||||||
"AUTHENTICATOR Authenticator module name (default MySQLAuth)\n"
|
"AUTHENTICATOR Authenticator module name (default MySQLAuth)\n"
|
||||||
|
|||||||
Reference in New Issue
Block a user