LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Automounting { if present } (https://www.linuxquestions.org/questions/linux-newbie-8/automounting-%7B-if-present-%7D-86995/)

Yocal 08-29-2003 11:28 AM

Automounting { if present }
 
Hi,

Im mounting my maxtor-firewire disk using this command:

mount -t vfat -o defaults,umask=0,quiet /dev/sda1 /mnt/removable

Great - it works very fine... But - i would like to mount it every time i boot... Or my goal is (info: using RH9):

- Boot
- Check if disk is present (how??)
- If present, mount it using the above command.
- Tada

Is that some weird kind of scripting - or is there an easy way to do it :scratch:


// Yoc.

MasterC 08-29-2003 11:37 AM

Actually, fstab will do that for you ;)

Code:

/dev/sda1  /mnt/removable  vfat  defaults,umask=0,quiet,auto  0  0
Should suffice as an entry in /etc/fstab

Cool

aaa 08-29-2003 11:41 AM

You should add an entry in your /etc/fstab file. It works like this (an example):
#device- mnt point- fs type-options- dump-pass
/dev/sda1 /mnt/removable vfat defaults,umask=0,quiet 0 0

Yocal 08-29-2003 11:44 AM

Hi,

Thanks! It seems to work :)

I just love this quick-replying forum ;)


All times are GMT -5. The time now is 07:10 PM.