Forum Discussion
LTM VE 10.2.3: number of requests per day
Hi all, I need to know the number of total requests per day that the BIG-IP LTM VE 10.2.3 appliance receives. Can anyone tell me how I can know it, please? Thx a lot.
- uniAltostratus
Quick and dirty method, run this each day from bash:
tmsh show ltm virtual raw|grep 'Total Req'|cut -d- -f3|awk '{s+=$1}END{print s}'
followed by
if you can't be bothered doing a subtraction each day.reset-stats ltm virtual
- almudena_3796Nimbostratus
Thx a lot. What I made was to create the following script named total_requests:
/bin/date +%d/%m/%y_%H:%M >> /var/local/scripts/total_requests.out /usr/bin/tmsh show ltm virtual raw|grep 'Total Req'|cut -d- -f3|awk '{s+=$1}END{print s}' >> /var/local/scripts/total_requests.out
When I run it, it works: [root@F5:Active] scripts /bin/bash /var/local/scripts/total_requests [root@F5:Active] scripts cat total_requests.out 13/01/14_11:42 99
BUT when I let crontab run it, it does not work: [root@F5:Active] scripts crontab -l
00,15,30,45 * * * * /bin/bash /var/local/scripts/total_requests
[root@F5:Active] scripts cat total_requests.out 13/01/14_11:45 <-it does not appear the value
Is there any bug with crontab?
- uniAltostratusDebugging cron issues is very low on my list of fun things to do. Try capturing stderr for your tmsh command.
- almudena_3796Nimbostratus
Crontab is working with the following script:
/bin/date +%d/%m/%y >> /var/local/scripts/total_requests.out /usr/bin/tmsh show ltm virtual raw|grep "Total Req" >> /var/local/scripts/tr.out awk '{s+=$5}END{print s}' /var/local/scripts/tr.out >> /var/local/scripts/total_requests.out tmsh reset-stats ltm virtual
Recent Discussions
Related Content
* 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