use thraeding for tee, eliminate `tee: input/output error` messages