Easy Tutorial
❮ Linux Comm Tee Linux Comm Netconfig ❯

Linux slocate Command

Linux Command Manual

The Linux slocate command is used to find files or directories.

slocate has its own database that contains information about files and directories on the system.

Syntax

slocate [-u][--help][--version][-d <directory>][file to find]

Parameters:

Example

To display file path information containing the keyword "fdisk" using the "slocate" command, enter the following command:

$ slocate fdisk # Displays file path information containing the keyword "fdisk"

After executing the above command, the output information is as follows:

$ slocate fdisk # Displays file path information containing the keyword "fdisk"
/root/cfdisk        # List of found file paths
/root/fdisk
/root/sfdisk
/usr/include/grub/ieee1275/ofdisk.h
/usr/share/doc/util-Linux/README.cfdisk
/usr/share/doc/util-Linux/README.fdisk.gz
/usr/share/doc/util-Linux/examples/sfdisk.examples.gz

Linux Command Manual

❮ Linux Comm Tee Linux Comm Netconfig ❯