How to make adb shell ps list all processes in Android O?

匿名 (未验证) 提交于 2019-12-03 07:50:05

问题:

adb shell ps not working in O android release

adb shell ps command in Android O release is listing only ps process information, but it is not listing all the processes information of all the process like it used to do it in earlier android releases

what is the command to list all the processes information in android O release?

回答1:

adb shell ps -A is listing all processes in android-8.0-O release.

I think Google has upgraded ps binary in this release.



回答2:

There are so many new options in ps . Try running ps --help

generic_x86:/ $ ps --help usage: ps [-AadefLlnwZ] [-gG GROUP,] [-k FIELD,] [-o FIELD,] [-p PID,] [-t TTY,] [-uU USER,]  List processes.  Which processes to show (selections may be comma separated lists):  -A  All processes  -a  Processes with terminals that aren't session leaders  -d  All processes that aren't session leaders  -e  Same as -A  -g  Belonging to GROUPs  -G  Belonging to real GROUPs (before sgid)  -p  PIDs (--pid)  -P  Parent PIDs (--ppid)  -s  In session IDs  -t  Attached to selected TTYs  -T  Show threads  -u  Owned by USERs  -U  Owned by real USERs (before suid)  Output modifiers:  -k  Sort FIELDs in +increasing or -decreasting order (--sort)  -M  Measure field widths (expanding as necessary)  -n  Show numeric USER and GROUP  -w  Wide output (don't truncate fields)  Which FIELDs to show. (Default = -o PID,TTY,TIME,CMD)  -f  Full listing (-o USER:12=UID,PID,PPID,C,STIME,TTY,TIME,ARGS=CMD)  -l  Long listing (-o F,S,UID,PID,PPID,C,PRI,NI,ADDR,SZ,WCHAN,TTY,TIME,CMD)  -o  Output FIELDs instead of defaults, each with optional :size and =title  -O  Add FIELDS to defaults  -Z  Include LABEL 


标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!