[Seattle-SAGE] Redirect stderr and stdout?
Atom Powers
atom.powers at gmail.com
Fri Jan 20 09:29:44 PST 2006
I'm trying to write a script that tests how long it takes to list the
shares on a samba server and prints the result to stdout. But I don't
want a list of all the shares, which smbclient normally sends to
stdout.
So far I have:
$ /usr/bin/time -h `which smbclient` -N -L ${server} 1> /dev/null
Problem is: the time outuput goes into stderr and I need it to go to
stdout; if I "2>1" then it goes into /dev/null. Smbclient outputs a
lot of data to stdout that I don't want (the list of shares).
Any ideas?
--
--
Perfection is just a word I use occasionally with mustard.
--Atom Powers--
More information about the Members
mailing list