RE: cpio problem
Posted in 1998
>----------
From: Abhay Mannur[SMTP:abhay@cheerful.com]
>Sent: Wednesday, March 04, 1998 6:55 AM
>We have exported a database to a tape.
>How can I edit the schema file before I import it.
You can't. Do not ever allow dbimport to write the schema file (SQL file) to the tape; always
use the -f option to ensure that the schema is stored separately. Amongst other things,
the format on the tape has the schema information distributed in amongst the data information.
The only time it is legitimate to let dbexport write the schema to tape too is when you will
never need to change the schema on import. This might apply if you are using dbexport
as an archive mechanism. But for ordinary use, ensure that the SQL file is written to disk,
even if the data isn't. And, if you've got enough disk space (a BIG 'if' these days), then
dbexport to disk and then write to tape is easiest.
>I tried cpio to copy the whole tape on the disk but it is giving me
'>Out of Phase' error. What should be the cpio command to extract
>everything on disk.
The format on the tape is *NOT* cpio format. It is dbexport/dbimport format.
If you write the tape from a dbexport to disk, then it will be in cpio format (or tar,
or pax, or whatever you used to create the tape).
If you let dbimport write the tape, it is in its own proprietary (and undocumented) format.
Yours,
Jonathan Leffler (jleffler@visa.com)
#include <bother.ms-exchange.h>
#include <do-not-do-it.h>