F5 is upgrading its customer support chat feature on My.F5.com. Chat support will be unavailable from 6am-10am PST on 1/20/26. Refer to K000159584 for details.

Forum Discussion

gondeeri's avatar
gondeeri
Icon for Nimbostratus rankNimbostratus
Nov 10, 2014

Script for tcpdum with cron

Hello,

 

I need to help with one script. I need make script on F5 for tcpdump with cron. Purpose of this srcript is that every day 20 minutes from 5:50 to 6:10 i need turn on tcpdump on client and server side as well. I try something prepare but I not have any experience with scripting. Could you pls check my script if it's good or make provide me some new script?

 

Script start-tcpdump

 

!/bin/bash

nohup tcpdump -i -s 0 -w //tmp/var/soubor.pcap

 

Script stop-tcpdump

 

!/bin/bash

killall -15 tcpdump

 

50 5 * * * /root/bin/start-tcpdump 10 6 * * * /root/bin/stop-tcpdump

 

PS:Do you think, that this script is not more for loadbalancer?

 

thanks

 

1 Reply

  • kunjan's avatar
    kunjan
    Icon for Nimbostratus rankNimbostratus

    There is syntax error and file location error.

     

    tcpdump -i 0.0:nn -s 0 -w /var/tmp/soubor.pcap