Forum Discussion
Need to apply profile with script
- Jun 17, 2019
Hello Ashish
1) awk '{ print $3 }' = separate the previous output by spaces and take the third value.
https://en.wikipedia.org/wiki/AWK
2) xargs -l {} = take the stdin (by line) and use it in the next command when characters '{}' are shown.
https://en.wikipedia.org/wiki/Xargs
BTW, I would appreciate if you mark my answer as "the best" or give me some upvote.
KR,
Dario.
Hello.
You can do it in four simple steps
1) Capture all VS configured in '/Common' partition
# tmsh list ltm virtual one-line | awk '{ print $3 }' > output.txt
2) Manually remove from 'output.txt' those VS that you don't want to modify
3) Change the HTTP profile in all VS in that list
# cat output.txt | xargs -I {} tmsh modify ltm virtual {} profiles add { <new_http_profile> } profiles delete { <current_http_profile> }
4) Save config from running-config to startup-config
# tmsh save sys config
KR,
Dario.
Recent Discussions
Related Content
* 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