[gdal-dev] Connect ogr2ogr without socket

Felipe Matas felipematas at yahoo.com
Wed Mar 23 11:18:52 PDT 2022


Hi, I'm testing a new db that is dolt, is like git in db, literally, but that db does not support connection through socket, but the db is mysql, or like a simulation of it, I'm trying this to check the connection:
ogrinfo MySQL:"host=127.0.0.1 port=3306 user='root' password='' dbname='test'"

I try several syntax too, and the answer from the ogrinfo was similar to:

ERROR 1: MySQL connect failed for: host=127.0.0.1;port=3306;user='root';password=XXXXXXXXXXXXXXXXXXXXXXX connect to local MySQL server through socket '/run/mysqld/mysqld.sock' (2)
ERROR 1: MySQL connect failed for: host=127.0.0.1;port=3306;user='root';password=XXXXXXXXXXXXXXXXXXXXXXX connect to local MySQL server through socket '/run/mysqld/mysqld.sock' (2)
FAILURE:
Unable to open datasource `MySQL:host=127.0.0.1;port=3306;user='root';password='';dbname='water'' with the following drivers.
(here the very long list of drivers, MySQL is in the list.
ogr is trying to connect from a socket, and the db does not support it, the connection need to be TCP, how can I force the ogr to use TCP? (not just for local, for remote servers too, and ogr2ogr too)

Thx.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20220323/f753bdd6/attachment.html>


More information about the gdal-dev mailing list