rbraun@spdcc.COM (Rich Braun) (03/10/91)
This is a related question, regarding cpio under SCO and AIX: How do I read tapes across two machines with byte-swapped architectures? If I create a tape (or disk archive) with cpio under SCO, and another under AIX, then swap the two tapes, neither machine can read the other's format. If I "od" the tape dump, I see that the header bytes seem to be swapped for each 16-bit short word. The -s, -S, and -b byte-swapping options to cpio seem to have no effect on either system; I still get "bad magic number" complaints. I haven't tried -c, to store file headers in ASCII mode rather than binary mode. It just ought to work; indeed it annoys me that any software/hardware developer would create a machine architecture-dependent tape archive format. How do I write tapes which are compatible between SCO and AIX (on the RS-6000)? Obviously, 'tar' will do the trick, but 'cpio' has more error recovery logic. Another question: how do I write multiple cpio archives to a single tape? My AIX system doesn't seem to have the no-rewind device defined (and I can't find this item in the documentation), and SCO Unix doesn't seem to provide decent end-of-tape error handling. You have to tell cpio how large your tape is, in kilobytes, which won't work correctly if you try to write multiple archives to one tape. Also, because there seems to be no way to "seek to the beginning of the current archive"-- it seems you have to rewind the tape and skip over the archives, an exceptionally slow process--I'm beginning to believe that I ought to just punt the idea of storing more than one archive per tape. Finally, how does one write to low-density media on a high-density Mountain drive under SCO Unix? I have some old DC-300 tapes which I can't seem to use at all. Thanks for the help. -rich
tim@dell.co.uk (Tim Wright) (03/11/91)
In <6806@spdcc.SPDCC.COM> rbraun@spdcc.COM (Rich Braun) writes: >This is a related question, regarding cpio under SCO and AIX: > How do I read tapes across two machines with byte-swapped > architectures? >If I create a tape (or disk archive) with cpio under SCO, and another >under AIX, then swap the two tapes, neither machine can read the other's >format. If I "od" the tape dump, I see that the header bytes seem to >be swapped for each 16-bit short word. Try $ dd if=your_tape_dev bs=20b conv=swab | cpio ... That will swap alternate bytes. I agree that the -c option ought to work. I'm fairly sure I've transferred between a SUN 3 and Sys V/386 (different byte order), so is cpio under AIX broken ? Does AIX use the extended cpio headers (a la SVR4), if so you would need to add '-H odc' to force it to write compatible headers. Tim -- Tim Wright, Dell Computer Corp., Bracknell | Domain: tim@dell.co.uk Berkshire, UK, RG12 1RW. Tel: +44-344-860456 | Uucp: ...!ukc!delluk!tim Nobody ever said I was charming before. They said, "Rimmer, you're a total git" - Red Dwarf, "Camille".
wcr@tree.tree.metrolink.com (W.c. Rothanburg) (03/12/91)
In article <6806@spdcc.SPDCC.COM> rbraun@spdcc.COM (Rich Braun) writes:
This is a related question, regarding cpio under SCO and AIX:
How do I read tapes across two machines with byte-swapped
architectures?
I've successfully done this with tapes only (not diskettes) between
ISC, and AIX. With the CPIO files, you need to make the tape with
the -c option to make the tapes compatible. The tar files should
work un-modified.
As far as diskettes, I've only been able to do it with DOS files.
I use vpix (faster than dossette or mounting the diskette) and
copy the files to the diskette. On the aix side, I just use dosread
and doswrite as necessary. (I don't have a tape drive on my
home system, so I use this more...)
Another question: how do I write multiple cpio archives to a single
tape? My AIX system doesn't seem to have the no-rewind device defined
(and I can't find this item in the documentation), and SCO Unix doesn't
seem to provide decent end-of-tape error handling. You have to tell
cpio how large your tape is, in kilobytes, which won't work correctly if
you try to write multiple archives to one tape. Also, because there
seems to be no way to "seek to the beginning of the current archive"--
it seems you have to rewind the tape and skip over the archives, an
exceptionally slow process--I'm beginning to believe that I ought to just
punt the idea of storing more than one archive per tape.
On AIX, the no-rewind setting is /dev/rmt?.1. Also, tctl (I beleive
is the name of the program) will allow you to perform tape functions,
including forward spacing files. Look in the files reference or
infoexplorer for all of the /dev/rmt* options. There are 4 per
density.
Bill
--
Who : Metro Link, Inc.
What : X11.R4. for ISC Unix 386/ix, SCO Unix/386, and Everex ESIX
Where: 2213 West Mc Nab Road, Pompano Beach,FL 33069
Sales: sales@metrolink.com
Email: wcr@metrolink.com
Phone: +1 305 970 7353 x927
Fax : +1 305 970 7351