Forum Discussion
automate command-line statistics
bigtop -once -vname|grep '[0]\ \+[0]\ \+[0]\ \+[0]\ \+[0]\ \+'
long.name.of.virtual. 0 0 0 0 0 0 0
long.name.of.node.com 0 0 0 0 0 0 DOWN
i have a few concerns though:
1) bigtop cuts off the virtual/node name after 21 characters. any idea how to get the whole thing? this is pretty important to me since we have lots of long hostnames.
2) what's the lowest level of access i can run a global statistic reset with? this is to be automatically run remotely so i'd like the user to have as little access as possible.
3) is there a better way to do this other than cutting up the output of bigtop?
thanks!
2 Replies
- Mike_Kahler_488Historic F5 Account1. I don't know of any way to make bigtop print more than 1st 21 chars.
3. I looked at this through snmp:
snmpwalk -v 2c -c public localhost ltmVirtualServStatClientTotConns | awk -F \" '{print $2, $3}' | grep 'Counter64: 0'
test_more_than_21_chars_nowisthetimeforallgoodmemtocometotheaidoftheirparty = Counter64: 0
You can reset virtual server stats through snmpset if you have a read/write agent configured:
snmpset -c private -v1 localhost F5-BIGIP-LOCAL-MIB::ltmVirtualServStatResetStats.0 i 1
You can do the same for "Nodes"
F5-BIGIP-LOCAL-MIB::ltmNodeAddrStatServerMaxConns
F5-BIGIP-LOCAL-MIB::ltmNodeAddrStatResetStats - The_Bhattman
Nimbostratus
Here are a couple of commands that I will throw our there
F5 Connection Count Summarization
b conn | grep 3.3.126.53 | awk '{print $1 }' | cut -d : -f 1 | uniq -c | sort
F5 Virtual List via BIGIP.conf for v9.x
awk 'BEGIN {RS="}";FS=RS} // {print $1"}";} ' /config/bigip.conf
show all VIP addresses with MAX Conns greater than 200
snmpwalk -c l0cal 127.0.0.1 F5-BIGIP-LOCAL-MIB::ltmVirtualAddrStatClientMaxConns|awk -F: '{if($4 > 200) print }'
show all VIP addresses with Curr Conns greater than 200
snmpwalk -c l0cal 127.0.0.1 F5-BIGIP-LOCAL-MIB::ltmVirtualAddrStatClientCurConns|awk -F: '{if($4 > 200) print }'
Leave out the awk -F: '{if($4 > 200) print }' to see all VIP addresses
NOTE: Make sure you allow SNMP from local loop address 127.0.0.1 from the GUI
I hope this helps
Bhattman
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
