linux - Is there a way to flush stdout of a running process -


i have long-running process stdout redirected file. e.g.:

./my-script.sh > file.txt & 

part of stdout still cached, flush file, see results earlier. there way it?

the caching handled libc. can use stdbuf command change buffer size:

stdbuf -o0 ./my-script.sh > file.txt & 

-o0 sets buffer size stdout 0. want -e0 stderr.


Comments

Popular posts from this blog

node.js - Using Node without global install -

How to access a php class file from PHPFox framework into javascript code written in simple HTML file? -

java - Null response to php query in android, even though php works properly -