android dump service,dumpsys 查看android 常用的service

1.dumpsys window:

可以查看window stack,wallpaper等情况

2.dumpsys activity

可以查看所有activity service的情况

dumpsys activity oom 可以看到oom adj 信息

3.dumpsys SurfaceFlinger

可以查看各个layer 的情况

--------------------------------------------------------------------------------

1.显示相关service;   SurfaceFlinger

display

gfxinfo

window

activity

wallpaper

2.多媒体相关:

media.player

media.audio_flinger

media.audio_policy

media.camera

3.输入相关:

input

input_method

4.常用的service

package

meminfo

mount

notification

account

alarm

audio

cpuinfo

dbinfo

device_policy

power

sensorservice

statusbar

usagestats

usb

user

wifi

wifip2p

5.查看各个service 的状态,每个service的状态都保存在init.svc.service_name 系统属性里,可以通过以下命令查看:

shell@android:/data # getprop | grep init.svc

[init.svc.adbd]: [stopped]

[init.svc.bootanim]: [stopped]

[init.svc.zygote]: [running]

6. 查看所有的service

adb shell dumpsys | grep

"DUMP OF SERVICE"

7. AudioPolicyService 查看,各个audio stream 的音量情况

dumpsys media.audio_policy

PolicyManager Interface: 0xb7775e40

Command Thread: 0xb77757b0

Tones Thread: 0xb7775480

AudioCommandThread 0xb77757b0 Dump

- Commands:

Command Time        Wait pParam

Last Command

03      000335.810  1    0xb77966f8

AudioCommandThread 0xb7775480 Dump

- Commands:

Command Time        Wait pParam

Last Command

-1      000007.373  0    0x0

AudioPolicyManager Dump: 0xb7775ee8

Primary Output: 2

A2DP device address:

SCO device address:

USB audio ALSA

Output devices: 00000403

Input devices: 00000084

Phone state: 0

Force use for communications 0

Force use for media 0

Force use for record 0

Force use for dock 8

Force use for system 0

HW Modules dump:

- HW Module 1:

- name: primary

- handle: 1

- outputs:

output 0:

- sampling rates: 44100

- channel masks: 0x0003

- formats: 0x00000001

- devices: 0x107f

- flags: 0x0002

- inputs:

input 0:

- sampling rates: 8000, 11025, 12000, 16000, 22050, 24000, 32000, 44100, 48000

- channel masks: 0x0010, 0x000c

- formats: 0x00000001

- devices: 0x8000009c

- flags: 0x0000

- HW Module 2:

- name: virtualaudio

- handle: 3

- inputs:

input 0:

- sampling rates: 8000, 11025, 12000, 16000, 22050, 24000, 32000, 44100, 48000

- channel masks: 0x0010, 0x000c

- formats: 0x00000001

- devices: 0x80000010

- flags: 0x0000

- HW Module 3:

- name: a2dp

- handle: 4

- outputs:

output 0:

- sampling rates: 44100

- channel masks: 0x0003

- formats: 0x00000001

- devices: 0x0380

- flags: 0x0000

- HW Module 4:

- name: usb

- handle: 5

- outputs:

output 0:

- sampling rates: 44100

- channel masks: 0x0003

- formats: 0x00000001

- devices: 0x2000

- flags: 0x0000

output 1:

- sampling rates: 44100

- channel masks: 0x0003

- formats: 0x00000001

- devices: 0x4000

- flags: 0x0000

- inputs:

input 0:

- sampling rates: 8000, 11025, 16000, 22050, 32000, 44100, 48000

- channel masks: 0x0010

- formats: 0x00000001

- devices: 0x80001000

- flags: 0x0000

- HW Module 5:

- name: r_submix

- handle: 6

- outputs:

output 0:

- sampling rates: 48000

- channel masks: 0x0003

- formats: 0x00000001

- devices: 0x8000

- flags: 0x0000

- inputs:

input 0:

- sampling rates: 48000

- channel masks: 0x000c

- formats: 0x00000001

- devices: 0x80000100

- flags: 0x0000

- HW Module 6:

- name: hdmi

- handle: 7

- outputs:

output 0:

- sampling rates: 48000

- channel masks: 0x0003

- formats: 0x00000001

- devices: 0x0400

- flags: 0x0000

output 1:

- sampling rates: 48000

- channel masks: 0x003f

- formats: 0x00000001

- devices: 0x0400

- flags: 0x0001

output 2:

- sampling rates: 32000, 44000, 48000, 88200, 96000

- channel masks: 0x063f

- formats: 0x00000001

- devices: 0x0400

- flags: 0x0001

output 3:

- sampling rates: 48000, 44100, 32000, 192000, 88200, 96000

- channel masks: 0x0003

- formats: 0x08000000, 0x09000000, 0x0a000000, 0x0b000000

- devices: 0x0400

- flags: 0x0001

Outputs dump:

- Output 2 dump:

Sampling rate: 48000

Format: 00000001

Channels: 00000003

Latency: 85

Flags 00000002

Devices 00000002

Stream volume refCount muteCount

00     0.582     00       00

01     0.501     00       00

02     1.000     00       00

03     0.425     00       00

04     0.596     00       00

05     1.000     00       00

06     -1.000     00       00

07     0.501     00       00

08     0.501     00       00

09     0.425     00       00

- Output 8 dump:

Sampling rate: 48000

Format: 00000001

Channels: 00000003

Latency: 85

Flags 00000000

Devices 00000400

Stream volume refCount muteCount

00     0.582     00       00

01     0.278     00       00

02     0.367     00       00

03     1.000     00       00

04     0.596     00       00

05     0.367     00       00

06     -1.000     00       00

07     0.278     00       00

08     0.290     00       00

09     0.425     00       00

- Output 9 dump:

Sampling rate: 48000

Format: 00000001

Channels: 00000003

Latency: 85

Flags 00000000

Devices 00000402

Stream volume refCount muteCount

00     0.582     00       00

01     0.501     00       00

02     1.000     00       00

03     0.425     00       00

04     0.596     00       00

05     1.000     00       00

06     -1.000     00       00

07     0.501     00       00

08     0.501     00       00

09     0.425     00       00

Inputs dump:

Streams dump:

Stream  Can be muted  Index Min  Index Max  Index Cur [device : index]...

00      true          00         05         40000000 : 04,

01      true          00         07         0002 : 07, 40000000 : 05,

02      true          00         07         0002 : 07, 40000000 : 05,

03      true          00         15         0004 : 10, 0008 : 10, 40000000 : 11,

04      true          00         07         40000000 : 06,

05      true          00         07         0002 : 07, 40000000 : 05,

06      true          00         15         40000000 : 07,

07      true          00         07         0002 : 07, 40000000 : 05,

08      true          00         15         0002 : 15, 40000000 : 11,

09      true          00         15         0004 : 10, 0008 : 10, 40000000 : 11,

Total Effects CPU: 0.000000 MIPS, Total Effects memory: 0 KB

Registered effects:

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值