Bash script is not working as cron job

Your PATH variable probably isn't what you expect it to be inside cron.

Use full paths to each executable in your script or set the path manually in your crontab or the script.

Also, a better way of stopping your tshark would be using the built-in functionality:

   -a  <capture autostop condition>
       duration:value Stop writing to a capture file after value seconds
       have elapsed.

Also #2: add a shebang line (#!)


Cron will limit the path used by cron jobs. Try /usr/sbin/tshark instead of just tshark. You can check where tshark is via which tshark


Looking at your script I see you're attempting to capture traffic for two minutes and write a file. Did you really mean to have a cronjob that runs on every Wed/Thur/Friday in February, every other hour at 1 past the hour? I'm guessing you wanted it to run every 2 minutes...

From crontab(5) (which can be read with man 5 crontab)

   cron(8) examines cron entries once every minute.

   The time and date fields are:

          field          allowed values
          -----          --------------
          minute         0-59
          hour           0-23
          day of month   1-31
          month          1-12 (or names, see below)
          day of week    0-7 (0 or 7 is Sun, or use names)

   A field may be an asterisk (*), which always stands for "first-last".