Wait Events

Ein Merkzettel für Wait Events, zu denen mir Erläuterungen begegnen, die ich für erinnerungswürdig erachte. Natürlich einmal mehr ohne jeden Anspruch auf Vollständigkeit.

Eine recht umfassende Sammlung von Informationen zu diversen Wait Events findet man bei Kyle Hailey.
  • db file sequential read
    • Event für Einzelblockzugriffe, in der Regel im Zusammenhang mit Index Scans.
    • Frits Hoogland dokumentiert einige zur Implementierung unter Linux und erklärt: "Because of the inherent single block IO nature of db file sequential read, every physical read (when it needs to read from a physical disk device) takes the IO latency penalty. Even with solid state disk devices, which have an inherently lower latency time because there are no rotating parts and disk heads to be moved, chopping up an operation in tiny parts when a full table scan or fast full index scan could be done means a lot of CPU time is used whilst it could be done more efficient."
  • log file sync
    • "When a transaction commits it will usually wait for its redo data to be recorded on disk before returning control to the application. That wait is LFS. There are three main exceptions to this:
      • When the commit is issued within a PL/SQL block. In this case the wait will be deferred until the block returns. If the PL/SQL block contains multiple commit statements then only one wait will occur when the block returns.
      • When the commit statement is actually COMMIT WORK NOWAIT. In this case, there is no LFS wait. See part 3 in this series for an explanation of why this is dangerous.
      •  When the session parameter COMMIT_WAIT (COMMIT_WRITE in earlier releases) is set to NOWAIT. This parameter can be set at the instance level but this is dangerous practice and should be set at the session level only with care. See part 3 in this series for an explanation of why this is dangerous." - Tony Hasler
  • log file parallel write
    • LGWR is the only process that waits on this event, and it is the actual I/O (and associated setup) that stamps the redo buffer information onto disk.
    • die redo Informationen mehrerer Sessions, die auf eine Bearbeitung durch den LGWR warten, können zusammengefasst verarbeitet werden (group oder piggyback commit): "If a second session issues a commit while the LGWR is busy writing the redo for the first session, it too will wait on log file sync." - James Morle
    • die Durchschnittswerte der Events log file sync und inbesondere log file parallel write sollte man aufgrund dieser Zusammenfassung mit Vorsicht betrachten: einzelne Outlier können die Angaben massiv verziehen. Hilfreicher sind in diesem Zusammenhang Histogramme (um zu bestimmen, ob es ein I/O-Problem beim Logging gibt). - Nicolay Savvinov
    • rdbms ipc message
      • "a process is waiting for an IPC message to arrive. Usually, this wait event can be ignored, but there are few rare scenarios this wait event can’t be completely ignored."
      • Die seltenen Fälle, in denen das Event nicht ignoriert werden kann, erläutert Riyaj Shamsudeen in seinem Blog.

    Keine Kommentare:

    Kommentar veröffentlichen