• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

findfs Command Examples in Linux

by Deepika

findfs is a command-line tool used to find a file system by either its label or UUID (Universally Unique Identifier) on a Linux or Unix-based system. It is a part of the util-linux package and can be used to locate a specific file system in a system with multiple file systems.

A file system label is a human-readable name that is assigned to a file system, typically at the time of its creation. A UUID, on the other hand, is a unique identifier that is assigned to a file system by the operating system, and it is not intended to be human-readable.

The findfs command can be used to find a file system by either its label or UUID. When used with the -l option, it will look for a file system with a specific label. When used with the -u option, it will look for a file system with a specific UUID. Once a file system is found, the command will return its device name, which can then be used to mount or work with the file system.

For example, to find a file system with the label “data”, the command would be:

# findfs LABEL="data"

To find a file system with UUID “8cc0f05e-7c9b-4c0d-8a2b-3f6f3e6e0c6a” the command would be:

# findfs UUID="8cc0f05e-7c9b-4c0d-8a2b-3f6f3e6e0c6a"

findfs Command Examples

1. Search block devices by filesystem label:

# findfs LABEL=label

2. Search by filesystem UUID:

# findfs UUID=uuid

3. Search by partition label (GPT or MAC partition table):

# findfs PARTLABEL=partition_label

4. Search by partition UUID (GPT partition table only):

# findfs PARTUUID=partition_uuid

Filed Under: Linux

Some more articles you might also be interested in …

  1. parted: command not found
  2. chsh: command not found
  3. startx: command not found
  4. ack – A search tool like grep, optimized for developers (Command Examples)
  5. CentOS / RHEL : Installing and Configuring ASMLib
  6. radeontop Command Examples in Linux
  7. lsinitramfs: Listing the contents of the initrd file system.
  8. apt-file Command Examples in Linux
  9. NFSv4 mountpoint shows incorrect ownerships as nobody:nobody in CentOS/RHEL
  10. updatedb: command not found

You May Also Like

Primary Sidebar

Recent Posts

  • “az storage blob” Command Examples (Manage blob storage containers and objects in Azure)
  • “az storage account” Command Examples (Manage storage accounts in Azure)
  • “az sshkey” Command Examples (Manage ssh public keys with virtual machines)
  • “az redis” Command Examples

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright