Exporting logs to Data Streams
Written by
Updated at July 15, 2025
Management console
CLI
API
- In the management console
, select the folder with the log group. - Select Cloud Logging.
- Next to the log group, click
. - In the menu that opens, click Edit.
- In the Stream field, select an existing data stream or create a new one.
- Click Save.
To export logs to a data stream, run this command:
yc logging group update \
--name=<log_group_name> \
--data-stream=<stream_ID>
Where:
--name
: Log group name.--data-stream
: Data stream ID in Yandex Data Streams consisting of the availability zone, cloud ID, database ID, and data stream name.
For example, your stream ID will appear as
/ru-central1/b1gvlrnlei4l********/etn780rpm7e5********/default
if:
ru-central1
: Region.b1gvlrnlei4l********
: Cloud ID.etn780rpm7e5********
: YDB database ID.default
: Stream name.
To export logs to a data stream, use the update REST API method for the LogGroup resource or the LogGroupService/Update gRPC API call.
The specified data stream will automatically receive the records added to your log group.