Skip site navigation (1)Skip section navigation (2)
Date:      21 Apr 2002 15:16:56 -0700
From:      Ken McGlothlen <mcglk@artlogix.com>
To:        Mark Filipak <filipak@earthlink.net>
Cc:        freebsd-questions <freebsd-questions@freebsd.org>
Subject:   Re: Mark asks: Easy way to copy CD-ROM > MS-floppy?
Message-ID:  <87it6ku27b.fsf@ralf.artlogix.com>
In-Reply-To: <3CC3349F.477E899F@earthlink.net>
References:  <3CC0CAE5.A8A56319@earthlink.net> <877kn1ptad.fsf@ralf.artlogix.com> <3CC26E9E.1F131018@earthlink.net> <87u1q4rfw0.fsf@ralf.artlogix.com> <3CC3349F.477E899F@earthlink.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Mark Filipak <filipak@earthlink.net> writes:

| > I do!
| >         # split -b 1474560 s_apache.tar.gz s_apache.tar.gz.
| 
| Giorgos Keramidas kindly wrote:
| >         # split -b 1400k s_apache.tar.gz
| 
| Hmmm... would that be 1,400,000 bytes or 1,433,600 bytes? -- How does FBSD
| do the math? No matter... (read on before jumpping on the 'reply' button)
| 
| Perhaps Giorgos and Ken can fight this out between themselves and give me
| a consistent way to do this.  Ken's suggestion seems a little redundant
| regarding arguments.

Not at all, though it could easily be seen as so.  Remember that Unix often
provides more than one way to do things (with apologies to Perl hackers), often
of equal relevance.

First off, for what it's worth, I took the "1474560" from the dd output you
provided; that's exactly 1440 KiB.  Giorgos took a more conservative approach,
and provided a 1400 KiB output (or, if you like, 1433600 bytes).  Either one
will work; mine *might* save you a floppy, but that's not guaranteed.  But you
could have used "-b 1440k" instead of "-b 1474560" for an equivalent result.

As far as the "redundant" argument, you should know that this:

        split -b 1440k s_apache.tar.gz

will result in a number of files named

        xaa
        xab
        xac

and so on.  That "redundant" argument defaults to "x" if you don't supply one;
by using

        split -b 1440k s_apache.tar.gz s_apache.tar.gz.

(and note the period at the end of that last argument) you get

        s_apache.tar.gz.aa
        s_apache.tar.gz.ab
        s_apache.tar.gz.ac

and so on.  The results are a little more self-evident as a result.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




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