title: No output from ''tail -f | gawk | tee''; either ''tail -f | gawk'' or ''gawk | tee'' works fine
body: <p><code>tee</code> works fine if placed before the gawk command, but not at all if placed after. Is it not possible to use after gawk?</p>
  
  <pre><code>#!/bin/bash
  CURRENT_DATE=`date -u +%Y-%m-%d`
  
  tail -fn0 /var/log/pi-star/MMDVM-"$CURRENT_DATE".log | gawk ' match($0, 
  /received.*voice header from ([[:alnum:]]+) to ([[:alnum:]]+ [0-9]+)/, 
  a) {
  in_record = 1
  call_sign = a[1]
  channel = a[2]
  }
  in_record &amp;&amp; match($0, /DMR ID: ([0-9]+)/, a) {
  dmr_id = a[1]
  }
  in_record &amp;&amp; match($0, /([0-9.]+) seconds, ([0-9]+)% packet loss, BER: 
  ([0-9.]+)%/, a) {
  in_record = 0
  print call_sign, channel, dmr_id, a[1], a[2], a[3]
  } ' OFS=, | tee -a log.txt
  </code></pre>
  
  <p>EDITED - Using the above bash script  when placing the tee command after TAIL but before GAWK I get a perfect replication of the original log that is being tailed, but with it comes all the unneeded information that GAWK is to filter. When I place the tee command at the end of the file (as it is above) nothing goes into the log.txt file and nothing is displayed on the screen as the original log changes.</p>
  
  <p>Here is a portion of the original logfile that is in the tail command.</p>
  
  <pre><code>M: 2019-06-10 00:00:03.667 DMR Slot 2, received network voice header 
  from W3DON to TG 310
  M: 2019-06-10 00:00:03.911 DMR Slot 2, received network end of voice 
  transmission, 0.5 seconds, 0% packet loss, BER: 0.0%
  M: 2019-06-10 00:00:11.611 DMR Slot 2, received network voice header 
  from KD2QDD to TG 310
  M: 2019-06-10 00:00:11.634 DMR Slot 2, received network end of voice 
  transmission, 0.5 seconds, 12% packet loss, BER: 0.0%
  M: 2019-06-10 00:00:12.703 DMR Slot 2, received network voice header 
  from IZ0LDE to TG 310
  M: 2019-06-10 00:00:13.932 DMR Slot 2, received network end of voice 
  transmission, 1.2 seconds, 0% packet loss, BER: 0.0%
  M: 2019-06-10 00:00:20.426 DMR Slot 2, received network voice header 
  from N1GMB to TG 310
  M: 2019-06-10 00:00:26.293 DMR Slot 2, received network end of voice 
  transmission, 6.7 seconds, 9% packet loss, BER: 0.0%
  M: 2019-06-10 00:00:34.722 DMR Slot 2, received network voice header 
  from N1GMB to TG 310
  M: 2019-06-10 00:00:35.197 DMR Talker Alias (Data Format 1, Received 
  6/10 char): 'TAC 31'
  M: 2019-06-10 00:00:35.197 DMR Slot 2, Embedded Talker Alias Header
  M: 2019-06-10 00:00:35.197 0000:  04 00 54 54 41 43 20 33 31                         
  *..TTAC 31*
  M: 2019-06-10 00:00:35.892 DMR Talker Alias (Data Format 1, Received 
  10/10 char): 'TAC 310 NC'
  M: 2019-06-10 00:00:35.892 DMR Slot 2, Embedded Talker Alias Block 1
  M: 2019-06-10 00:00:35.892 0000:  05 00 30 20 4E 43 00 00 00                         
  *..0 NC...*
  M: 2019-06-10 00:00:52.569 DMR Slot 2, received network end of voice 
  transmission, 18.2 seconds, 2% packet loss, BER: 0.0%
  M: 2019-06-10 00:00:53.700 DMR Slot 2, received network voice header 
  from K6FCC to TG 310
  M: 2019-06-10 00:00:53.851 DMR Slot 2, received network end of voice 
  transmission, 0.5 seconds, 0% packet loss, BER: 0.0%
  M: 2019-06-10 00:00:54.605 DMR Slot 2, received network voice header 
  from KC8QCH to TG 310
  M: 2019-06-10 00:00:56.168 DMR Slot 2, network watchdog has expired, 
  1.8 seconds, 80% packet loss, BER: 0.0%
  M: 2019-06-10 00:01:01.253 DMR Slot 2, received network voice header 
  from N1GMB to TG 310
  M: 2019-06-10 00:01:01.735 DMR Talker Alias (Data Format 1, Received 
  6/10 char): 'TAC 31'
  M: 2019-06-10 00:01:01.735 DMR Slot 2, Embedded Talker Alias Header
  M: 2019-06-10 00:01:01.735 0000:  04 00 54 54 41 43 20 33 31                         
  *..TTAC 31*
  M: 2019-06-10 00:01:02.426 DMR Talker Alias (Data Format 1, Received 
  10/10 char): 'TAC 310 NC'
  M: 2019-06-10 00:01:02.426 DMR Slot 2, Embedded Talker Alias Block 1
  M: 2019-06-10 00:01:02.426 0000:  05 00 30 20 4E 43 00 00 00                         
  *..0 NC...*
  M: 2019-06-10 00:01:06.507 DMR Slot 2, received network end of voice 
  transmission, 5.5 seconds, 1% packet loss, BER: 0.0%
  </code></pre>
  
  <p>Using the GAWK command cleanses it the above down content such as this:</p>
  
  <blockquote>
    <p>K6ASF,TG 310,3158238,0.5,0,0.0</p>
  </blockquote>
  
  <p>Does that help clarify?</p>