FileZilla Server - Connection attempt failed with ECONNREFUSED - Connection refused by server
the problem
When I was trying to set up a FileZilla Server using FTPS and the default settings I got the error “ECONNREFUSED - Connection refused by server”.
the cause
This was due to the default parameter for the IP address retrieval.
![](https://cdn.gpunktschmitz.de/blog/1021/FileZilla-passive-mode-default-setting.png)
The erroneous script always returns 127.0.0.1.
![](https://cdn.gpunktschmitz.de/blog/1021/ip_filezilla-project_org.png)
the solution
I’ve set up a script which returns the current public IP.
![](https://cdn.gpunktschmitz.de/blog/1021/FileZilla-passive-mode-custom-url.png)
![](https://cdn.gpunktschmitz.de/blog/1021/gpunktschmitz_com-ip.png)