Hi people,
I'm trying to connect my VM with my SQL instances using cloud_sql_proxy but I got this message when I tried it :
current FDs rlimit set to 200000, wanted limit is 8500. Nothing to do here
And then an Error: connect ETIMEDOUT
I already set the FDs limit to 8500 as the error message suggested but it still doesn't work so I increased it to 200000 and it still doesn't work
The error message "current FDs rlimit set to 200000, wanted limit is 8500. Nothing to do here" indicates that the maximum number of file descriptors (FDs) your VM is allowed to have is set to 200,000. The cloud_sql_proxy tool checks if the FD limit is at least 8500, which is its recommendation. Since your limit is already much higher, there's no need to adjust it.
The "Error: connect ETIMEDOUT" message means that the cloud_sql_proxy process was unable to establish a connection to your SQL instances within the expected timeout period.
To address this:
Ensure the FDs limit for your VM is at least 8500, although in your case, it's already set much higher. If needed, you can adjust it with: ulimit -n 8500.
Verify the firewall rules for your VM to ensure they allow connections to your SQL instances.
Consider restarting the cloud_sql_proxy process.
If you continue to face issues, reaching out to Google Cloud support might be beneficial.
Additional Notes:
The FDs limit represents the maximum number of open files a process can have. This limit is determined by the OS but can be modified by the user.
If you're using a firewall, ensure it permits connections to the port that cloud_sql_proxy uses. The default port varies based on the database type (e.g., 3306 for MySQL, 5432 for PostgreSQL, 1433 for SQL Server).