Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FORCE APPLICATION

Status
Not open for further replies.

kozlow

MIS
Mar 3, 2003
326
US
When running a FORCE APPLICATION, I receive the following message in return:

DB20000I The FORCE APPLICATION command completed successfully.
DB21024I This command is asynchronous and may not be effective immediately.

I was wondering if it waits until all current transaction complete or if it rolls them back.

Some of our offline backups have been receiving the follow error:
SQL1035N The database is currently in use. SQLSTATE=57019

I was thinking of runnig a loop until the "LIST APPLICATIONS" comes up Null......

Any suggestions would be appriciated...

Thanks in advance....
 
Paraphrasing the manual...
Asynchronous mode means that FORCE APPLICATION does not wait until all specified users are terminated before returning. It returns as soon as the API has been issued successfully, or an error occurs. As a result, there may be a short interval between the time the FORCE APPLICATION call completes and the specified users have been terminated.

To preserve database integrity, only users who are idling or executing interruptible database operations can be terminated.

When a user is terminated, a ROLLBACK is performed to ensure database consistency.

Our scenario allows us to do online backups.
 
I already had a sleep in my script and recieved the following suggestion for running my backups...

force application
terminate

backup

db2stop
db2start

Will be trying it this weekend....

thanks for the information....
Koz
 
Hi!

Try to do that:

db2stop force
db2start
db2 backup database .....

This works for me!!

Bye
 
Another thing why the offline backup is giving you this error "SQL1035N The database is currently in use. SQLSTATE=57019" is because the database was active.
I'll recommend thess steps:
1) Db2 "force application all"
2) db2 deactivate db <db_name>
3) db2 list application... to check if there is/are connected to the database.
4) db2 &quot;backup db <db_name> ,,,,

Thank you
And good luck
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top