Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Dec 2004 16:00:08 +0200
From:      Peter Pentchev <roam@ringlet.net>
To:        Maxim Sobolev <sobomax@portaone.com>
Cc:        Matteo Riondato <rionda@gufi.org>
Subject:   Re: Creating Compressed Loop FS from stdin
Message-ID:  <20041230140007.GH830@straylight.m.ringlet.net>
In-Reply-To: <41D4036B.1060600@portaone.com>
References:  <1104358540.2895.10.camel@kaiser.sig11.org> <20041230103433.GB830@straylight.m.ringlet.net> <1104409708.6657.1.camel@kaiser.sig11.org> <20041230123116.GE830@straylight.m.ringlet.net> <41D4036B.1060600@portaone.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--82evfD9Ogz2JrdWZ
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Thu, Dec 30, 2004 at 03:32:27PM +0200, Maxim Sobolev wrote:
> Peter Pentchev wrote:
> >On Thu, Dec 30, 2004 at 01:28:28PM +0100, Matteo Riondato wrote:
> >
> >>Il giorno Gio, 30-12-2004 alle 12:34 +0200, Peter Pentchev ha scritto:
> >>
> >>>This could be fixed by the following patch.  I'm CC'ing Maxim Sobolev,
> >>>the author of mkuzip(8); Maxim, do you have any objections to this pat=
ch?
> >>
> >>Thank you for the answer and fo the patch! I hope Maxim will commit it
> >>soon.
> >
> >
> >Actually, if Maxim has no objections, I could commit it myself.
> >However, it would be totally understandable if he doesn't answer in
> >the next day or three, what with the calendar moving ahead and all :)
>=20
> It will not help, since AFAIK you can't seek stdin anyway, or even if I=
=20
> am wrong and you can seek it to the end you will be unable to seek it=20
> backward.

I tested the patch before posting it, fully expecting to find that stdin
really cannot be seeked (sought? :), and surprisingly it worked, at least
on RELENG_5 as of today!

> I've already replied to this message, but Matteo has some very strange=20
> settings of his smtp relay so that neither my original message nor my=20
> follow-up in which I had forwarded mail delivery error message got throug=
h.
>=20
> -Maxim
>=20
> -------- Original Message --------
> Subject: Re: Creating Compressed Loop FS from stdin
> Date: Fri, 17 Dec 2004 17:14:48 +0200
> From: Maxim Sobolev <sobomax@portaone.com>
> Organization: Porta Software Ltd
> To: Matteo Riondato <rionda@freesbie.org>
> References: <1103290915.8516.9.camel@kaiser.sig11.org>
>=20
> This is not going to work by design unfortunately. cloop format has
> serious design flaw: it contains variable-lengh header at the beginning
> of the compressed image, so that before doing compression mkuzip(1) uses
> stat(2) call at the original file to get its size and reserve necessary
> space, which doesn't work with /dev/stdin as you may guess. Original GNU
> utility either keeps the whole compressed image in memory or uses some
> form of temporary storage (I don't quite remember) to work around this
> problem.

Well, another solution would be to make mkuzip use a temporary file
(obviously, keeping the whole thing in memory would be a bad idea for
big ISO filesystems ;).  However, as I noted above, my lseek patch
works at least for RELENG_5.  Can somebody test it on -CURRENT?

G'luck,
Peter

--=20
Peter Pentchev	roam@ringlet.net    roam@cnsys.bg    roam@FreeBSD.org
PGP key:	http://people.FreeBSD.org/~roam/roam.key.asc
Key fingerprint	FDBA FD79 C26F 3C51 C95E  DF9E ED18 B68D 1619 4553
This inert sentence is my body, but my soul is alive, dancing in the sparks=
 of your brain.

--82evfD9Ogz2JrdWZ
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (FreeBSD)

iD8DBQFB1Ann7Ri2jRYZRVMRAp8iAJ9guDPyhybLrdP/UaBmAioq8+PiFACfRxdU
zS4zglsQT5rHFfPWP45HaMo=
=IkSk
-----END PGP SIGNATURE-----

--82evfD9Ogz2JrdWZ--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041230140007.GH830>