diff options
author | Sergey Vojtovich <svoj@mariadb.org> | 2017-03-07 15:06:01 +0400 |
---|---|---|
committer | Sergey Vojtovich <svoj@mariadb.org> | 2017-03-07 22:28:33 +0400 |
commit | 19629ebf813ef7825eb86a46045ebccdfd484d9a (patch) | |
tree | 88f7563b47bf8dfcf9666e27b17ddb25f448d6b7 /sql | |
parent | fa137476ff14a42c25f221585066d36124755f0a (diff) | |
download | mariadb-git-19629ebf813ef7825eb86a46045ebccdfd484d9a.tar.gz |
MDEV-10646 - System Unit File After network-online
Bind to an address even if it is not yet configured.
Diffstat (limited to 'sql')
-rw-r--r-- | sql/mysqld.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sql/mysqld.cc b/sql/mysqld.cc index 90607882aa4..2607307ceee 100644 --- a/sql/mysqld.cc +++ b/sql/mysqld.cc @@ -2520,6 +2520,12 @@ static MYSQL_SOCKET activate_tcp_port(uint port) (char*)&arg, sizeof(arg)); } #endif + +#ifdef IP_FREEBIND + arg= 1; + (void) mysql_socket_setsockopt(ip_sock, IPPROTO_IP, IP_FREEBIND, (char*) &arg, + sizeof(arg)); +#endif /* Sometimes the port is not released fast enough when stopping and restarting the server. This happens quite often with the test suite |