LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   mounting question (https://www.linuxquestions.org/questions/linux-hardware-18/mounting-question-631370/)

andy1974 03-28-2008 06:10 PM

mounting question
 
ok i have a question about a failing drive on my system and how it is mounted..

i have the drive set up in fstab to mount on boot like this

/dev/sdb1 /mnt/drive1 ext3 defaults 1 2

however if the drive fails it will hault the boot. is there a way to set it up to still allow boot even the drive is dead or not there??

also if the drive does fail .....how do i get to edit the fstab from command line to get the system back up till the drive is replaced. i feel that day is comming soon ....i ordered a new drive however i would like to know the answers to these questions. Any help would be great.

jailbait 03-28-2008 06:27 PM

Quote:

Originally Posted by andy1974 (Post 3103578)

i have the drive set up in fstab to mount on boot like this

/dev/sdb1 /mnt/drive1 ext3 defaults 1 2

however if the drive fails it will hault the boot. is there a way to set it up to still allow boot even the drive is dead or not there??

Change your fstab entry to:

/dev/sdb1 /mnt/drive1 ext3 noauto,user 1 2

(If you only allow root access then take out the user parameter.)

Quote:

Originally Posted by andy1974 (Post 3103578)

if the drive does fail .....how do i get to edit the fstab from command line to get the system back up till the drive is replaced.

Boot a live CD and edit /etc/fstab from the live CD.

----------------
Steve Stites

andy1974 03-28-2008 06:48 PM

ok i will try that

andy1974 03-28-2008 07:05 PM

nah that didnt work

Bad format on line 10

i added that line then rebooted after unpluging hard drive

jschiwal 03-28-2008 08:25 PM

Try:
/dev/sdb1 /mnt/drive1 ext3 defaults,noauto,user 0 0

The "user" isn't necessary if you will try to mount it as root. Who is the owner of the filesystem? If it is root, then delete ",user".

See the mount manpage for details on the mount options.

If you unplugged the drive, then your drive assignments may have changed. A hard disk that used to be /dev/sdc might then be /dev/sdb.

michaelk 03-28-2008 08:45 PM

Quote:

Bad format on line 10
Looks like something is wrong in your fstab file. Make sure you do not have any blank lines at the end of the file. There also needs to be a LF on the last entry too.

andy1974 03-29-2008 09:14 AM

Quote:

Originally Posted by jschiwal (Post 3103641)
Try:
/dev/sdb1 /mnt/drive1 ext3 defaults,noauto,user 0 0

The "user" isn't necessary if you will try to mount it as root. Who is the owner of the filesystem? If it is root, then delete ",user".

See the mount manpage for details on the mount options.

If you unplugged the drive, then your drive assignments may have changed. A hard disk that used to be /dev/sdc might then be /dev/sdb.

/dev/sdb1 /mnt/drive1 ext3 defaults,noauto 0 0

worked ......what does the 0 0 do ?

andy1974 03-30-2008 05:06 PM

jailbait
 
i wanted you to clearify somthing you said...you said

Boot a live CD and edit /etc/fstab from the live CD.

could you explain how i would go about that ?

jailbait 03-30-2008 06:31 PM

Quote:

Originally Posted by andy1974 (Post 3105268)
Boot a live CD and edit /etc/fstab from the live CD.

could you explain how i would go about that ?

Pretty much all distributions come with a bootable install CD which also can be used as a live CD. So boot your installation CD into live CD mode (some call it rescue mode) and get a command prompt. Then mount your Linux partition. Let's say that you have Linux installed on /dev/sda3 and that you are using ext3:

mkdir /sparrow
mount -t ext3 /dev/sda3 /sparrow

You need to use one of the editors installed on the live CD. vim is the almost universal editor on live CDs, so:

vim /sparrow/etc/fstab

make the necessary changes to fstab and save it. umount /sparrow to make sure the cache is flushed before you reboot:

umount /sparrow

----------------------
Steve Stites

andy1974 04-01-2008 08:31 AM

need to be mounted at startup?
 
well lets dig a bit deeper......would i have to have to mount /dev/sdb1 in fstab to use samba ?? the samba share is on /mnt/data

only make sence i would have to have it fstab i dont want to have to mount it manually

the os is Fedora 8, seems to mount auto anyway, regaurdles of fstab


All times are GMT -5. The time now is 01:47 AM.