Skip to Content
CockroachDB权威指南
book

CockroachDB权威指南

by Guy Harrison, Jesse Seldess, Ben Darnell
May 2024
Intermediate
425 pages
12h 29m
Chinese
China Machine Press
Content preview from CockroachDB权威指南
370
|
14
14-3CockroachDB 日志过滤器
过滤器 描述
INFO INFO
级别用于不需要操作的信息性消息
WARNING WARNING
级别用于可能需要特殊处理的情况
在这种情况下
正常操作默
认是可以自动恢复的
ERROR ERROR
级别用于需要特殊处理的情况
在这种情况下
正常操作不能按预
期执行
其他大部分操作基本可以不受影响地继续进行
FATAL FATAL
级别用于需要立即硬关闭服务器的情况
如果启用遥测
也会向遥
测系统发送错误报告
注意,每个过滤器包含所有高级过滤器。因此,如果指定
INFO
,那么你还将收到
WARNING
ERROR
FATAL
。如果指定
ERROR
,那么还将收到
FATAL
YAML
的这个片段中,我们将默认过滤器设置为
WARNING
,有效地从日志流中消除
INFO
消息:
file-defaults:
max-file-size: 10MiB
max-group-size: 100MiB
buffered-writes: true
filter: WARNING
format: json
在这个代码片段中,我们将
sql-audit-channel
的过滤器设置为
INFO
,覆盖应用于其
他日志的
WARNING
过滤器:
sql-audit:
channels: [SENSITIVE_ACCESS]
filter: INFO
auditable: true
14.2.4
日志目的地
基于文件的目标可以通过修改默认
dir
值或特定接收器的
dir
值来更改。例如,这里我
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

What Successful Brick-and-Mortar Retailers Get Right

What Successful Brick-and-Mortar Retailers Get Right

Rob Angell
A Five-Step Guide to Improving Your Employer Brand

A Five-Step Guide to Improving Your Employer Brand

Kimberly A. Whitler, Richard Mosley
What Successful Project Managers Do

What Successful Project Managers Do

W. Scott Cameron, Jeffrey S. Russell, Edward J. Hoffman, Alexander Laufer

Publisher Resources

ISBN: 9787111752868