bash strerr pipe problem - workaround ?

dave selby dave6502 at
Sat Jun 14 08:16:25 UTC 2008

Hi all,

I have a app that outputs to stderr, what I need is a filtered version
to be saved in a file

 motion -c %s/core/motion_conf/motion.conf 2> saved

works as expected but is unfiltered. So to filter it I am trying ...

 motion -c %s/core/motion_conf/motion.conf | grep -E 'error|not found' > saved

and I get zip. I am thinking because stderr gets dumped to screen and
not processed by the pipe

motion is continuously running so I cannot use motion -c
%s/core/motion_conf/motion.conf 2> saved
then filter the output, it has to be an ongoing process.

Any ideas how to get around this ?



Please avoid sending me Word or PowerPoint attachments.

More information about the ubuntu-users mailing list