lua-resty-mysql icon indicating copy to clipboard operation
lua-resty-mysql copied to clipboard

Can not connect to mysql by setting mysql_host = xxxxxxxxxx.mysql.rds.aliyuncs.com

Open huuuunt opened this issue 11 years ago • 3 comments

Aliyun RDS server require mysql_host using domain name. When I set "mysql_host = xxxxxxxxxx.mysql.rds.aliyuncs.com", I found can not connect to mysql.

Error info: failed to connect: no resolver defined to resolve "xxxxxxxxxxxx.mysql.rds.aliyuncs.com".

How can I do about it.

huuuunt avatar Jun 28 '14 14:06 huuuunt

@huuuunt The error message clearly indicates that you have not defined any resolvers in your nginx.conf. See http://nginx.org/r/resolver for details.

agentzh avatar Jun 29 '14 00:06 agentzh

Thanks!! Done!

huuuunt avatar Jun 29 '14 02:06 huuuunt

@agentzh I am having similar issue while linking docker container to openresty. The named container does not work and I get this error

failed to connect: failed to connect: no resolver defined to resolve "mysql": nil nil

mysql here is the container name. Nginx is able to resolve my all other containers such as php, hhvm but in my lua script is not able to.

aftabnaveed avatar May 22 '18 08:05 aftabnaveed