Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Morning all
I'm running the following script to export an informix database:-
INFORMIXDIR=/usr/informix export INFORMIXDIR
INFORMIXSERVER=ONLINELIVE
ONCONFIG=onconfig.live
PATH=$PATH:$INFORMIXDIR/bin
export INFORMIXSERVER ONCONFIG PATH /usr/informix/bin/dbexport dbname -c -o /scratch/schema
I get the following error messages
-425 - Database is currently opened by another user.
-107 - ISAM error: record is locked.
and sometimes
Cannot create message file
In respect of the firsterror, I am now aware of the need for
exclusivity in order for the dbexport command to run. Does anybody
have any additional code that I can incorporate into the above script
to facilitate this?
Any ideas on the second?
Many thanks
Gary Cobden
the dbexport.out file may be owned by a different user
and you do not have permissions to overwrite it...
the otherone ... as user informix!!!!
dbaccess sysmaster <<!
output to sids without headings
select distinct (a.owner) from syslocks a, sysdatabases b
where a.rowidlk = b.rowid
and b.name = <name of your db>!
for i in `cat sids`
do
onmode -z $idone
.... YOURSTUFF
this is NOT bullitproof!!!!!!!
you even may see a btcleaner show up having a open lock on
the db...
Superboer.
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.