-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
request: bandwidth consumption #551
Comments
using reqs/sec and content size to calculate bandwidth would not include overhead from the headers at several layers of network transfer, so it won't be a real accurate measure of bandwidth used. It's also not a trivial change :) |
It would be an awesome add-on though. It would be great to have a methode
inside locust to do this, otherwise you'd have to make another tool that
traces bandwidth used on a nic.
I'll take a look, maybe I can find something trivial like a library which
does it. Would be easy to include into locusts then.
Op 23 feb. 2017 5:11 p.m. schreef "Corey Goldberg" <[email protected]
…:
using reqs/sec and content size to calculate bandwidth would not include
overhead from the headers at several layers of network transfer, so it
won't be a real accurate measure of bandwidth used. It's also not a trivial
change :)
I think this type of metric is better handled by measuring with network
monitoring tools.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#551 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AGA5znhLuhyoxTFFYeMb6yMDOpM-jSzaks5rfa-fgaJpZM4MJ8oR>
.
|
but lots of such tools exist.
check out It's a popular library for gathering system and process stats. It's also cross-platform, which is probably the most difficult part of implementing this to intregrate with Locust. You would need to retrieve network i/o stats for a given nic (or all nics) at specified intervals, and then do calculations to get bits/sec for each interval (and probably aggregate stats for the entire run). You can get at the data easily with the There is an example included that has most of it done for you: just remember that these stats are system-wide, not per process. (but maybe that's what you are after anyways). hope that helps.. |
Very much, thanks!
Op 23 feb. 2017 8:57 p.m. schreef "Corey Goldberg" <[email protected]
…:
otherwise you'd have to make another
tool that traces bandwidth used on a nic.
but lots of such tools exist.
maybe I can find something trivial like a library which does it
check out psutil: https://github.com/giampaolo/psutil
It's a popular library for gathering system and process stats. It's also
cross-platform, which is probably the most difficult part of implementing
this to intregrate with Locust. You would need to retrieve network i/o
stats for a given nic (or all nics) at specified intervals, and then do
calculations to get bits/sec for each interval (and probably aggregate
stats for the entire run).
You can get at the data easily with the net_io_counters() function from
psutil: https://pythonhosted.org/psutil/#psutil.net_io_counters
There is an example included that has most of it done for you:
https://github.com/giampaolo/psutil/blob/master/scripts/nettop.py
just remember that these stats are system-wide, not per process. (but
maybe that's what you are after anyways).
hope that helps..
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#551 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AGA5zkY1oRcvdsnlnF8cOWmBHABFbAI1ks5rfeS6gaJpZM4MJ8oR>
.
|
Hi,
Locust is great for testing, it would be even more awesome if there is a way (graphically) to see what the consumed bandwidth (per sec) is.
Is there a way to implement this quickly? As the number of requests per second and the content size is known, i assume the bandwidth is also traceable? This especially is convenient when master-slave configurations are used.
Thanks!
The text was updated successfully, but these errors were encountered: