Forum Discussion

Tafiela_89904's avatar
Tafiela_89904
Icon for Nimbostratus rankNimbostratus
Apr 26, 2018

F5 Configuration

Hi,

 

I need to run a script on 11 F5s in our environment, I can pull the configuration file and run the script against. What i need is the following :

 

1- generate a spreadsheet with the following columns: Virtual Server Name, VIP, Pools, Node 2- parse the configuration and update the spreadsheet with the above details.

 

Thank you for your help in advance!

 

1 Reply

  • This is asked over and over again 🙂

    Please refer this thread. Fetch all details about VS, POOLS, Nodes, etc.

    Solution:

    tmsh list ltm virtual one-line |awk '{for(i=0;i<=NF;i++)if($i=="pool"){p=$(i+1)}; print $3,$6,p}' |awk '{cmd="tmsh list ltm pool " $3 " one-line"; cmd|getline r; print $1,$2,$3,r}' |awk '{printf "%s,%s,%s",$1,$2,$3} {for(j=3;j<=NF;j++)if($j~/:/){printf ",%s",$j} {print ""}}' >> /var/tmp/collecting-nitas-method.csv