Re: Copying an informix database with "cp"
Posted in 1992
Helge Egelund Rasmussen writes:
> I want to take a copy a informix database, so that the users can get
> access to both the old and the new copy by setting DBPATH.
>
> Is it ok to use cp to copy the database files to another directory,
> or does the db files contain absolute pathnames?
If the database is logged, systables contains the absolute path to
the log file. For example,
create database foobar with log in "/u2/theskett/foobar2";
strings foobar.dbs/systables.dat | grep syslog
gets me:
syslog theskett/u2/theskett/foobar2
If you're not logging, no problem. If you are, you can patch
systables with emacs (!!), or just do a
start database foobar with log in "/bar/foo";
or equiv. to get the copy to use a different log file. You have
to have the log file there to be able to bring up isql, BTW.
> Is there a better way to copy the database?
You could be polite and do an unload/reload, but I've had complete
success with this (and ftp between architectures !), so suggest
you go right ahead. Might make sure no-ones using it before you
start the cp, tho'.
> Helge E. Rasmussen . PHONE + 45 36 72 33 00 . E-mail: her@compel.dk
> Compel A/S . FAX + 45 36 72 43 00 .
> Copenhagen, Denmark
Hope this helps. How's Copenhagen these days ?
Cheers - Tony.
__________________________________________________________________________
Tony Heskett th@bnr.co.uk Voice: (+44) 279 402637
BNR, London Road, Harlow, Essex CM17 9NA Fax: (+44) 279 451434