Firebird Documentation IndexFirebird 2.0.6 Release NotesCommand-line Utilities → gfix Server Utility
Firebird Home Firebird Home Prev: gsec Authentication ManagerFirebird Documentation IndexUp: Command-line UtilitiesNext: External Functions (UDFs)

gfix Server Utility

New Shutdown States (Modes)

Changes to the gfix utility include:

New Shutdown States (Modes)

N. Samofatov, D. Yemanov

The options for gfix -shut[down] have been extended to include two extra states or modes to govern the shutdown.

New Syntax Pattern

      gfix <command> [<state>] [<options>]

  <command> ::= {-shut | -online}
  <state> ::= {normal | multi | single | full}
  <options> ::= {[-force | -tran | -attach] <timeout>}
        

- “normal” state = online database

- “multi” state = multi-user shutdown mode (the legacy one, unlimited attachments of SYSDBA/owner are allowed)

- “single” state = single-user shutdown (only one attachment is allowed, used by the restore process)

- “full” state = full/exclusive shutdown (no attachments are allowed)

Note

Multi” is the default state for -shut, “normal” is the default state for -online.

The modes can be switched sequentially:

normal <-> multi <-> single <-> full

Examples

  gfix -shut single -force 0
  gfix -shut full -force 0
  gfix -online single
  gfix -online
        

You cannot use -shut to bring a database one level “more online” and you cannot use -online to make a database more protected (an error will be thrown).

For example, these sequence-pairs are prohibited:

  gfix -shut single -force 0
  gfix -shut multi -force 0
::
  gfix -online
  gfix -online full
::
  gfix -shut -force 0
  gfix -online single
        

Timeout

As before, the timeout is in seconds. In the case of the -attach and -tran timeouts, the timeout determines how long the engine will wait for any attached clients to complete their work and log off. The shutdown request should return the SQLCode -902 message shutfail (ISC code 335544557), “Database shutdown unsuccessful” if there are still active attachments when the timeout expires.

However, there is a known issue with the implementation of the new modes. A regression occurred, whereby the said message is returned but the engine does not revert the database to the online state, as it should. It affects all versions of Firebird up to and including v.2.0.5 and v.2.1.3, and all v.2.5 alphas, betas and release candidates.

Prev: gsec Authentication ManagerFirebird Documentation IndexUp: Command-line UtilitiesNext: External Functions (UDFs)
Firebird Documentation IndexFirebird 2.0.6 Release NotesCommand-line Utilities → gfix Server Utility