Forum Discussion

ChromeTemplar's avatar
ChromeTemplar
Icon for Nimbostratus rankNimbostratus
Nov 05, 2014

How can I determine if an iRule is in use?

I am updating our iRules from 11.3 to 11.5.1 HF5. As part of this process, I want to identify (and remove) iRules that are not currently in use.

 

My understanding is that I can look in the bigip.conf file and see which iRules are used by virtual servers. Is this the case?

 

I do not have access to that file; but I do have read access to the iRules through the web based BIG IP Configuration Utility.

 

Is there a way to see if an iRule is active without visiting every virtual server's resource page in the BIG IP Configuration Utility?

 

Sorry if this is a noob question.

 

Thanks!

 

7 Replies

  • If you navigate to Local Traffic | Network Map, and show the map, it will show you each virtual server and any iRules assigned to that virtual server. You can also look at iRule statistics to get an idea of which iRules are actually being executed

     

    • ChromeTemplar's avatar
      ChromeTemplar
      Icon for Nimbostratus rankNimbostratus
      Awesome! Thanks! I found that after I click on Local Traffic in the left hand pane, and then click iRules->Statistics, I can see all the statistics for all the iRules and events. This is awesome!
  • shaggy's avatar
    shaggy
    Icon for Nimbostratus rankNimbostratus

    If you navigate to Local Traffic | Network Map, and show the map, it will show you each virtual server and any iRules assigned to that virtual server. You can also look at iRule statistics to get an idea of which iRules are actually being executed

     

    • ChromeTemplar's avatar
      ChromeTemplar
      Icon for Nimbostratus rankNimbostratus
      Awesome! Thanks! I found that after I click on Local Traffic in the left hand pane, and then click iRules->Statistics, I can see all the statistics for all the iRules and events. This is awesome!
  • Arie's avatar
    Arie
    Icon for Altostratus rankAltostratus

    If you use the iRule editor you can look at the properties of each rule (right-click). That provides a list of all VIPs that use (and don't use) the rule.

     

    You can also query the bigip.conf file.

     

  • you can use this from bash to get a list of irules associated with VSs

     tmsh -q -c "cd /; list ltm virtual recursive rules" | awk 'BEGIN {RS="\n}"} !/none/ {print}' | grep -v ' rules \|}'
    

    then you could check the stats in the irules within tmsh

    show ltm rule xxxxx
    

    cheers