LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-09-2004, 03:45 PM   #1
chongluo
Member
 
Registered: Mar 2004
Location: uk
Distribution: fedora2, slackware10
Posts: 54

Rep: Reputation: 15
edit fstab to mount a second harddrive


hi,
I'm running slackware 10. here is my problem, I want my second harddrive to be mounted automatically when the system boots up and every user will be able to read and write to the partition, so I edited the /etc/fstab file with following extra line:

/dev/hdc1 /home/chongluo ext3 umask=000 0 0

so here is the fstab file looklike now:

/dev/hda1 swap swap defaults 0 0
/dev/hda2 / reiserfs defaults 1 1
/dev/hdc1 /home/chongluo ext3 umask=000 0 0
/dev/cdrom /mnt/cdrom iso9660 noauto,owner,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0

however, this does not work, the partition is not mounted when the system boots up, am I missing something?

please kindly advise?
 
Old 10-09-2004, 03:49 PM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974Reputation: 1974
use the same options as hda2, i.e. "defaults 1 1", offhand it looks fine other than that....
 
Old 10-09-2004, 04:30 PM   #3
chongluo
Member
 
Registered: Mar 2004
Location: uk
Distribution: fedora2, slackware10
Posts: 54

Original Poster
Rep: Reputation: 15
no, I made the changes, still not working, the partitions is still not mounted at boot up

here the fstab after I made the change:

/dev/hda1 swap swap defaults 0 0
/dev/hda2 / reiserfs defaults 1 1
/dev/cdrom /mnt/cdrom iso9660 noauto,owner,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner 0 0
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0
/dev/hdc1 /home/chongluo ext3 umask=000 1 1


I cann't see what is wrong with it
 
Old 10-09-2004, 10:27 PM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 14,931

Rep: Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520
Well, for one thing you do not need the umask option for an ext3 partition.

Try to mount the partiton manually. If that fails post the error messages. Like:
mount -t ext3 /dev/hdc1 /home/chongluo

Are you sure the second drive is located on the 2nd IDE controller master slot? Does the BIOS & OS recognize the drive. Look at the output of the dmesg command to verify.
 
Old 10-10-2004, 08:33 AM   #5
chongluo
Member
 
Registered: Mar 2004
Location: uk
Distribution: fedora2, slackware10
Posts: 54

Original Poster
Rep: Reputation: 15
I'm able to mount the partition manually, using the mount command. and obviously I'm sure the ext3 partition is connected to secondary master.

so I used the command dmesg to see what is there:
.......

EXT3-fs: Unrecognized mount option umask

.....
EXT3 FS 2.4-0.9.19, 19 August 2002 on ide1(22,1), internal journal
EXT3-fs: mounted filesystem with ordered data mode.

I think the umask is causing the problem, but I want to every user be able to read, write and execute to the partition when it is mounted, so how can I do that without using umask???
please advise
 
Old 10-10-2004, 09:51 AM   #6
michaelk
Moderator
 
Registered: Aug 2002
Posts: 14,931

Rep: Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520Reputation: 1520
Use the chmod command to change the permissions of the /home/chongluo (unmount the filesystem first).

BTW
Is chongluo is a regular user?

Are there any existing files in /home/chongluo? If so once /dev/hdc1 is mounted any existing files in that directory will not be accessible.

The man pages for fstab and mount describ the options for each filesystem. umask is an a valid option for a ext3 filesystem.
 
Old 10-10-2004, 12:50 PM   #7
chongluo
Member
 
Registered: Mar 2004
Location: uk
Distribution: fedora2, slackware10
Posts: 54

Original Poster
Rep: Reputation: 15
the problem is that the /dev/hdc1 is not mounted when it boots up, I have to mannually mount it use 'mount' command

I want the partition mounted when the system boots up, see my fstab above, it doesn't work
 
Old 10-10-2004, 01:27 PM   #8
egag
Senior Member
 
Registered: Jul 2004
Location: Netherlands
Distribution: Slackware
Posts: 2,721

Rep: Reputation: 52
hi,
-----------
/dev/hdc1 /home/chongluo ext3 umask=000 1
-----------

should read:
---------
/dev/hdc1 /home/chongluo ext3 rw,user,exec 1 2
---------
works fo me...
( and do a "chmod 770 /home/chongluo " )

egag
 
Old 10-10-2004, 06:16 PM   #9
chongluo
Member
 
Registered: Mar 2004
Location: uk
Distribution: fedora2, slackware10
Posts: 54

Original Poster
Rep: Reputation: 15
thanks, eaga, it works for me now
 
Old 10-10-2004, 06:59 PM   #10
egag
Senior Member
 
Registered: Jul 2004
Location: Netherlands
Distribution: Slackware
Posts: 2,721

Rep: Reputation: 52
ok, happy to hear...

good luck with linux...

egag
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
fstab problem: mount: can't find dvd in /etc/fstab or /etc/mtab Nikon01 Slackware 5 11-17-2006 07:15 AM
fstab edit craigers Linux - Software 15 12-03-2004 07:02 AM
Help me edit my fstab Slovak Slackware 3 11-26-2004 11:12 AM
how to edit harddrive information Jalalabee General 2 01-19-2004 01:59 PM
edit fstab - what i ve to do ? thinkdifferent Linux - Newbie 4 12-23-2003 05:20 PM


All times are GMT -5. The time now is 08:18 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration