IBM 000-8697 Manual Do Utilizador

Página de 702
2-32
IBM Informix OnLine Database Server Administrator’s Guide
Orphaned Database Server Processes
Never kill an OnLine database server process with the UNIX
kill -9
command. If
you execute the
kill -9
command and generate a
SIGKILL
signal while that
server process is holding a latch or is in a critical section of a transaction,
OnLine aborts with an immediate shutdown to preserve data consistency.
Never kill an application tool process with a
SIGKILL
 signal. An application tool
process can, on occasion, get the attention of the database server process by
sending a signal that the server process can trap. The only signal that the
server process cannot trap is the
SIGKILL
signal. Therefore, there is no reason
for an administrator to use the
SIGKILL
 signal to terminate application
processes. When you kill an application process with
 kill -9
, you can
create an orphaned database server process.
If you suspect a database server process has been orphaned, follow these
steps to verify that the process is not doing any database work before you
attempt to kill it:
1.
Obtain the database server process identification (pid) number from
tbstat -u
 output.
2.
Check that the process is not in a critical section. Look at the third-
position flag of the tbstat -u output. If the process flag is X, do not kill
the process; if you do, OnLine aborts with an immediate shutdown.
3.
Check that the process is not holding a latch. Obtain the address of
the process from the tbstat -u output. Execute tbstat -s to look at a
summary of latch information. Verify that the address of this process
is not listed as the owner of any latch. If the process address is
associated with a latch, do not kill the process; if you do, OnLine
aborts with an immediate shutdown.
4.
If the server process is not in a critical section and is not holding a
latch, user informix or root can kill the process with the command
tbmode -z pid
.
Do not kill a database server process that is in a critical section or is holding
a latch; if you do, OnLine initiates an abort. Instead, wait until the server
process has exited the section or released the latch.
If the server process does not exit the section or release the latch, user
informix
 or root can execute tbmode -k to detach all processes from shared
memory and take OnLine to offline mode.