API Error: cURL error 28: Operation timed out after 20000 milliseconds with 0 b

#27523
  • Resolved Josh Gibson
    Rank Math free

    API Error: cURL error 28: Operation timed out after 20000 milliseconds with 0 bytes received

    I spent am hour or 2 talking to my web hosting provider (HostGator shared host) and they say there are no blacklisted IP domains on the list for my account(s) and not rankmath.com IP either. They also check the cURL and it tested ok. I have a reseller account with dozens of websites and this problem is only happening on 4 of my sites? I really like Rankmath (because it’s easy to use) and would like to get this problem solved. Thanks.

    • This topic was modified 4 years, 11 months ago by Michael Davis.
Viewing 11 replies - 1 through 11 (of 11 total)
  • Hello,

    Thank you for contacting Rank Math and sorry for any inconvenience that might have been caused due to that.

    To be able to chase this down further, could you please share some FTP access as well on the sensitive data section?

    Looking forward to helping you. Thank you.

    ​​​​​​​

    [DELETED]

    Let me know if you need anything else.

    • This reply was modified 4 years, 11 months ago by Michael Davis. Reason: Public credentials

    Hi there,

    Thanks for the reply.

    It is not recommended to share credentials on the public facing forum. I have deleted the credentials and added them to the sensitive data section instead.

    We are checking this issue and we will have an update in a short while.

    Your patience is highly appreciated. Thank you.

    Hello,

    I have logged in to your site to check this issue and from what I see, the problem was that the request kept timing out when your server was trying to reach ours. I have edited one of the plugin files through FTP: I changed the timeout limit in the plugin’s code (from 20 to 60 seconds) and now the analysis is working correctly.

    The change I’ve made will be lost when you update the plugin, so the analysis may stop working again. I’m not quite sure why this issue was happening but I have taken note of it and we will see if it can be fixed permanently in a future update.

    Hope that helps.

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Hi Josh,

    Thank you for getting back to us.

    Can you confirm that the issue is resolved?
    The login token on the sensitive data section does not seem to work.

    Thank you.

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    From Support Staff: Balazs
    “I have logged in to your site to check this issue and from what I see, the problem was that the request kept timing out when your server was trying to reach ours. I have edited one of the plugin files through FTP: I changed the timeout limit in the plugin’s code (from 20 to 60 seconds) and now the analysis is working correctly.

    The change I’ve made will be lost when you update the plugin, so the analysis may stop working again. I’m not quite sure why this issue was happening but I have taken note of it and we will see if it can be fixed permanently in a future update.”
    >———————————————————————————
    I am having the same issue on other websites I installed the RankMath plugin, some sites work and others don’t? It will work for a while then I get the “API Error: cURL error 28: Operation timed out after 20000”. Can you give me the procedure for changing the timeout limit and the plugin you edited?
    Thanks,
    Josh

    Hi Josh,

    I edited the following plugin file:
    /includes/modules/seo-analysis/class-seo-analyzer.php

    I changed the following line (line number 358):
    $request = wp_remote_get( $api_url, [ 'timeout' => 20 ] );

    I increased the timeout value to 60:
    $request = wp_remote_get( $api_url, [ 'timeout' => 60 ] );

    In the future we might add a filter hook to this line, so that the value can be changed from outside the plugin. That way, you won’t have to redo the change after each update of the plugin.

    Hope that helps. If you have any question, please feel free to ask.

    That worked. I just made the correction on 1 file and downloaded to my other sites that had the same issue. On your next update just add 60 to timeout? Like the plugin compared to other SEO plugins and would like to continue using it. Thanks again.

    Hi Josh,

    I am glad that this is now resolved 🙂

    Feel free to contact us should any other issues come up.

    Thank you.

Viewing 11 replies - 1 through 11 (of 11 total)

The ticket ‘API Error: cURL error 28: Operation timed out after 20000 milliseconds with 0 b’ is closed to new replies.