grep command is not installed by default on your device. If you need to use the grep on your device, you can cross-compile busybox and then call grep under busybox .
However, if you are on Linux or Cygwin , you can execute the output of the command and use grep on the PC to get the desired result, for example
$ adb shell ps |grep google app_5 279 71 200212 30928 ffffffff 00000000 S com.google.process.gapps app_66 481 71 122804 21632 ffffffff 00000000 S com.google.android.apps.maps app_66 32311 71 120200 20916 ffffffff 00000000 S com.google.android.apps.maps:NetworkLocationService
source share