Closed lqmnhakeem217 closed 2 weeks ago
when i try to logging it require md5 auth but my db use scram-sha-256 auth
FDO Connection Status: The remote server returned an error: (559) MgFdoException.: An exception occurred in FDO component. Error occurred in Feature Source (Session:c78f2942-38e1-11ef-8000-a0294205948e_en_MTI3LjAuMC4x0AFC0AFB0AFA//fafbc1bf-6c0c-4fdd-8e23-ee9884b0687a.FeatureSource): An exception occurred in FDO component. RDBMS: authentication method 10 not supported
MgFdoConnectionManager.Open() line 333 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\common\manager\FdoConnectionManager.cpp
MgFdoConnectionManager.CacheFdoConnection() line 1097 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\common\manager\FdoConnectionManager.cpp
MgFdoConnectionManager.Open() line 1089 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\common\manager\FdoConnectionManager.cpp (Cause: , Root Cause: )
MgFeatureServiceHandler.ProcessOperation() line 83 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\services\feature\FeatureServiceHandler.cpp
MgOpTestFeatureSourceConnection.Execute() line 100 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\services\feature\OpTestFeatureSourceConnection.cpp
MgServerFeatureService.TestConnection() line 245 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\services\feature\ServerFeatureService.cpp
MgFdoConnectionManager.Open() line 366 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\common\manager\FdoConnectionManager.cpp
The remote server returned an error: (559) MgFdoException. This error generate when i try to add feature source, already tried different services, logins or passwords still not working. Even tried looking into it on the internet but no luck on finding solution to this
It could be that the libpq.dll
included with the MG/FDO install does not support this authentication type.
If you download a zip package of the latest postgresql 16 release and copy libpq.dll
and dependent dlls to the FDO directory (overwriting existing files). Does this then work?
For the record, this is the full set of dependent dlls you need to copy alongside libpq.dll
from the latest 16.3 binaries according to the Dependencies tool
Oh, I see. I thought I had already resolved the issue by following this guide: Error: Unable to load the FDO Provider library 'PostgreSQLProvider.dll' in Map 3D or Civil 3D 2020.
However, after your suggestion, I noticed some progress. But what does 'FDO Connection Status: False' mean? Does it indicate that my database username and password are incorrect? I am using superuser credentials, so it should work, right?
Not quite sure. MG connection status can obscure the underlying connection failure details.
A better test would be to try creating a PostgresSQL connection with FDO Toolbox with the updated libpq.dll
and see what happens there.
After using FDO Toolbox, I've been able to access the database smoothly. However, I'm unsure how to set this up with MapGuide Maestro. Could you provide some guidance on integrating FDO ToolBox with MapGuide Maestro?
Also, I encountered the following errors in the log files related to the 'FDO Connection Status: False' issue from my previous query:
System.Exception: The remote server returned an error: (559) MgConnectionFailedException.: Problem:\nCannot establish connection to the MapGuide Server.\n\nPossible Causes:\n-Your session has been idle for too long;\n-MapGuide Server is no longer responding;\n-Internet connection problems.\n\nSolution:\nRestart your application / session, restart the MapGuide Server service, or contact with the server administrator.
MgServerGetSpatialContexts.GetSpatialContexts()() line 92 file c:\working\build_area\mapguide\4.0.0\x64\mgdev\server\src\services\feature\ServerGetSpatialContexts.cpp
---> System.Net.WebException: The remote server returned an error: (559) MgConnectionFailedException.
at System.Net.HttpWebRequest.GetResponse()
at OSGeo.MapGuide.MaestroAPI.Http.DefaultHttpRequestor.Get(String uri, IHttpGetRequestOptions options, Nullable1 requestTimeout) in /_/OSGeo.MapGuide.MaestroAPI/Http/DefaultHttpRequestor.cs:line 144 --- End of inner exception stack trace --- at OSGeo.MapGuide.MaestroAPI.Http.DefaultHttpRequestor.Get(String uri, IHttpGetRequestOptions options, Nullable
1 requestTimeout) in //OSGeo.MapGuide.MaestroAPI/Http/DefaultHttpRequestor.cs:line 144
at OSGeo.MapGuide.MaestroAPI.HttpServerConnection.GetSpatialContextInfo(String resourceID, Boolean activeOnly) in //OSGeo.MapGuide.MaestroAPI/Http/HttpServerConnection.cs:line 1244
at Maestro.Editors.FeatureSource.CoordSys.CoordSysOverrideDialog..ctor(IEditorService ed) in C:\projects\mapguide-maestro\Maestro.Editors\FeatureSource\CoordSys\CoordSysOverrideDialog.cs:line 53
at Maestro.Editors.FeatureSource.CoordSysOverrideCtrl.btnAdd_Click(Object sender, EventArgs e) in C:\projects\mapguide-maestro\Maestro.Editors\FeatureSource\CoordSysOverrideCtrl.cs:line 61
at System.Windows.Forms.ToolStripButton.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, WM msg, IntPtr wparam, IntPtr lparam)
Updated:
I finally spun up a postgres16 docker image (using https://hub.docker.com/r/kartoza/postgis/) to test this and was able to connect from both MapGuide 4.0 Beta 1 and FDO Toolbox. I also verified this docker image uses scram-sha-256
auth.
So from this I can only assume your issue was this particular step:
- Backup MapGuide/FDO files and Copy/paste FDOToolBox/FDO files to the MapGuide/FDO files to check if it works (It does not worked)
You did not need to copy all the FDO files from FDO Toolbox, you only needed to copy in an updated libpq.dll
and its dependencies from a postgres16 windows binaries zip file. For ease of reference, this is the full dll list you need to copy from the postgres16 windows binaries.
libcrypto-3-x64.dll
libiconv-2.dll
libintl-9.dll
libpq.dll
libssl-3-x64.dll
libwinpthread-1.dll
i been trying to connect my database server which are using postgres 16 to mapguide maestro which i have installed the latest version, but there seem to be an issue with fdo not matching latest version. is there a way to make a custom connection extension that can cater fdo connecting to pg16