[Bug 47083] New: MySQL 8.0.x community installer (.NET 4.5.x app) fails to configure mysql, needs support for WS_AF_INET6 in ' iphlpapi.GetExtendedTcpTable'

wine-bugs at winehq.org wine-bugs at winehq.org
Sat Apr 27 05:25:07 CDT 2019


https://bugs.winehq.org/show_bug.cgi?id=47083

            Bug ID: 47083
           Summary: MySQL 8.0.x community installer (.NET 4.5.x app) fails
                    to configure mysql, needs support for WS_AF_INET6 in
                    'iphlpapi.GetExtendedTcpTable'
           Product: Wine
           Version: 4.7
          Hardware: x86-64
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: iphlpapi
          Assignee: wine-bugs at winehq.org
          Reporter: focht at gmx.net
      Distribution: ---

Hello folks,

as it says. Happens during installation/configuration of mysql server but
doesn't seem to be fatal.

Prerequisite: 'winetricks -q dotnet452' (or Wine-Mono).

Download:
https://dev.mysql.com/get/Downloads/MySQLInstaller/mysql-installer-community-8.0.16.0.msi

Internet Archive snapshot:
https://web.archive.org/web/20190427100352/https://cdn.mysql.com//Downloads/MySQLInstaller/mysql-installer-community-8.0.16.0.msi

Managed backtrace (copied from error dialog):

--- snip ---
System.Net.NetworkInformation.NetworkInformationException (0x80004005): Request
not supported
   at
System.Net.NetworkInformation.SystemIPGlobalProperties.GetAllTcpConnections()
   at
System.Net.NetworkInformation.SystemIPGlobalProperties.GetActiveTcpListeners()
   at
MySql.Installer.Plugins.Server.ServerConfigLocalMachinePage.ValidatePortInUse(UInt32
port, UInt32 oldPort)
   at
MySql.Installer.Plugins.Server.ServerConfigLocalMachinePage.portNumberEdit_TextChanged(Object
sender, EventArgs e)
   at MySql.Installer.Plugins.Server.ServerConfigLocalMachinePage.Activate()
   at MySql.Installer.Wizards.Wizard.ActivatePage()
   at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button,
Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ButtonBase.WndProc(Message& m)
   at System.Windows.Forms.Button.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr
wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 4.0.0.0
    Win32 Version: 4.0.30319.34209 built by: FX452RTMGDR
    CodeBase:
file:///C:/windows/Microsoft.NET/Framework64/v4.0.30319/mscorlib.dll
----------------------------------------
MySQLInstaller
    Assembly Version: 1.4.29.0
    Win32 Version: 1.4.29.0
    CodeBase:
file:///C:/Program%20Files%20(x86)/MySQL/MySQL%20Installer%20for%20Windows/MySQLInstaller.exe
----------------------------------------
...
MySQLInstaller.Core
    Assembly Version: 1.4.29.0
    Win32 Version: 1.4.29.0
    CodeBase:
file:///C:/Program%20Files%20(x86)/MySQL/MySQL%20Installer%20for%20Windows/MySQLInstaller.Core.DLL
----------------------------------------
...
MySQL.Utility
    Assembly Version: 8.2.3.0
    Win32 Version: 8.2.3
    CodeBase:
file:///C:/Program%20Files%20(x86)/MySQL/MySQL%20Installer%20for%20Windows/MySQL.Utility.DLL
...
----------------------------------------
StandardPlugins
    Assembly Version: 1.4.29.0
    Win32 Version: 1.4.29.0
    CodeBase:
file:///C:/Program%20Files%20(x86)/MySQL/MySQL%20Installer%20for%20Windows/StandardPlugins.DLL
----------------------------------------
MySql.Data
    Assembly Version: 8.0.13.0
    Win32 Version: 8.0.13.0
    CodeBase:
file:///C:/Program%20Files%20(x86)/MySQL/MySQL%20Installer%20for%20Windows/MySql.Data.DLL
----------------------------------------
--- snip ---

Microsoft .NET Reference source:

https://github.com/Microsoft/referencesource/blob/4.6.2/System/net/System/Net/NetworkInformation/SystemIPGlobalProperties.cs#L149

--- snip ---
...
            if (Socket.OSSupportsIPv6) {

                // IPv6 tcp connections
                // Get the size of buffer needed
                size = 0;
                result =
UnsafeNetInfoNativeMethods.GetExtendedTcpTable(SafeLocalFree.Zero, ref size,
true,
                                                                       
(uint)AddressFamily.InterNetworkV6,
                                                                       
TcpTableClass.TcpTableOwnerPidAll, 0);

                while (result == IpHelperErrors.ErrorInsufficientBuffer) {
try {
...
                    }
                    finally {
                        if (buffer != null)
                            buffer.Close();
                    }
                }

                // If we don't have any ipv6 interfaces detected, just continue
                if (result != IpHelperErrors.Success && result !=
IpHelperErrors.ErrorNoData) {
                    throw new NetworkInformationException((int)result);
                }
}
...
--- snip ---

Microsoft CoreFX implementation (Windows platform) is pretty much the same :

https://github.com/dotnet/corefx/blob/8c5260061b11323dfd97fbab614d54402405513f/src/System.Net.NetworkInformation/src/System/Net/NetworkInformation/SystemIPGlobalProperties.cs#L115

Microsoft docs:

https://docs.microsoft.com/en-us/windows/desktop/api/iphlpapi/nf-iphlpapi-getextendedtcptable

Wine source:

https://source.winehq.org/git/wine.git/blob/f0db9c4b3be1f44289d2f7e26d4fa3548edf6d27:/dlls/iphlpapi/iphlpapi_main.c#l2380

--- snip ---
2380 /******************************************************************
2381  *    GetExtendedTcpTable (IPHLPAPI.@)
2382  */
2383 DWORD WINAPI GetExtendedTcpTable(PVOID pTcpTable, PDWORD pdwSize, BOOL
bOrder,
2384                                  ULONG ulAf, TCP_TABLE_CLASS TableClass,
ULONG Reserved)
2385 {
2386     DWORD ret, size;
2387     void *table;
2388 
2389     TRACE("pTcpTable %p, pdwSize %p, bOrder %d, ulAf %u, TableClass %u,
Reserved %u\n",
2390            pTcpTable, pdwSize, bOrder, ulAf, TableClass, Reserved);
2391 
2392     if (!pdwSize) return ERROR_INVALID_PARAMETER;
2393 
2394     if (ulAf != WS_AF_INET)
2395     {
2396         FIXME("ulAf = %u not supported\n", ulAf);
2397         return ERROR_NOT_SUPPORTED;
2398     }
2399     if (TableClass >= TCP_TABLE_OWNER_MODULE_LISTENER)
2400         FIXME("module classes not fully supported\n");
2401 
2402     if ((ret = build_tcp_table(TableClass, &table, bOrder,
GetProcessHeap(), 0, &size)))
2403         return ret;
2404 
2405     if (!pTcpTable || *pdwSize < size)
2406     {
2407         *pdwSize = size;
2408         ret = ERROR_INSUFFICIENT_BUFFER;
2409     }
2410     else
2411     {
2412         *pdwSize = size;
2413         memcpy(pTcpTable, table, size);
2414     }
2415     HeapFree(GetProcessHeap(), 0, table);
2416     return ret;
2417 }
--- snip ---

$ sha1sum mysql-installer-community-8.0.16.0.msi 
430bdbfa5c1b1bdccfb7cdb3e0b85d1e71696294 
mysql-installer-community-8.0.16.0.msi

$ du -sh mysql-installer-community-8.0.16.0.msi 
374M    mysql-installer-community-8.0.16.0.msi

$ wine --version
wine-4.7

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.


More information about the wine-bugs mailing list