Change the database-logging mode

You can use ondblog or ontape to add or change logging. Then use ON-Bar, or ontape to back up the data. When you use ON-Bar or ontape, the database server must be in online, administration, or quiescent mode.

For information about ON-Bar and ontape, see the IBM® Informix® Backup and Restore Guide.

The following table shows how the database server administrator can change the database-logging mode. Certain logging mode changes take place immediately, while other changes require a level-0 backup.
Table 1. Logging mode transitions
Converting from: Converting to no logging Converting to unbuffered logging Converting to buffered logging Converting to ANSI compliant
No logging Not applicable Level-0 backup (of affected storage spaces) Level-0 backup (of affected storage spaces) Level-0 backup (of affected storage spaces)
Unbuffered logging Yes Not applicable Yes Yes
Buffered logging Yes Yes Not applicable Yes
ANSI compliant Illegal Illegal Illegal Not applicable
Changing the database-logging mode has the following effects:
  • While the logging status is being changed, the database server places an exclusive lock on the database to prevent other users from accessing the database, and frees the lock when the change is complete.
  • If a failure occurs during a logging-mode change, check the logging mode in the flags in the sysdatabases table in the sysmaster database, after you restore the database server data. For more information, see Monitor the logging mode of a database. Then try the logging-mode change again.
  • After you choose either buffered or unbuffered logging, an application can use the SQL statement SET LOG to change from one logging mode to the other. This change lasts for the duration of the session. For information about SET LOG, see the IBM Informix Guide to SQL: Syntax.
  • If you add logging to a database, the change is not complete until the next level-0 backup of all the storage spaces for the database.

Copyright© 2018 HCL Technologies Limited