Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-22743

Windows 10 MSI installer : port in use is not determined

    XMLWordPrintable

Details

    Description

      Turns out, that it is possible for a process other than mysqld to bind socket on mysqld, on IPv4, while the server binds on dual-stack IPv6. This was found by accident, testing the MSI installer, which has the ability to check for a free port (it would reject the port in GUI, when the port is already used ) .

      Looks like the logic for checking for free port needs to be taken from server.

      This points to be possibility of the port hijacking on Windows 10, even without SO_REUSEADDR. Perhaps we need to use to SO_EXCLUSIVEADDRUSE on the listening socket in the future, alas this can come with some surprises according to documentation, and a possible delays and/or failures at restart , due to "time wait delays"

      Also interesting to note, that current logic has worked in the past. Something in TCP stack has changed in Windows 10, relatively recently.

      Attachments

        Issue Links

          Activity

            People

              wlad Vladislav Vaintroub
              wlad Vladislav Vaintroub
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.