Forum Discussion
Hello,
Do you have multiple iRules on the same vServer?
- Anthony_AOct 06, 2020Altostratus
That was it! Out of the 600+ HTTP-to-HTTPS redirect virtuals with the _sys_https_redirect iRule, a handful of them had second iRules that had HTTP::respond events. I just removed those secondary iRules after I determined I didn't need them to do what they were doing. Logs look good now. Thanks again for your help!
If anyone is curious, I came up with the below bash script to quickly find the culprit virtuals (I didn't have enough time to get fancy though so it just echos the comma-delimited output to stdout).
#!/bin/bash IRULE="_sys_https_redirect" VIRTUALS=$(tmsh list ltm virtual one-line | grep -i ${IRULE} | cut -d' ' -f3) for VS in $VIRTUALS do IRULES=$(tmsh list ltm virtual "${VS}" one-line | grep rules | sed -e 's/.* rules { //' -e 's/ }.*//') echo "$VS,$IRULES" done
- Mayur_SutareOct 07, 2020MVP
I suspected the same that it was due to other iRules. I am glad it helped you.
Also thanks for sharing above script. Cheers!
- Anthony_AOct 06, 2020Altostratus
Hi Mayur,
Thanks for the response. I didn't even think of that. Usually with our HTTP virtual servers that only exist to redirect to their HTTPS counterparts, there is usually only the "_sys_https_redirect" iRule. But it's possible there may be HTTP virtual servers with the _sys_https_redirect iRule and another iRule.
Problem is though is that we have a couple thousand virtual servers with maybe a third of them only existing for HTTP-to-HTTPS redirection. Will need to write a quick script to find all the virtuals that have the "_sys_https_redirect" iRule attached and another iRule.
Thanks for the advice! Will reply back with what I find.