Yandex Cloud
Search
Contact UsGet started
  • Blog
  • Pricing
  • Documentation
  • All Services
  • System Status
    • Featured
    • Infrastructure & Network
    • Data Platform
    • Containers
    • Developer tools
    • Serverless
    • Security
    • Monitoring & Resources
    • ML & AI
    • Business tools
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Customer Stories
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Education and Science
    • Yandex Cloud Partner program
  • Blog
  • Pricing
  • Documentation
© 2025 Direct Cursus Technology L.L.C.
Yandex Query
    • All tutorials
    • Processing Cloud Logging logs
    • Processing CDC Debezium streams
    • Visualizing Object Storage data in DataLens
    • Processing Audit Trails events
    • Processing files with usage details in Yandex Cloud Billing
    • Analyzing data with Jupyter
    • Automating tasks using Managed Service for Apache Airflow™
    • Analyzing data with Query
    • Working with data in Object Storage
    • Working with data in Managed Service for ClickHouse®
    • Working with data in Managed Service for PostgreSQL
    • Federated data queries
    • Searching for Yandex Cloud events in Query
  • Access management
  • Pricing policy
  • Integration
  • Audit Trails events
  • FAQ

In this article:

  • Getting started
  • Configure Audit Trails
  • Set up integration between Audit Trails and Query
  • Analytical queries to data in Object Storage
  • Streaming queries to data from Data Streams
  • See also
  1. Tutorials
  2. Processing Audit Trails events

Processing Yandex Audit Trails events

Written by
Yandex Cloud
Updated at May 7, 2025
  • Getting started
  • Configure Audit Trails
  • Set up integration between Audit Trails and Query
  • Analytical queries to data in Object Storage
  • Streaming queries to data from Data Streams
  • See also

Yandex Audit Trails is a service for collecting and exporting the audit logs of Yandex Cloud resources to various target systems, including Yandex Object Storage and Yandex Data Streams. Audit Trails and Yandex Query are integrated between themselves to enable searching through audit logs.

image

After audit logs are processed using Query, you can get such information as:

  • Who deleted a cloud folder.
  • Who added permissions to access the Yandex Compute Cloud VM serial console.
  • Who edited permissions to access an Object Storage bucket.
  • Who was granted administrator privileges.

You can find the preset queries for these use cases in this GitHub repository. You can also write custom YQL queries.

In this use case, you will create trails that will upload audit logs of all folder resources to an Object Storage bucket and send them to a Data Streams stream. Next, you will run analytical and streaming queries to the log data using Query.

Getting started

Sign up in Yandex Cloud and create a billing account:

  1. Navigate to the management console and log in to Yandex Cloud or register a new account.
  2. On the Yandex Cloud Billing page, make sure you have a billing account linked and it has the ACTIVE or TRIAL_ACTIVE status. If you do not have a billing account, create one and link a cloud to it.

If you have an active billing account, you can navigate to the cloud page to create or select a folder for your infrastructure to operate in.

Learn more about clouds and folders.

Configure Audit Trails

Create two trails:

  • To upload folder audit logs to an Object Storage bucket.
  • To send folder audit logs to a Data Streams stream.

Set up integration between Audit Trails and Query

To set up integration:

  1. Open the list of trails in the Yandex Cloud console.
  2. Select the trail that you previously created for uploading cloud audit logs to a bucket and click Process in YQ.
  3. When switching from Audit Trails to Query for the first time, set up integration:
    1. In the Query interface, select the service account you want to use to read data from Object Storage in the connection creation dialog and click Create.
    2. In the Query interface, check the preset parameters by clicking Preview in the binding creation dialog. Next, click Create to complete the integration.

This will automatically redirect you to the Audit trails panel of the Query interface.

Perform similar actions for the previously created trail that sends data to a Data Streams stream.

Analytical queries to data in Object Storage

To query Audit Trails analytical data stored in Object Storage:

  1. Under Audit trails in the Query interface, select Analytical as the data analysis type. In the list of data bindings, select audit-trails-test-object_storage.
  2. Select a query to Object Storage data from the list and click Run.

You can do the following with analytical query results:

  • Download them through the Query UI by clicking Export.
  • Save them to an Object Storage bucket.
  • Get and process them via the Query HTTP API.

Streaming queries to data from Data Streams

To query Audit Trails streaming data transferred through Data Streams:

  1. Under Audit trails in the Yandex Query interface, select Streaming as the data analysis type. In the list of data bindings, select the one you need.
  2. Select a query to Object Storage data from the list and click Run.

You can do the following with streaming query results:

  • Send them to Yandex Monitoring as metrics.
  • Send them to an output Data Streams stream as data and then process the data using Yandex Cloud Functions triggers.

See also

  • Yandex Object Storage.
  • Yandex Data Streams.
  • Yandex DataLens.

Was the article helpful?

Previous
Visualizing Object Storage data in DataLens
Next
Processing files with usage details in Yandex Cloud Billing
© 2025 Direct Cursus Technology L.L.C.