开发者

How to determine bandwidth used by cron job?

I'm not a unix guy. CPanel does a good job of managing cr开发者_开发技巧onjobs and that is what I used to run dozens of cronjobs. All of them combined run more than 5000 times every day. Every cron makes a call to an external API.

How can I check how much bandwidth are all the cron jobs eating? For my website I use awstats and that shows bandwidth usage et al.

Another thing is that I dont want the admins to ban the cron jobs because they are using too much bandwidth (and CPU), more than what is allocated in my web hosting package.


You can do all kinds of crazy things with netcat. See http://pauldotcom.com/wiki/index.php/Episode195#Instrumented_Relays for some examples. Combine with tee and wc to count actual bytes passed.


You may want to look at the bandwidth used for individual API calls.

At least I am not aware of a utility that can do b/w analysis at process/thread level. It's at network layer.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜