Linux Today: Linux News On Internet Time.
Search Linux Today
Linux News Sections:  Blog -  Developer -  High Performance -  Infrastructure -  IT Management -  Security -  Storage -
Linux Today Navigation
LT Home
Preferences
Contribute
Link to Us
Search
Linux Jobs

Linux Today
Enterprise Linux Today
Apache Today
JustLinux.com
Linux Planet
PHPBuilder
All Linux Devices
Technology Jobs

JustTechJobs.com

LinuxToday Newsletters
Server Daily
IT Management Daily
Subscribe News
Subscribe PR
Subscribe Security

internet.com
Internet News
Small Business

Advertise
Newsletters
Tech Jobs
E-mail Offers

 






Current Newswire:

Linux Top 5: Linux's New Fellow

RebeccaBlackOS - First Live CD Running Wayland Display Server

The Linux powered LAN Gaming House

5 Best Android Apps For Reddit Lovers

SECURITY: Flash Player Sandbox Comes to Firefox

The Future of Kubuntu

SECURITY: Symantec should not be afraid of 'open' source code

Linux 3.3 rc3

60 Fantastic Free Android Apps

Ready for Another Linux Tablet? Meet the Rugged Trimble Yuma



Applications Management Engineer Sr (NYC)
Next Step Systems
US-NY-New York

Justtechjobs.com Post A Job | Post A Resume
:Speaking UNIX: Peering into pipes
Speaking UNIX: Peering into pipes
Nov 4, 2009, 15 :03 UTC (0 Talkback[s]) (4022 reads)

(Other stories by Martin Streicher)

[ Thanks to An Anonymous Reader for this link. ]

"One of the cleverest and most powerful innovations in UNIX is the shell. It's more efficient than a GUI, and you can write scripts to automate many tasks. Better yet, the pipe operator assembles ad hoc programs right at the command line. The pipe chains commands in sequence, where the output of an earlier command becomes the input of a subsequent command.

"But the pipe has one major detractor: It's something of a black box. If you string commands together, the only evidence of progress is the output that the last command in the series generates. Yes, you can interject tee in the sequence, and you can watch an output file grow with tail, but those solutions work best once, lest the standard output (stdout) and standard error (stderr) of multiple phases commingle. Further, both solutions are crude indicators and likely mask how much computation each step requires.

"Of course, you could deconstruct a complex sequence into multiple individual steps, each with its own interim output file. And indeed, if you want to verify results at each interval, decomposition is ideal. Write a script, produce one data file for each step, use a data file between each pair of steps as input, and collect the final file as the ultimate result. However, such a practice is not well suited to the impromptu nature of the command line.

"What's needed is a progress meter that you can embed in the command line to measure throughput. Ideally, the meter could be repeated to benchmark each step—and because the sky's the limit, the tool would be open source and portable to multiple UNIX variants, such as Linux® and Mac OS X."

Complete Story

Related Stories:
Getting comfortable with Linux plumbing(Oct 16, 2009)
Reading Multiple Files with Bash(Aug 22, 2009)
Names Pipes... or how to get two separate applications to interact(Jun 30, 2009)
Exploring filters and pipes(Apr 02, 2009)
Chaining Linux Commands Together(Feb 03, 2009)
pv (Pipe Viewer) - Shell pipeline element to meter data passing through(Dec 30, 2008)



No talkbacks posted.
  Home | Search Talkbacks | Customize View    Top of Page  



Enter your comments below:

* Your Name:

* Your Email Address:

* Subject:

CC: [will also send this talkback to an E-Mail address]

* Comments:

Tags allowed:<I>,<B> and <U>. See our talkback-policy for more about talkback content.

Fields marked with * are required!

..............................




All times are recorded in UTC.
Linux is a trademark of Linus Torvalds.
Powered by Linux, Apache and PHP