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

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

mkfs.vfat Command Examples in Linux

by admin

“mkfs.vfat” is a command-line utility that creates a Virtual File Allocation Table (VFAT) filesystem on a partition or disk. VFAT is an extension of the original FAT file system developed by Microsoft, and is designed to be backward-compatible with older systems while also supporting long file names and larger partition sizes. The “mkfs.vfat” command initializes the partition, creates the necessary file and directory structures, and writes the boot sector and other required information to the partition. After the process is complete, the partition is ready to be used to store and access files, and should be compatible with most operating systems that support FAT file systems. VFAT is commonly used on removable drives and other storage devices that need to be compatible with different operating systems, including Microsoft Windows, macOS, and Linux.

mkfs.vfat Command Examples

1. Create a vfat filesystem inside partition 1 on device b (`sdb1`):

# mkfs.vfat /dev/sdb1

2. Create filesystem with a volume-name:

# mkfs.vfat -n volume_name /dev/sdb1

3. Create filesystem with a volume-id:

# mkfs.vfat -i volume_id /dev/sdb1

4. Use 5 instead of 2 file allocation tables:

# mkfs.vfat -f 5 /dev/sdb1

Filed Under: Linux

Some more articles you might also be interested in …

  1. How to Re-generate initramfs and vmlinuz for Rescue Kernel with Current Kernel in CentOS/RHEL 7
  2. “cannot install the best update candidate for package” – error on running dnf update
  3. dumpe2fs: command not found
  4. genid Command Examples in Linux
  5. How to change the PATH variable in Linux
  6. flow: A static type checker for JavaScript
  7. gh pr merge: Merge GitHub pull requests
  8. command: Command forces the shell to execute the program and ignore any functions, builtins and aliases with the same name
  9. deluge: A command-line BitTorrent client
  10. duf: Disk Usage/Free Utility

You May Also Like

Primary Sidebar

Recent Posts

  • glab Command Examples
  • “glab repo” Command Examples
  • “glab release” Command Examples
  • “glab pipeline” Command Examples

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright