其实, adb shell dumpsys命令是用于打印出当前系统信息(更切确的说是dumpsys命令,因为adb shell只是为了进入手机或模拟器的shell内核,使其能够执行dumpsys命令),可以在命令后面加指定的service name(比如activity,location),如果不加则默认打印出设备中所有service的信息.
在adb shell dumpsys后面可添加的service name可通过adb shell dumpsys或adb shell service list方法获取.
1.adb shell dumpsys
===================================================
Currently running services:
DmAgent
DockObserver
GuiExtService
IIccPhoneBookMz
NvRAMAgent
PPLAgent
SurfaceFlinger
access_control
accessibility
account
activity
alarm
alphame_server
android.security.keystore
anrmanager
appops
appwidget
audio
backup
battery
batteryproperties
batterystats
bluetooth_manager
clipboard
commontime_management
connectivity
consumer_ir
content
country_detector
cpuinfo
dbinfo
device_control
device_policy
device_states
devicestoragemonitor
diskstats
display
dreams
drm.drmManager
dropbox
entropy
fingerprint
fingerprints_service
flyme_error_report_manager
flyme_novccusagestats
flyme_packagemanager
flyme_permission
flyme_splitmode
flyme_statusbar
flyme_theme_service
flyme_wallpaper
gesture_manager
gfxinfo
hardware
hips_service
imms
input
input_method
iphonesubinfo
isms
isub
jobscheduler
launcherapps
location
lock_settings
media.audio_flinger
media.audio_policy
media.camera
media.mmsdk
media.player
media.sound_trigger_hw
media_projection
media_router
media_session
meizu.camera
meminfo
memory_dumper
mobile
mount
move_window
mtk-perfservice
mtk.codecservice
netpolicy
netstats
network_management
network_score
networkmanagement_service_flyme
notification
package
permission
phone
phoneEx
phone_ext
power
pppoe
print
procstats
program_binary
recovery
restrictions
rttmanager
samba_client
samba_server
samplingprofiler
scheduling_policy
search
search_engine
sensorservice
serial
servicediscovery
simphonebook
sip
statusbar
telecom
telephony.registry
textservices
trust
uimode
updatelock
usagestats
usb
user
vibrator
voiceinteraction
wallpaper
webviewupdate
wifi
wifip2p
wifiscanner
window