Current location: Hot Scripts Forums » Programming Languages » PHP » about cURL


about cURL

Reply
  #1 (permalink)  
Old 02-04-10, 12:42 AM
sunanurag sunanurag is offline
Newbie Coder
 
Join Date: Aug 2009
Posts: 51
Thanks: 2
Thanked 0 Times in 0 Posts
about cURL

Hi All,

If we want to communicate between two server we can use cURL for this purpose.i think using cURL we can fetch the data from only one server at a time. suppose if we want to fetch the similer type of data let say cpu load from more then 1 server at a time ,then what should i do? can i do it with the help of cURL, if yes then how?if no then what are the other ways to solve this problem?

reply soon...
Thanks in advance.

Regards,
Anurag
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 02-04-10, 08:37 AM
scott2500uk's Avatar
scott2500uk scott2500uk is offline
Coding Addict
 
Join Date: Apr 2006
Posts: 275
Thanks: 2
Thanked 2 Times in 2 Posts
What you would need to do is on the server you want to read off the load is make up a script that reads the load from the server and displays it. Then you would use cURL to read that page that displays the load.

For that script to read load the easiest way would be to use SNMP to read the servers MIB's. With this you can get all sorts of info such as server load, uptime, disk space usage and network utilization.

If you used SNMP you could cut out the cURL bit as SNMP can be read from a different server providing the traffic isnt blocked.

Take a look at SNMP over at PHP PHP: SNMP - Manual

Also I have some sample code to read disk space usage with SNMP on my blog Brady Getting Windows HDD usage with PHP and SNMP

This is only one way of reading system data and I believe there are others.

Hope this helps
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
curl strange behaviour bhavin12300 PHP 9 09-26-09 11:36 PM
curl + post + cookies naissa PHP 1 08-30-09 07:36 AM
PHP Curl horeru_tenshi PHP 4 05-14-09 08:02 AM
Another cURL problem :( arshem PHP 0 01-27-09 09:38 PM
Trying to get CURL to work.... End User PHP 0 04-07-05 12:11 AM


All times are GMT -5. The time now is 12:44 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.