Server ip address blocked?


#1

I’m not sure if this is the correct category, if it’s incorrect please let me know.

I’m using a PHP script to get a user’s timeline via RSS and display the latest tweet on that user’s website. I’m using the same script on several different servers and it’s working perfectly. On one of the server’s however, one which is hosting ten different websites, I’m receiving the following error message for all of them: (asterisks added)

file_get_contents(https://api.twitter.com/1/statuses/user_timeline.rss?screen_name=the*****) [function.file-get-contents]: failed to open stream: Connection refused in /home/******/public_html/responsive/inc/twitterpost.php on line 55

I’ve tried WGET from the same server and receive the following error, leading me to believe this server has had it’s IP address blocked:

Resolving api.twitter.com… 199.59.148.87, 199.59.149.232, 199.59.150.9
Connecting to api.twitter.com|199.59.148.87|:443… failed: Connection refused.
Connecting to api.twitter.com|199.59.149.232|:443… failed: Connection refused.
Connecting to api.twitter.com|199.59.150.9|:443… failed: Connection refused.

I’m using a cache file in order to limit the number of requests per hour and the same script works fine on my local machine as well as on different servers.

Thanks for any help you can provide!


#2

Do you know if the IP address where you are unable to access is shared with any other parties? Perhaps something someone has done on that IP address has caused it to be blacklisted. How sophisticated is your back-off/retry code when faced with API errors? If you’re still experiencing this problem and the IP address is under your sole control, consider following up with API policy for further investigation: https://support.twitter.com/forms/platform


#3

Hi Taylor, thanks for your reply.
The IP address isn’t shared with anyone else, just between the sites I host on that server. As for the back-off/retry code, I’m not too sure - it isn’t my script.
Thanks for the link, I’ll follow it up now.