Forum Discussion
Jeff_Witkowski_
Altostratus
Dec 19, 2017LTM commands output and reporting
I'm trying to gather and document details for LTMs 11.n including virtual server Names, VIPs, Pools, Services and Nodes. While I can run a recursive command and output the data I haven't found a simp...
jaikumar_f5
Noctilucent
Dec 20, 2017You can try going with bash with tmsh commands, save the output in csv format. winscp it to windows and use it.
Making headings & intialize the file
echo Virtual-Server, Destination, Pool, Pool-Members > /var/tmp/$HOSTNAME.csv
Capture all virtuals in the LTM
VIRTUALS=$(tmsh list ltm virtual | grep "ltm virtual" | cut -d" " -f3)
for VS in $VIRTUALS;
do
DEST=$(tmsh list ltm virtual $VS | grep destination | cut -d" " -f6)
POOL=$(tmsh list ltm virtual $VS | grep pool | cut -d" " -f6)
if [ -n "$POOL" ];
then
MBRS=$(tmsh list ltm pool "$POOL" | grep address | cut -d" " -f14)
fi
echo $VS,$DEST,$POOL,$MBRS >> /var/tmp/$HOSTNAME.csv
done
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