![]() So I set the pass value to 2 for my drive. All other file systems should have a value of 2. Swap partitions do not need to be checked and the value for them is zero. As you can see in this file, the value of the pass field for the root file system is 1. The pass field is used by the fsck program to determine the order in which filesystem checks are done at reboot time. The value of the dump field is usually zero. The defaults mount option will give users read and write access to the file system. Some Explanationįor swap partitions, the mount point field should be specified as none. So that’s how you automount a file system in Linux. Then run the following command to see if it works. If you want to automount a Btrfs file system, then change the file system type to btrfs. If you want to automount an NTFS file system, here is an example. For example, I added the following line to the end of /etc/fstab. Note that you need to separate these items with Tab key. The format of this line of code is as follows: UUID= We need to append one line of code at the end of the file. Run the following command to edit the /etc/fstab file. ![]() Enter the following command, sudo mkdir /mnt/įor example, I issued the following command: sudo mkdir /mnt/sdb9 Step 3: Edit /etc/fstab File We are going to make a mount point under /mnt directory. Step 2: Make a Mount Point For Your Drive As you can see the UUID of /dev/sdb9 is eb67c479-962f-4bcc-b3fe-cefaf908f01e and the file system of /dev/sdb9 is ext4 which is the standard file system in Linux. Then you need to know its UUID and file system type. For example, the name of the drive that is going to be automatically mounted on my computer is /dev/sdb9. The second column is the label of the drive (if you set a label for it) and the third column is the UUID of your drives.įirst, you need to know the name of the drive that is going to be automatically mounted. In the output of this command, the first column is the name of your drives. Open your terminal, run the following command to see the name of your drive, its UUID(Universal Unique Identifier) and file system type. Step 1: Get the Name, UUID and File System Type So I’m going to show you an easy way to automount drive in Linux. Mounting drive manually is just a waste of time. So oftentimes I need to mount the mechanical drive in the file manager manually to access my mp3 and video files. I install operating systems on SSD and store files on the mechanical drive. My laptop has one SSD and one mechanical drive. Today I’m going to show you how to automatically mount a drive at boot time in Linux.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |