Connection tests between Informix in Docker and C#
-
Download informix docker image from here and follow the instructions.
-
Go to /opt/ibm/informix/sqlhosts, check the name in drsoctcp protocol and edit the hostname with 0.0.0.0.
Like the following image:
-
Edit in /opt/ibm/informix/onconfig DBSERVERALIASES key with step 2 value (informix_dr).
Example:
-
Restart informix server with "onmode -ku -y" and initialize with "oninit".
-
Check DRDA Connection (9089 port) with netstat inside your container.
- In your project add IBM.Data.DB2.Core nuget.
- In your connection string add this parameter: "Persist Security Info=True;Authentication=Server". Example in IfxConnectionTests.cs file on this repo.
- Done!