当前位置:网站首页>AOSP ~ logcat persistence
AOSP ~ logcat persistence
2022-06-29 13:16:00 【Nanke is cute】
I found an option to store logs: Settings -> System -> Advanced -> Developer options -> Store logger data persistently on device
Store logger data persistently on device: Select the type of log messages you want to store persistently on the device. Options are off, all, all but radio, or kernel only.
logd is the logging daemon on Android which mainly covers the functionality of its desktop counterpart syslogd, but also includes klogd and partially auditd to get logs from SELinux subsystem of kernel. However logd just reads from different memory buffers (in RAM) and doesn’t save to persistent memory (files) by default. We can use commandline tools logcat and log to read/write from/to logd respectively. Read here more about memory buffers - main, system, radio, events, and crash.
If one needs persistent logs as files, a separate sub-service (available on userdebug and eng builds only since Oreo (1)) named logcatd (logcat daemon which itself reads from logd) can save them to filesystem in /data/misc/logd/ (not accessible without root). Behavior of the service on boot is controlled by properties logd.logpersistd.enable and persist.logd.logpersistd (2). Or to manually start/stop the service shell scripts /system/bin/logpersist.[start|stop] can be used.
The option “Store logger data persistently on device” in “Developer Options” also controls the same service using property persist.logd.logpersistd.buffer. From official documentation:
Store logger data persistently on device: Select the type of log messages you want to store persistently on the device. Options are off, all, all but radio, or kernel only.
Reference resources : https://elinux.org/Android_Logging_System
边栏推荐
- Qt中的UI文件介绍
- Install the terrain ovirt plug-in to provide automated management for ovirt
- C#实现队列结构定义、入队、出队操作
- C语言内存函数
- 记一次固态更新与系统迁移debug的过程
- 倍福控制器连接松下EtherCAT伺服注意事项
- Cvpr2022 𞓜 thin domain adaptation
- Aes-128-cbc-pkcs7padding encrypted PHP instance
- RT thread memory management
- Hutool tool class learning (continuous update)
猜你喜欢
随机推荐
nvtmpp
倍福控制器连接松下EtherCAT伺服注意事项
C#实现堆栈结构的定义、入栈、出栈
mysql调优
Cvpr2022 | reexamine pooling: your receptive field is not the best
Evaluation of powerful and excellent document management software: image management, book management and document management
Interview shock 61: tell me about MySQL transaction isolation level?
树状数组应用(AcWing 242,243,244)
AcWing第57场周赛
Don't build the wheel again. It is recommended to use Google guava open source tool class library. It is really powerful!
SCHIEDERWERK电源维修SMPS12/50 PFC3800解析
Acwing 234 abandoning testing
Tree array application (acwing 24224244)
qt json
leetcode 522. Longest special sequence II
安装terraform-ovirt插件为ovirt提供自动化管理
C#通过线索二叉树进行中序遍历输出
STK_ Gltf model
C#实现队列结构定义、入队、出队操作
Hystrix circuit breaker









