leawhig Posted June 14, 2022 Share Posted June 14, 2022 My NC is working fine. But one day I wanted to play with docker 😅 and wanted to split my NC DB (MySQL) into different ip. BUT Direct Error... Error code. SQLSTATE[HY000][2002] Connection Refused I would like to know why this is happening, thanks. Quote Link to comment
Aran Posted July 7, 2022 Share Posted July 7, 2022 (edited) BUMP I was playing with NC and FileRun and encoutered the same problem in both those dockers. So i don't think it's NC related. When the network type is changed to custom:br an given a different ip, it cannot connect to the database. Still, the ip's are within the same subnet. It does not matter if the databasehost is changed to localhost or 123.456.7.89 . To make it more rare, the problem only exists in my backup server. The NC docker on my main server is configured with custom network type. Both servers running unraid 6.9.2. What am i doing wrong? Please, enlighten me. Edited July 7, 2022 by Aran Quote Link to comment
Aran Posted July 7, 2022 Share Posted July 7, 2022 Found it: Set 'Host access to custom networks' to 'Enabled' from the docker settings page. When greyed-out, stop the docker service => enable host access to custom network => start docker again. 🙄 Quote Link to comment
primeval_god Posted July 7, 2022 Share Posted July 7, 2022 If the containers are on the same custom bridge network (not the default bridge) then you should be able to use the container name as the database host. Custom bridge networks have an internal DNS mapping for each container so containers can reference each other by name. 1 Quote Link to comment
chicherich Posted February 3 Share Posted February 3 On 7/7/2022 at 7:47 PM, primeval_god said: If the containers are on the same custom bridge network (not the default bridge) then you should be able to use the container name as the database host. Custom bridge networks have an internal DNS mapping for each container so containers can reference each other by name. That was it for me, thank you! Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.