Forum Discussion
scott_sams_8256
Nimbostratus
Feb 20, 2009content tracking
we found an irule here by Kirk (thanks Kirk) that breaks content down by count. any genius out there that can take this and add total bytes for each category? our ecomm group wants to see the breakd...
Jon_Strabala_46
Nimbostratus
Jul 02, 2011What if I don't care to have the above show up in the GUI F5 interface but want to merely keep a count for every five minutes and write it out to a file and zero the stats
(before anyone goes crazy on me - In my use case I will actually track the content_and_len by some key like USER-AGENT)
I imagine I use could use the version 10.1.* "TABLE" syntax for my hashes and counters along with "AFTER" and dump my results to file (preferably named ua_use_yyyymmdd.out). If I can't use iRULEs to write to a file I guess I could use a rolling log.
rolling log: http://devcentral.f5.com/Tutorials/TechTips/tabid/63/articleType/ArticleView/articleId/1084377/Writing-to-and-rotating-custom-log-files.aspx
Here is some simple code using AFTER (I did not use the "table" syntax) to show what I am having an issue getting my head around
when RULE_INIT {
set reqs_last_600_sec 0
set new_req_count 0
after 600000 –periodic
set reqs_last_600_sec $new_user_count
set new_req_count 0
HOW DO I SAVE the reqs_last_600_sec value to a file ?
Is it better to send it to a rollign log file or is it
better to make an OOB request to some other server like
a memcached server. }
}
when HTTP_REQUEST { incr new_req_count }
Any help or directions would be appreciated.
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
