Forum Discussion
simon_irwin_849
Jan 24, 2011Nimbostratus
Memory footprint of an iRule
Hi guys -
Is there any way to tell how much memory an iRule requires to maintain a given TCP connection?
Here's my scenario:
- i have a TCP virtual server with an associated iRule
- the iRule is quite long and relatively complex; among other things, it wakes up every 30 seconds or so to check the status of the connection (e.g. inactivity and data thresholds).
Load testing is indicating that the iRule adds an extra 10kb to each TCP connection (I think it was 4K without the iRule, 14K with the iRule). This seems to be an average when 100,000s of simultaneous connections are used. I think tmstat was used to measure this.
My question is whether a developer has ready access to the amount of memory required for a single connection. I want to be able to tweak the iRule and see the memory requirements drop (hopefully!) so I can make informed decisions about what looks worth changing.
any help would be gratefully received
thanks
Simon
- L4L7_53191NimbostratusSimon: have you considered using the native TCP profile timeouts to manage that portion of this rule? It may be possible to optimize that a bit via native mechanisms as opposed to doing it all within the iRule.
- Colin_Walker_12Historic F5 AccountSimon,
- simon_irwin_849NimbostratusGuys - thank you for your replies. Apologies for not responding before now - I need to setup email alerts for this topic!
- Colin_Walker_12Historic F5 AccountHah, I love your thought process, it's right on the money. Unfortunately you're completely correct. Even if you could get at the byte code it wouldn't give you an accurate depiction of the entirety of the memory footprint. Your best bet is going to be to do some polling.
- simon_irwin_849NimbostratusThanks, Colin. We've been running our load tests to try to measure where the best gains in RAM are. Reducing the use of local variables has been the biggest help so far.
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects