Take the 2-minute tour ×
Android Enthusiasts Stack Exchange is a question and answer site for enthusiasts and power users of the Android operating system. It's 100% free, no registration required.

Is there an adb command similar to "locate" or "grep" that would help me find a file on my Android device?

I'm curious about adb specifically, not a search app.

EDIT: "find" has been suggested, but on my ICS device:

hydrangea@turnsole:~$ adb shell find / -name *maps*
/system/bin/sh: find: not found

On my Gingerbread device it works, though. (Except I haven't rooted that device so it lacks permission.)

hydrangea@turnsole:~$ adb shell find / -name *maps*
find: permission denied
share|improve this question
Busybox will provide grep but not locate (AFAIK). –  eldarerathis Feb 29 '12 at 22:40
find is available on stock devices I believe too. –  Ryan Conrad Feb 29 '12 at 22:52
On ICS at least it tells me "find: not found". :( –  Hydrangea Feb 29 '12 at 23:53

1 Answer 1

The find command works well in adb shell. The syntax is find /path -name file_name. For searching read only areas you will need root. If the find command is not available on your particular device, you might need to install BusyBox (search the Market.)

For example,
adb shell find / -name *maps*
will find all files that contain word "maps" across the entire file system.

share|improve this answer
If this command spams you with /somedir/: Permission denied append 2>/dev/null to the command to mute error messages. –  onik Mar 1 '12 at 12:38

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.