Forum Discussion
Livius
Cirrus
Sep 12, 2018Crontab not working
Hi all,
Trying to set up a rotating tcpdump on F5 , I added the following entries in crontab :
0,15,30,45 * * * * pkill tcpdump
0,15,30,45 * * * * tcpdump -ni 0.0:nnnp -s0 host x.x.x.x or...
youssef1
Cumulonimbus
Sep 12, 2018Hello,
I advise you to proceed like that (don't use pkill tcpdump 0,15,30,45 ... instead use timeout as shown below):
So first of specify when you want to trigged your tcpdump, you can use an online generator:
https://www.freeformatter.com/cron-expression-generator-quartz.html
Then use command
timeout (sec) in order to setup how many times you want to capture (suppose 5 sec), you will obtain (crontab every 10 minutes):
*/10 * * * *
timeout 5 tcpdump -ni 0.0:nnnp -s0 host x.x.x.x or host y.y.y.y or host z.z.z.z -w /var/tmp/2518/2518_v4_`date +%Y%m%d%H%M%S`.pcap
Keep me update regards
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects
