How to automatically mount the hard disk

By December 9, 2016Tutorials

Use the mount command to mount the hard disk in the reboot and will not be automatically mounted, if you need to boot automatically mount the hard disk you can use the following methods.

When the system start run will automatically read the /etc/fstab, the file a total of six parameters are as follows:
<file system>         <dir>           <type>     <options>      <dump>      <pass>

/dev/sdb1                /mnt              ext3          defaults             0                  0
The above is an example of a simple set boot disk.

"file system":Indicating the name of the device to be mounted, block information or label, you can usually mount the device name like /dev/sdb1.
"dir":Indicates the mount point, which is the directory where you want to mount the device, such as /mnt, /media, or another custom folder.
"type":Said the file system format, such as ext3, ext4.
"options":Operating parameters, the default can be filled defaults.
"auto": The system automatically mount, fstab default is this option.
"noauto": Don't automatically mount.
"defaults": Contain rw,suid,dev,exec,auto,nouser,async.
"nouser":Only superuser can mount.
"user":Evary users can mount.
"ro": mount for only read.
"rw":mount for only read and write.
"dump":The value of the dump tool can be used to decide when to make a backup, 0 means that the backup "1", usually no need to default to fill "0".
"pass":Indicates whether the boot sector, where the fill 0 is not checked. Root partition must be filled in here "1" other can not fill in "1". The other partitions check the numbers starting at "2".
The smaller the priority, the number of the same partition at the same time check, usually no default can fill 0.


Leave a Reply