server performance: multiple external connections and performance
I am creating a php script that requires the server to make several cURL requests per run. I'll be running this script through cron every 3 minutes. Im looking to maximize the amount of cURL requests I can make in a 24 hr period.
What I am wondering is if it would be better from a performance standpoint to get a dedicated server, or several small shared hosting accounts. With the problem being number of external connections and not system resource开发者_C百科s I'm wondering which is the best approach.
Shared hosting accounts generally have a very low limit, making something like this difficult. I would not recommend this. It would be MUCH more effective to invest in a VPS hosting account (such as one with Linode or Slicehost). They generally don't have a connection limit (or at least not one that I've run into). They're also faster and much more cost-effective than straight-up shared hosting. A dedicated server would be overkill.
Also, since you're using PHP, feel free to take advantage of curl_multi_init
, which will allow you to run many cURL requests at once.
Hope this helps!
精彩评论