On Fri, 2 Nov 2001, David Douthitt wrote:

> "Michael D. Schleif" wrote:
> 
> > root@trout:/var/log
> > # svi ramdisk.pkg start
> > ramdisk.pkg: Uncompressing archives - log.tgz/etc/init.d/ramdisk.pkg:
> > line 33: 22910 Broken pipe             gunzip -c "$pkgdir/$pkg"
> >      22911 Done                    | qt tar -x
> >  - Finished.
> 
> My understanding was that "broken pipe" meant that a pipe "source" (if
> you will) sort of fell off the planet.  I've seen this error, for
> instance, in
> 
> somecmd | less
> 
> ...when you use ^C to quit somecmd or quit less early - at least, that's
> what my SwissCheese memory tells me :-)
> 
> Is that about right?  Would be interesting to know the Real Reason that
> error comes about...

On a Linux workstation,

   man 7 signal

says (among other things):

   SIGPIPE   13  A  Broken pipe: write to pipe with no readers

where 13 is the integer value of SIGPIPE, and "A" means the default action
is to terminate the process.

>From this I gather that anything that causes the consumer to close the
pipe before the producer finishes will result in this signal.  The general
consensus at http://www.lcg.org/sock-faq/ seems to be that the programmer
of the producer can (ought to?) ignore the signal and pay attention to the
success code from write calls.  Depending on purpose of the program, I
think this may not be much more useful than the default response.

In the case of ramdisk.pkg above, I would think this means the output of
gunzip is not making tar happy, so tar is quitting, and gunzip is
reporting that it cannot proceed.  I don't have ramdisk.pkg, but it sounds
like something is corrupt either in the selection of the value of
"$pkgdir/$pkg" (wrong file) or in the contents of a rightly chosen file.  
The "qt" is preventing any error messages generated by tar from being
displayed.  Temporarily getting rid of the "qt" could allow further
debugging.

---------------------------------------------------------------------------
Jeff Newmiller                        The     .....       .....  Go Live...
DCN:<[EMAIL PROTECTED]>        Basics: ##.#.       ##.#.  Live Go...
                                      Live:   OO#.. Dead: OO#..  Playing
Research Engineer (Solar/Batteries            O.O#.       #.O#.  with
/Software/Embedded Controllers)               .OO#.       .OO#.  rocks...2k
---------------------------------------------------------------------------


_______________________________________________
Leaf-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/leaf-devel

Reply via email to