{"id":2549,"date":"2023-03-19T15:51:30","date_gmt":"2023-03-19T10:21:30","guid":{"rendered":"https:\/\/smarttech101.com\/?p=2549"},"modified":"2023-03-22T17:14:23","modified_gmt":"2023-03-22T11:44:23","slug":"how-to-create-fstab-entry-in-linux","status":"publish","type":"post","link":"https:\/\/smarttech101.com\/how-to-create-fstab-entry-in-linux\/","title":{"rendered":"How to create fstab entry in Linux"},"content":{"rendered":"\n

The fstab is used to mount drives during the boot. Basically, it is represented by the file \/etc\/fstab<\/code>. The mount<\/code> and unmount<\/code> commands also read this to mount\/unmount drives with specific options. In this article, I will explain how it works, and its fields. I will also help you to create a mount entry for your new disk drive, NTFS drives, virtual hard disk, swapfile, etc.<\/p>\n\n\n\n

Each Linux distribution creates \/etc\/fstab<\/code> file during its installation. It might look like this:<\/p>\n\n\n\n

# <file system> <dir> <type> <options> <dump> <pass>\n\n# \/dev\/nvme0n1p5\nUUID=fc986af0-b252-4c73-a921-a7cb75eb4c5f    \/           ext4        rw,lazytime,strictatime 0 1\n\n# \/dev\/nvme0n1p1\nUUID=B2E8-9A01          \/boot\/EFI   vfat        rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro   0 2<\/code><\/pre>\n\n\n\n

Table of Contents<\/h2>\n\n\n\n