parsed.org
FIFOs Are Great by xinu on Jan 12, 2005 10:52 AM

If you want to tail the errors on another terminal, just push them to a fifo:

$ mkfifo pgerror
$ psql -U user dbname < ./dbfile 2> pgerror

On your other terminal:

$ tail -f pgerror

Voila! STDOUT on the main terminal, and STDERR on the secondary.

commandserrorsmkfifopipepsqlredirectshelltailterminal
RSS