CLI syntax to change i-rule order
- Feb 12, 2024
Hi Grandiser,
You can use
tmsh edit ltm rule 'name_of_the_iRule'
2nd method
Create a new irule with new name using create command with new rule order sequence
tmsh create ltm rule NEW-IRULE irule1 irlue 2
then use modify statement in the Virtual server to switch the iRule to new iRule
tmsh modify /ltm virtual rules { NEW-IRULE }
Please note this will removes all the applied irules and only adds the new irule inside the curly braces.
When using tmsh, you can only create iRules using the editor, which starts when you use the create or edit commands. You cannot create an iRule directly on the command line. The vim editor applies the autoindent and smartindent options. You can toggle on/off paste mode using the F12 key.
11.3 tmsh cli for irule | DevCentral
https://clouddocs.f5.com/cli/tmsh-reference/v13/modules/ltm/ltm_rule.html
Hope this helps
🙏