Re:GBAK fails when scheduled in NT task scheduler
Okay -- I think I got it working. Thanks for everyones help. Here is what
I ended up with:
Of course the > on the GFIX lines don't result in output, and there is no -y
command so I
am hopefull the gfix is working.. This will run around midnight to do
database backups
and maintenance. This was requested by my product vendor, who hasn't used
version
6.5 yet - so I question if this needs done. I have OFA from Veritas and I
have read
that the 6.5 version has resolved the issues where prior versions required
this once
in a while.
------------------------------------------------------
d:
cd "\Progra~1\Borland\InterBase\bin\"
net stop InterBaseGuardian >> d:\risk\ed.txt
net stop InterBaseServer >> d:\risk\ed.txt
net start InterBaseGuardian >> d:\risk\ed.txt
del D:\risk\risklog1.txt
del D:\risk\risklog2.txt
del D:\risk\servicelog1.txt
del D:\risk\servicelog2.txt
del d:\risk\*.gbk
d:\Progra~1\Borland\InterBase\bin\gfix -sh -force 0
ntfs4:d:\risk\risks.gdb -user "sysdba" -pass "mypassword" >
d:\risk\risklog0.txt
copy d:\risk\Risks.gdb d:\risk\Risks.sav > d:\risk\riskscopy.log
d:\Progra~1\Borland\InterBase\bin\gbak -B -b -v ntfs4:d:\risk\risks.gdb
d:\risk\risks.gbk -user "sysdba" -pass "mypassword" -y D:\risk\risklog1.txt
d:\Progra~1\Borland\InterBase\bin\gbak -R -r -p 8192 -v d:\risk\Risks.gbk
ntfs4:d:\risk\Risks.gdb -user "sysdba" -pass "mypassword" -y
D:\risk\risklog2.txt
d:\Progra~1\Borland\InterBase\bin\gfix -o ntfs4:d:\risk\Risks.gdb -user
"sysdba" -password "mypassword" > d:\risk\risklog3.txt
d:\Progra~1\Borland\InterBase\bin\gfix -sh -force 0
ntfs4:d:\risk\service.gdb -user "sysdba" -pass "mypassword" >
d:\risk\servicelog0.txt
copy d:\risk\service.gdb d:\risk\service.sav > d:\risk\servicecopy.log
d:\Progra~1\Borland\InterBase\bin\gbak -B -b -v ntfs4:d:\risk\service.gdb
d:\risk\service.gbk -user "sysdba" -pass "mypassword" -y
D:\risk\servicelog1.txt
d:\Progra~1\Borland\InterBase\bin\gbak -R -r -p 8192 -v d:\risk\service.gbk
ntfs4:d:\risk\service.gdb -user "sysdba" -pass "mypassword" -y
D:\risk\servicelog2.txt
d:\Progra~1\Borland\InterBase\bin\gfix -o ntfs4:d:\risk\service.gdb -user
"sysdba" -password "mypassword" > d:\risk\servicelog3.txt
exit