Skip to main content
Certain notable events are reported using a structured format. Commonly, these notable events are also copied to the table system.eventlog, unless the cluster setting server.eventlog.enabled is unset. Additionally, notable events are copied to specific external logging channels in log messages, where they can be collected for further processing. The sections below document the possible notable event types in this version of CockroachDB. For each event type, a table documents the possible fields. A field may be omitted from an event if its value is empty or zero. A field is also considered “Sensitive” if it may contain application-specific information or personally identifiable information (PII). In that case, the copy of the event sent to the external logging channel will contain redaction markers in a format that is compatible with the redaction facilities in and , provided the redactable functionality is enabled on the logging sink. Events not documented on this page will have an unstructured format in log messages.

Changefeed telemetry events

Events in this category pertain to changefeed usage and metrics. Events in this category are logged to the TELEMETRY channel.

alter_changefeed

An event of type alter_changefeed is an event for any ALTER CHANGEFEED statements that are run. Note: in version 26.1, these events will be moved to the CHANGEFEED channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to CHANGEFEED instead of TELEMETRY.

Common fields

changefeed_canceled

An event of type changefeed_canceled is an event for any changefeed cancellations. Note: in version 26.1, these events will be moved to the CHANGEFEED channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to CHANGEFEED instead of TELEMETRY.

Common fields

changefeed_emitted_bytes

An event of type changefeed_emitted_bytes is an event representing the bytes emitted by a changefeed over an interval. Note: in version 26.1, these events will be moved to the CHANGEFEED channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to CHANGEFEED instead of TELEMETRY.

Common fields

changefeed_failed

An event of type changefeed_failed is an event for any changefeed failure since the plan hook was triggered. Note: in version 26.1, these events will be moved to the CHANGEFEED channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to CHANGEFEED instead of TELEMETRY.

Common fields

create_changefeed

An event of type create_changefeed is an event for any CREATE CHANGEFEED query that successfully starts running. Failed CREATE statements will show up as ChangefeedFailed events. Note: in version 26.1, these events will be moved to the CHANGEFEED channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to CHANGEFEED instead of TELEMETRY.

Common fields

Cluster-level events

Events in this category pertain to an entire cluster and are not relative to any particular tenant. In a multi-tenant setup, the system.eventlog table for individual tenants cannot contain a copy of cluster-level events; conversely, the system.eventlog table in the system tenant cannot contain the SQL-level events for individual tenants. Events in this category are logged to the OPS channel.

certs_reload

An event of type certs_reload is recorded when the TLS certificates are reloaded/rotated from disk.

Common fields

disk_slowness_cleared

An event of type disk_slowness_cleared is recorded when disk slowness in a store has cleared.

Common fields

disk_slowness_detected

An event of type disk_slowness_detected is recorded when a store observes disk slowness events.

Common fields

low_disk_space

An event of type low_disk_space is emitted when a store is reaching capacity, as we reach certain thresholds. It is emitted periodically while we are in a low disk state.

Common fields

node_decommissioned

An event of type node_decommissioned is recorded when a node is marked as decommissioned.

Common fields

node_decommissioning

An event of type node_decommissioning is recorded when a node is marked as decommissioning.

Common fields

node_join

An event of type node_join is recorded when a node joins the cluster.

Common fields

node_recommissioned

An event of type node_recommissioned is recorded when a decommissioning node is recommissioned.

Common fields

node_restart

An event of type node_restart is recorded when an existing node rejoins the cluster after being offline.

Common fields

node_shutdown_connection_timeout

An event of type node_shutdown_connection_timeout is recorded when SQL connections remain open during shutdown, after waiting for the server.shutdown.connections.timeout to transpire.

Common fields

node_shutdown_transaction_timeout

An event of type node_shutdown_transaction_timeout is recorded when SQL transactions remain open during shutdown, after waiting for the server.shutdown.transactions.timeout to transpire.

Common fields

tenant_shared_service_start

An event of type tenant_shared_service_start is recorded when a tenant server is started inside the same process as the KV layer.

Common fields

tenant_shared_service_stop

An event of type tenant_shared_service_stop is recorded when a tenant server is shut down inside the same process as the KV layer.

Common fields

Contention events

Aggregated information about contention events. Events in this category are logged to the SQL_EXEC channel.

aggregated_contention_info

An event of type aggregated_contention_info is recorded periodically when contention events are resolved.

Common fields

Debugging events

Events in this category pertain to debugging operations performed by operators or (more commonly) Cockroach Labs employees. These operations can e.g. directly access and mutate internal state, breaking system invariants. Events in this category are logged to the OPS channel.

debug_recover_replica

An event of type debug_recover_replica is recorded when unsafe loss of quorum recovery is performed.

Common fields

debug_send_kv_batch

An event of type debug_send_kv_batch is recorded when an arbitrary KV BatchRequest is submitted to the cluster via the debug send-kv-batch CLI command.

Common fields

Health events

Events in this category pertain to the health of one or more servers. Events in this category are logged to the HEALTH channel.

hot_ranges_stats

An event of type hot_ranges_stats

Common fields

runtime_stats

An event of type runtime_stats is recorded every 10 seconds as server health metrics.

Common fields

Job events

Events in this category pertain to long-running jobs that are orchestrated by a node’s job registry. These system processes can create and/or modify stored objects during the course of their execution. A job might choose to emit multiple events during its execution when transitioning from one “state” to another. Egs: IMPORT/RESTORE will emit events on job creation and successful completion. If the job fails, events will be emitted on job creation, failure, and successful revert. Events in this category are logged to the OPS channel.

import

An event of type import is recorded when an import job is created and successful completion. If the job fails, events will be emitted on job creation, failure, and successful revert.

Common fields

restore

An event of type restore is recorded when a restore job is created and successful completion. If the job fails, events will be emitted on job creation, failure, and successful revert.

Common fields

status_change

An event of type status_change is recorded when a job changes statuses.

Common fields

Miscellaneous SQL events

Events in this category report miscellaneous SQL events. They are relative to a particular SQL tenant. In a multi-tenant setup, copies of these miscellaneous events are preserved in each tenant’s own system.eventlog table. Events in this category are logged to the OPS channel.

set_cluster_setting

An event of type set_cluster_setting is recorded when a cluster setting is changed.

Common fields

set_tenant_cluster_setting

An event of type set_tenant_cluster_setting is recorded when a cluster setting override is changed, either for another tenant or for all tenants.

Common fields

SQL Access Audit Events

Events in this category are generated when a table has been marked as audited via ALTER TABLE... EXPERIMENTAL_AUDIT SET. Note: These events are not written to system.eventlog, even when the cluster setting system.eventlog.enabled is set. They are only emitted via external logging. Events in this category are logged to the SENSITIVE_ACCESS channel.

admin_query

An event of type admin_query is recorded when a user with admin privileges (the user is directly or indirectly a member of the admin role) executes a query.

Common fields

role_based_audit_event

An event of type role_based_audit_event is an audit event recorded when an executed query belongs to a user whose role membership(s) correspond to any role that is enabled to emit an audit log via the sql.log.user_audit cluster setting.

Common fields

sensitive_table_access

An event of type sensitive_table_access is recorded when an access is performed to a table marked as audited.

Common fields

unsafe_internals_accessed

UnsafeInternalsAccess is recorded when a query accesses unsafe internals using the allow_unsafe_internals override.

Common fields

unsafe_internals_denied

An event of type unsafe_internals_denied is recorded when a query attempts to access unsafe internals but lacks the appropriate session variables.

Common fields

SQL Execution Log

Events in this category report executed queries. Note: These events are not written to system.eventlog, even when the cluster setting system.eventlog.enabled is set. They are only emitted via external logging. Events in this category are logged to the SQL_EXEC channel.

query_execute

An event of type query_execute is recorded when a query is executed, and the cluster setting sql.log.all_statements.enabled is set.

Common fields

scan_row_count_misestimate

An event of type scan_row_count_misestimate is recorded when the optimizer’s row count estimate for a logical scan differs significantly from the actual number of rows read, and cluster setting sql.log.scan_row_count_misestimate.enabled is set.

Common fields

SQL Logical Schema Changes

Events in this category pertain to DDL (Data Definition Language) operations performed by SQL statements that modify the SQL logical schema. They are relative to a particular SQL tenant. In a multi-tenant setup, copies of DDL-related events are preserved in each tenant’s own system.eventlog table. Events in this category are logged to the SQL_SCHEMA channel.

alter_database_add_region

An event of type alter_database_add_region is recorded when a region is added to a database.

Common fields

alter_database_drop_region

AlterDatabaseAddRegion is recorded when a region is added to a database.

Common fields

alter_database_placement

An event of type alter_database_placement is recorded when the database placement is modified.

Common fields

alter_database_primary_region

An event of type alter_database_primary_region is recorded when a primary region is added/modified.

Common fields

alter_database_set_zone_config_extension

An event of type alter_database_set_zone_config_extension is recorded when a zone config extension is changed.

Common fields

alter_database_survival_goal

An event of type alter_database_survival_goal is recorded when the survival goal is modified.

Common fields

alter_function_options

An event of type alter_function_options is recorded when a user-defined function’s options are altered.

Common fields

alter_index

An event of type alter_index is recorded when an index is altered.

Common fields

alter_index_visible

AlterIndex is recorded when an index visibility is altered.

Common fields

alter_sequence

An event of type alter_sequence is recorded when a sequence is altered.

Common fields

alter_table

An event of type alter_table is recorded when a table is altered.

Common fields

alter_type

EventAlterType is recorded when a user-defined type is altered.

Common fields

comment_on_column

An event of type comment_on_column is recorded when a column is commented.

Common fields

comment_on_constraint

An event of type comment_on_constraint is recorded when an constraint is commented.

Common fields

comment_on_database

CommentOnTable is recorded when a database is commented.

Common fields

comment_on_index

An event of type comment_on_index is recorded when an index is commented.

Common fields

comment_on_schema

Common fields

comment_on_table

An event of type comment_on_table is recorded when a table is commented.

Common fields

comment_on_type

An event of type comment_on_type is recorded when a type is commented.

Common fields

create_database

An event of type create_database is recorded when a database is created.

Common fields

create_function

An event of type create_function is recorded when a user-defined function is created.

Common fields

create_index

An event of type create_index is recorded when an index is created.

Common fields

create_policy

An event of type create_policy is recorded when a policy is created.

Common fields

create_schema

An event of type create_schema is recorded when a schema is created.

Common fields

create_sequence

An event of type create_sequence is recorded when a sequence is created.

Common fields

create_statistics

An event of type create_statistics is recorded when statistics are collected for a table. Events of this type are only collected when the cluster setting sql.stats.post_events.enabled is set.

Common fields

create_table

An event of type create_table is recorded when a table is created.

Common fields

create_trigger

An event of type create_trigger is recorded when a trigger is created.

Common fields

create_type

An event of type create_type is recorded when a user-defined type is created.

Common fields

create_view

An event of type create_view is recorded when a view is created.

Common fields

drop_database

An event of type drop_database is recorded when a database is dropped.

Common fields

drop_function

An event of type drop_function is recorded when a user-defined function is dropped.

Common fields

drop_index

An event of type drop_index is recorded when an index is dropped.

Common fields

drop_policy

An event of type drop_policy is recorded when a policy is dropped.

Common fields

drop_schema

An event of type drop_schema is recorded when a schema is dropped.

Common fields

drop_sequence

An event of type drop_sequence is recorded when a sequence is dropped.

Common fields

drop_table

An event of type drop_table is recorded when a table is dropped.

Common fields

drop_trigger

An event of type drop_trigger is recorded when a trigger is dropped.

Common fields

drop_type

An event of type drop_type is recorded when a user-defined type is dropped.

Common fields

drop_view

An event of type drop_view is recorded when a view is dropped.

Common fields

finish_schema_change

An event of type finish_schema_change is recorded when a previously initiated schema change has completed.

Common fields

finish_schema_change_rollback

An event of type finish_schema_change_rollback is recorded when a previously initiated schema change rollback has completed.

Common fields

force_delete_table_data_entry

Common fields

refresh_materialized_view

An event of type refresh_materialized_view is recorded when a materialized view is refreshed.

Common fields

rename_database

An event of type rename_database is recorded when a database is renamed.

Common fields

rename_function

An event of type rename_function is recorded when a user-defined function is renamed.

Common fields

rename_schema

An event of type rename_schema is recorded when a schema is renamed.

Common fields

rename_table

An event of type rename_table is recorded when a table, sequence or view is renamed.

Common fields

rename_type

An event of type rename_type is recorded when a user-defined type is renamed.

Common fields

reverse_schema_change

An event of type reverse_schema_change is recorded when an in-progress schema change encounters a problem and is reversed.

Common fields

set_schema

An event of type set_schema is recorded when a table, view, sequence or type’s schema is changed.

Common fields

truncate_table

An event of type truncate_table is recorded when a table is truncated.

Common fields

unsafe_delete_descriptor

An event of type unsafe_delete_descriptor is recorded when a descriptor is written using crdb_internal.unsafe_delete_descriptor(). The fields of this event type are reserved and can change across patch releases without advance notice.

Common fields

unsafe_delete_namespace_entry

An event of type unsafe_delete_namespace_entry is recorded when a namespace entry is written using crdb_internal.unsafe_delete_namespace_entry(). The fields of this event type are reserved and can change across patch releases without advance notice.

Common fields

unsafe_upsert_descriptor

An event of type unsafe_upsert_descriptor is recorded when a descriptor is written using crdb_internal.unsafe_upsert_descriptor().

Common fields

unsafe_upsert_namespace_entry

An event of type unsafe_upsert_namespace_entry is recorded when a namespace entry is written using crdb_internal.unsafe_upsert_namespace_entry(). The fields of this event type are reserved and can change across patch releases without advance notice.

Common fields

SQL Privilege changes

Events in this category pertain to DDL (Data Definition Language) operations performed by SQL statements that modify the privilege grants for stored objects. They are relative to a particular SQL tenant. In a multi-tenant setup, copies of DDL-related events are preserved in each tenant’s own system.eventlog table. Events in this category are logged to the PRIVILEGES channel.

alter_database_owner

An event of type alter_database_owner is recorded when a database’s owner is changed.

Common fields

alter_default_privileges

An event of type alter_default_privileges is recorded when default privileges are changed.

Common fields

alter_function_owner

AlterTableOwner is recorded when the owner of a user-defined function is changed.

Common fields

alter_schema_owner

An event of type alter_schema_owner is recorded when a schema’s owner is changed.

Common fields

alter_table_owner

An event of type alter_table_owner is recorded when the owner of a table, view or sequence is changed.

Common fields

alter_type_owner

An event of type alter_type_owner is recorded when the owner of a user-defiend type is changed.

Common fields

change_database_privilege

An event of type change_database_privilege is recorded when privileges are added to / removed from a user for a database object.

Common fields

change_function_privilege

Common fields

change_schema_privilege

An event of type change_schema_privilege is recorded when privileges are added to / removed from a user for a schema object.

Common fields

change_table_privilege

An event of type change_table_privilege is recorded when privileges are added to / removed from a user for a table, sequence or view object.

Common fields

change_type_privilege

An event of type change_type_privilege is recorded when privileges are added to / removed from a user for a type object.

Common fields

SQL Session events

Events in this category report SQL client connections and sessions. They are relative to a particular SQL tenant. In a multi-tenant setup, copies of these miscellaneous events are preserved in each tenant’s own system.eventlog table. Events in this category are logged to the SESSIONS channel.

client_authentication_failed

An event of type client_authentication_failed is reported when a client session did not authenticate successfully. Events of this type are only emitted when the cluster setting server.auth_log.sql_sessions.enabled is set.

Common fields

client_authentication_info

An event of type client_authentication_info is reported for intermediate steps during the authentication process. Events of this type are only emitted when the cluster setting server.auth_log.sql_sessions.enabled is set.

Common fields

client_authentication_ok

An event of type client_authentication_ok is reported when a client session was authenticated successfully. Events of this type are only emitted when the cluster setting server.auth_log.sql_sessions.enabled is set.

Common fields

client_connection_end

An event of type client_connection_end is reported when a client connection is closed. This is reported even when authentication fails, and even for simple cancellation messages. Events of this type are only emitted when the cluster setting server.auth_log.sql_connections.enabled is set.

Common fields

client_connection_start

An event of type client_connection_start is reported when a client connection is established. This is reported even when authentication fails, and even for simple cancellation messages. Events of this type are only emitted when the cluster setting server.auth_log.sql_connections.enabled is set.

Common fields

client_session_end

An event of type client_session_end is reported when a client session is completed. Events of this type are only emitted when the cluster setting server.auth_log.sql_sessions.enabled is set.

Common fields

SQL Slow Query Log

Events in this category report slow query execution. Note: these events are not written to system.eventlog, even when the cluster setting system.eventlog.enabled is set. They are only emitted via external logging. In version 26.1, these events will be moved to the SQL_EXEC channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to SQL_EXEC instead of SQL_PERF. Events in this category are logged to the SQL_PERF channel.

large_row

An event of type large_row is recorded when a statement tries to write a row larger than cluster setting sql.guardrails.max_row_size_log to the database. Multiple LargeRow events will be recorded for statements writing multiple large rows. LargeRow events are recorded before the transaction commits, so in the case of transaction abort there will not be a corresponding row in the database.

Common fields

slow_query

An event of type slow_query is recorded when a query triggers the “slow query” condition. As of this writing, the condition requires: - the cluster setting sql.log.slow_query.latency_threshold set to a non-zero value, AND - EITHER of the following conditions: - the actual age of the query exceeds the configured threshold; AND/OR - the query performs a full table/index scan AND the cluster setting sql.log.slow_query.experimental_full_table_scans.enabled is set.

Common fields

txn_rows_read_limit

An event of type txn_rows_read_limit is recorded when a transaction tries to read more rows than cluster setting sql.defaults.transaction_rows_read_log. There will only be a single record for a single transaction (unless it is retried) even if there are more statement within the transaction that haven’t been executed yet.

Common fields

txn_rows_written_limit

An event of type txn_rows_written_limit is recorded when a transaction tries to write more rows than cluster setting sql.defaults.transaction_rows_written_log. There will only be a single record for a single transaction (unless it is retried) even if there are more mutation statements within the transaction that haven’t been executed yet.

Common fields

SQL Slow Query Log (Internal)

Events in this category report slow query execution by internal executors, i.e., when CockroachDB internally issues SQL statements. Note: these events are not written to system.eventlog, even when the cluster setting system.eventlog.enabled is set. They are only emitted via external logging. In version 26.1, these events will be moved to the SQL_EXEC channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to SQL_EXEC instead of SQL_INTERNAL_PERF. Events in this category are logged to the SQL_INTERNAL_PERF channel.

large_row_internal

An event of type large_row_internal is recorded when an internal query tries to write a row larger than cluster settings sql.guardrails.max_row_size_log or sql.guardrails.max_row_size_err to the database.

Common fields

slow_query_internal

An event of type slow_query_internal is recorded when a query triggers the “slow query” condition, and the cluster setting sql.log.slow_query.internal_queries.enabled is set. See the documentation for the event type slow_query for details about the “slow query” condition.

Common fields

txn_rows_read_limit_internal

An event of type txn_rows_read_limit_internal is recorded when an internal transaction tries to read more rows than cluster setting sql.defaults.transaction_rows_read_log or sql.defaults.transaction_rows_read_err. There will only be a single record for a single transaction (unless it is retried) even if there are more mutation statements within the transaction that haven’t been executed yet.

Common fields

txn_rows_written_limit_internal

An event of type txn_rows_written_limit_internal is recorded when an internal transaction tries to write more rows than cluster setting sql.defaults.transaction_rows_written_log or sql.defaults.transaction_rows_written_err. There will only be a single record for a single transaction (unless it is retried) even if there are more mutation statements within the transaction that haven’t been executed yet.

Common fields

SQL User and Role operations

Events in this category pertain to SQL statements that modify the properties of users and roles. They are relative to a particular SQL tenant. In a multi-tenant setup, copies of DDL-related events are preserved in each tenant’s own system.eventlog table. Events in this category are logged to the USER_ADMIN channel.

alter_role

An event of type alter_role is recorded when a role is altered.

Common fields

create_role

An event of type create_role is recorded when a role is created.

Common fields

drop_role

An event of type drop_role is recorded when a role is dropped.

Common fields

grant_role

An event of type grant_role is recorded when a role is granted.

Common fields

password_hash_converted

An event of type password_hash_converted is recorded when the password credentials are automatically converted server-side.

Common fields

Storage telemetry events

Events in this category are logged to the TELEMETRY channel.

level_stats

An event of type level_stats contains per-level statistics for an LSM.

store_stats

An event of type store_stats contains per store stats. Note that because stats are scoped to the lifetime of the process, counters (and certain gauges) will be reset across node restarts.

Common fields

TELEMETRY

Events in this file are related to bulk ingest operations performance metrics. Events in this category are logged to the TELEMETRY channel.

bulk_ingest_completed

An event of type bulk_ingest_completed is an event that is logged when a bulk ingest job (restore, import, etc.) completes successfully. It captures key performance metrics for the operation.

Common fields

Telemetry events

Events in this category are logged to the TELEMETRY channel.

captured_index_usage_stats

An event of type captured_index_usage_stats

Common fields

m_v_c_c_iterator_stats

Internal storage iteration statistics for a single execution.

recovery_event

An event of type recovery_event is an event that is logged on every invocation of BACKUP, RESTORE, and on every BACKUP schedule creation, with the appropriate subset of fields populated depending on the type of event. This event is is also logged whenever a BACKUP and RESTORE job completes or fails.

Common fields

sampled_exec_stats

An event of type sampled_exec_stats contains execution statistics that apply to both statements and transactions. These stats as a whole are collected using a sampling approach. These exec stats are meant to contain the same fields as ExecStats in apps_stats.proto but are for a single execution rather than aggregated executions. Fields in this struct should be updated in sync with apps_stats.proto.

sampled_query

An event of type sampled_query is the SQL query event logged to the telemetry channel. It contains common SQL event/execution details. Note: in version 26.1, these events will be moved to the SQL_EXEC channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to SQL_EXEC instead of TELEMETRY.

Common fields

sampled_transaction

An event of type sampled_transaction is the event logged to telemetry at the end of transaction execution. Note: in version 26.1, these events will be moved to the SQL_EXEC channel. To test compatability before this, set the cluster setting log.channel_compatibility_mode.enabled to false. This will send the events to SQL_EXEC instead of TELEMETRY.

Common fields

schema_descriptor

An event of type schema_descriptor is an event for schema telemetry, whose purpose is to take periodic snapshots of the cluster’s SQL schema and publish them in the telemetry log channel. For all intents and purposes, the data in such a snapshot can be thought of the outer join of certain system tables: namespace, descriptor, and at some point perhaps zones, etc. Snapshots are too large to conveniently be published as a single log event, so instead they’re broken down into SchemaDescriptor events which contain the data in one record of this outer join projection. These events are prefixed by a header (a SchemaSnapshotMetadata event).

Common fields

schema_snapshot_metadata

An event of type schema_snapshot_metadata is an event describing a schema snapshot, which is a set of SchemaDescriptor messages sharing the same SnapshotID.

Common fields

Zone config events

Events in this category pertain to zone configuration changes on the SQL schema or system ranges. When zone configs apply to individual tables or other objects in a SQL logical schema, they are relative to a particular SQL tenant. In a multi-tenant setup, copies of these zone config events are preserved in each tenant’s own system.eventlog table. When they apply to cluster-level ranges (e.g., the system zone config), they are stored in the system tenant’s own system.eventlog table. Events in this category are logged to the OPS channel.

remove_zone_config

An event of type remove_zone_config is recorded when a zone config is removed.

Common fields

set_zone_config

An event of type set_zone_config is recorded when a zone config is changed.

Common fields

Enumeration types

AuthFailReason

AuthFailReason is the inventory of possible reasons for an authentication failure.