如何在Android中更改logcat缓冲区的大小? [英] How to change size of logcat buffer in Android?

查看:839
本文介绍了如何在Android中更改logcat缓冲区的大小?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我注意到logcat缓冲区的大小在不同设备上有所不同.假设我对设备具有root权限,是否可以在运行时更改主缓冲区的缓冲区大小?如果没有,那么假设我可以重建Android映像,那么在编译时如何更改它?我正打算将其放大以用于诊断.

I noticed that the size of the logcat buffer varies on different devices. Assuming I have root permissions on my device, is there a way to change the buffer size of the main buffer at runtime? If not, then assuming I can rebuild the Android image, how do I change it at compile time? I'm looking to enlarge it for diagnostic purposes.

推荐答案

根据新闻组 Android Developers

According to the newsgroup Android Developers, logcat buffer size:

设备上的日志缓冲区为64 KB.时间戳,进程ID, 和日志级别以紧凑格式存储,因此您实际上可能会 logcat -d -v <mode>中超过64 KB的格式化数据.

The log buffers on the device are 64 KB. The timestamp, process ID, and log level are stored in a compact format, so you may actually get more than 64 KB of formatted data out of logcat -d -v <mode>.

这篇关于如何在Android中更改logcat缓冲区的大小?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆