z/OS UNIX System Services User's Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Finding a directory or file

z/OS UNIX System Services User's Guide
SA23-2279-00

The find command lists the names of all the files under a directory with a given characteristic or set of characteristics. The simplest version of the command is:
find dirname
It displays the names of all files under the given directory, including files in subdirectories under the directory.
To display the names of all files whose names have the form specified in pattern, issue:
find dirname –name pattern
Example: To list the names of all files under the directory abc with the file name extension .lst,issue: (
find abc –name '*.lst'
The asterisk (*) is a wildcard character that stands for any sequence of zero or more characters.l Using find, you can locate files quickly, even when you have a complicated file system structure, with many directories and subdirectories. See the find command description in z/OS UNIX System Services Command Reference.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014