Quick question on I/O limiter
For example, on my idle machine:
io_count=25139840 io_rate=0 io_tokens=200000 token_refill=512 token_max=200000
Clearly I'm not doing much I/O and so no problems.
But if it says
io_count=25142137 io_rate=166 io_tokens=199933 token_refill=512 token_max=200000
then would the limiter kick in?
Can the iorate ever go above tokenrefill?
In my sporadic checking I've never seen io_rate go above 300, but I just wanted to make sure I have the details correct in my own mind
5 Replies
The io_rate can go over the refill rate, but if it does it for to long you will run out of tokens.
It is when you run out of io_tokens you will run into a problem.
The system works the same as iptables buckets
Adam
io_count=25142137
I believe this is the total input/output your linode has done (since boot I think)
io_rate=166
This is how much input/output your Linode is currently doing per unit of time.
io_tokens=199933
This is basically your input/output buffer… If you're iorate is above tokenrefill, this will slowly go down. If it reaches 0, then that's when your Linode starts to get limited, and you can only use token_refill tokens per unit of time.
token_refill=512
The rate at which your io_tokens buffer is refilled per unit of time.
token_max=200000
The max size of your i/o buffer.
@tierra:
io_tokens=199933
This is basically your input/output buffer… If you're iorate is above tokenrefill, this will slowly go down. If it reaches 0, then that's when your Linode starts to get limited, and you can only use tokenrefill tokens per unit of time. So when I originally wrote "Am I right in assuming that if the iotokens value is positive then I'm not actively being limited? " then I was correct and I'm doing just fine
:-)
Thanks!
@sweh:
So when I originally wrote "Am I right in assuming that if the io_tokens value is positive then I'm not actively being limited? " then I was correct and I'm doing just fine
:-) Thanks!
That's kind of a yes and no answer. If your programming something that relies on that answer, then use the assumption that if iotokens is greater than tokenrefill, then your not actively being limited. Your Linode may have just been granted another tokenrefill tokens after being in the hole, in which case, your not in the free and clear just yet. Another way to tell is to look at your iorate. If it's close to the same as tokenrefill, and your iotokens bucket is pretty empty, then your being limited.
If your going to be making assumptions on this, your safest bet would be to say if your iotokens is less than 10% of your tokenmax, then your using too much I/O.