Tee and file redirections are very slow to write anything.
Hamish McIntyre-Bhatty
hamishmb@live.co.uk
Wed Feb 24 20:33:45 GMT 2021
Hi there,
I found recently when trying to save output from a script for later
inspection that "tee" and file redirections seem to have massive delays
when run in Cygwin - usually nothing is written to file or stdout until
after the command has finished - not very helpful.
I'm running a bash script with the following cmdlines:
"bash ./path/to/script.sh > stdout.log"
and:
"bash ./path/to/script.sh | tee stdout.log"
Both of them result in no writes to the file (or stdout in the second
case) until the command is finished, and as this script takes minutes to
run, it's not very helpful. I'm running these commands from bash in Mintty.
Is there any configuration I need to do, or have I potentially
discovered a bug? IIRC there have been some changes in the dev version
of Cygwin relating to file I/O so perhaps this is already fixed?
Hamish
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_0x18F1759B3457223F.asc
Type: application/pgp-keys
Size: 3131 bytes
Desc: not available
URL: <https://cygwin.com/pipermail/cygwin/attachments/20210224/34329f66/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <https://cygwin.com/pipermail/cygwin/attachments/20210224/34329f66/attachment.sig>
More information about the Cygwin
mailing list