No, it's me. I didn't interpret [FILE]... as more than one file. My bad. I think this will handle what I want to do. Many thanks!
-- John McKown Systems Engineer IV IT Administrative Services Group HealthMarkets(r) 9151 Boulevard 26 * N. Richland Hills * TX 76010 (817) 255-3225 phone * john.mck...@healthmarkets.com * www.HealthMarkets.com Confidentiality Notice: This e-mail message may contain confidential or proprietary information. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. HealthMarkets(r) is the brand name for products underwritten and issued by the insurance subsidiaries of HealthMarkets, Inc. -The Chesapeake Life Insurance Company(r), Mid-West National Life Insurance Company of TennesseeSM and The MEGA Life and Health Insurance Company.SM > -----Original Message----- > From: Linux on 390 Port [mailto:LINUX-390@VM.MARIST.EDU] On > Behalf Of Larry Ploetz > Sent: Wednesday, February 09, 2011 2:48 PM > To: LINUX-390@VM.MARIST.EDU > Subject: Re: BASH question - may even be advanced - pipe > stdout to 2 or more processes. > > On 2/9/11 12:40 PM, McKown, John wrote: > > tee can output to multiple files? The man page implies only > a single file. > > Hmmm...maybe you need a new enough tee also: > > SYNOPSIS > tee [OPTION]... [FILE]... > > DESCRIPTION > Copy standard input to each FILE, and also to standard output. > > > > So I guess I could: > > > > bzcat data*bz2| tee >(perl script1.pl|psql database)|perl > script2.pl|psql database > > > > bzcat data*bz2| tee >(perl script1.pl|psql database)|tee > >(pers script2.pl|psql database)|perl script3.pl|psql databaselin > > Yep, those should work also. The named pipe would work too, > if you did something like: > > mkfifo p1 p2 p3 > > bzcat data*bz2 | tee p1 | tee p2 > p3 & > > perl script1.pl < p1 > perl script2.pl < p2 > perl script3.pl < p3 > > (make sure and background or run in another terminal the bzcat.) > > for the 2 case. I also guess that I might be able to > cascade tee processes. But that's getting nasty, too. > > > > -- > > John McKown > > Systems Engineer IV > > IT > > - Larry > > ---------------------------------------------------------------------- > For LINUX-390 subscribe / signoff / archive access instructions, > send email to lists...@vm.marist.edu with the message: INFO > LINUX-390 or visit > http://www.marist.edu/htbin/wlvindex?LINUX-390 > ---------------------------------------------------------------------- > For more information on Linux on System z, visit > http://wiki.linuxvm.org/ > > ---------------------------------------------------------------------- For LINUX-390 subscribe / signoff / archive access instructions, send email to lists...@vm.marist.edu with the message: INFO LINUX-390 or visit http://www.marist.edu/htbin/wlvindex?LINUX-390 ---------------------------------------------------------------------- For more information on Linux on System z, visit http://wiki.linuxvm.org/