LinuxQuestions.org
Help answer threads with 0 replies.
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 09-24-2003, 05:29 AM   #1
Riichard
Member
 
Registered: Sep 2003
Location: 3rd Rock
Distribution: Mepis 6.5.02
Posts: 106

Rep: Reputation: 15
fstab


My cd drives dont work
Is my fstab file correct ?

LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
/dev/hdb3 swap swap defaults 0 0
 
Old 09-24-2003, 05:33 AM   #2
ceedeedoos
Member
 
Registered: Aug 2003
Location: Antwerp, Belgium
Distribution: Slackware 10.0, Mandrake 10.1
Posts: 174

Rep: Reputation: 35
they're not in there I think ...
you can try to find out this command to see which are your cd drives

fdisk -l /dev/hd*

should give you a list of all devices on hd* ... then add appropriate lines in fstab
 
Old 09-24-2003, 05:41 AM   #3
Riichard
Member
 
Registered: Sep 2003
Location: 3rd Rock
Distribution: Mepis 6.5.02
Posts: 106

Original Poster
Rep: Reputation: 15
I get
bash: fdisk: command not found ?
 
Old 09-24-2003, 05:48 AM   #4
ceedeedoos
Member
 
Registered: Aug 2003
Location: Antwerp, Belgium
Distribution: Slackware 10.0, Mandrake 10.1
Posts: 174

Rep: Reputation: 35
my bad
you have to be root for that ..
su
fdisk -l /dev/hd*
exit

sorry

ps: l is little L just to make sure

Last edited by ceedeedoos; 09-24-2003 at 05:50 AM.
 
Old 09-24-2003, 06:15 AM   #5
Riichard
Member
 
Registered: Sep 2003
Location: 3rd Rock
Distribution: Mepis 6.5.02
Posts: 106

Original Poster
Rep: Reputation: 15
I'm having problems
# fdisk
bash: fdisk: command not found
# fdisk _1
bash: fdisk: command not found
# fdisk -l
bash: fdisk: command not found
# fdisk -l/dev/hd
bash: fdisk: command not found
# fdisk
bash: fdisk: command not found
# fdisk -l/dev/hdd
bash: fdisk: command not found
 
Old 09-24-2003, 06:56 AM   #6
MadNewbie
Member
 
Registered: Jun 2003
Posts: 31

Rep: Reputation: 15
fdisk is normally located in sbin/ and it is probably not in your path so you have to type /sbin/fdisk to make it work.
 
Old 09-24-2003, 08:07 AM   #7
michaelk
Moderator
 
Registered: Aug 2002
Posts: 16,430

Rep: Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938
fdisk will not show CD drives.

What distro / version are you running?

What kind of CD drives do you have? IDE, USB, SCSI, PCMCIA, firewire?

If the are IDE then try as root:
mount -t iso9660 /dev/hdx /mnt/cdrom

where hdx:
IDE #1
master - hda
slave - hdb
IDE #2
master - hdc
slave - hdd

/mnt/cdrom or any existing empty directory to mount the drive to.

Use mkdir to create a directory.
 
Old 09-24-2003, 12:17 PM   #8
Riichard
Member
 
Registered: Sep 2003
Location: 3rd Rock
Distribution: Mepis 6.5.02
Posts: 106

Original Poster
Rep: Reputation: 15
The CD/DVD drives are on the secondary ide channel
I'm using Red Hat 9
Ive had a look at the linux hardware browser;
Lite-on LTR-24102B
Driver: None or built in
Device: /dev/scd0
And
Toshiba DVD-ROM SD-R1002
Driver: None or built in
Device: /dev/hdd
 
Old 09-24-2003, 12:22 PM   #9
aaa
LQ Guru
 
Registered: Jul 2003
Location: VA
Distribution: Slack 10.1
Posts: 2,194

Rep: Reputation: 46
Add these lines to your fstab:
#device mnt-point fs-type options dump pass
/dev/scd0 /mnt/cdrom iso9660 user,defaults 0 0
/dev/hdd /mnt/cdrom1 iso9660 user,defaults 0 0
 
Old 09-24-2003, 03:19 PM   #10
Riichard
Member
 
Registered: Sep 2003
Location: 3rd Rock
Distribution: Mepis 6.5.02
Posts: 106

Original Poster
Rep: Reputation: 15
Ive just added one device to get familiar with this

LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /proc proc defaults 0 0
none /dev/shm tmpfs defaults 0 0
/dev/hdb3 swap swap defaults 0 0
#device mnt-point fs-type options dump pass
/dev/scd0 mnt/cdrom iso9660 user,defaults 0 0


The bold bit is what I 've added, I think I saved it correctly but...
Now when i boot i get
No final new line at end of etc/fstab.
 
Old 09-24-2003, 05:30 PM   #11
michaelk
Moderator
 
Registered: Aug 2002
Posts: 16,430

Rep: Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938
Just edit the file and move the cursor to the end the end of the last line and press the enter key.

BTW any line that start with a # is a comment.
 
Old 09-24-2003, 05:35 PM   #12
Skyline
Senior Member
 
Registered: Jun 2003
Distribution: Debian/other
Posts: 2,104

Rep: Reputation: 45
Quote:
I get
bash: fdisk: command not found ?
For Red Hat and fdisk - l /dev/hdX

you need a diiferent way of suing to root user ie

su -

(su dash)
 
Old 09-24-2003, 06:16 PM   #13
aaa
LQ Guru
 
Registered: Jul 2003
Location: VA
Distribution: Slack 10.1
Posts: 2,194

Rep: Reputation: 46
The commented-out line would be better at the top. It's just for reference.
 
Old 09-25-2003, 06:36 AM   #14
Riichard
Member
 
Registered: Sep 2003
Location: 3rd Rock
Distribution: Mepis 6.5.02
Posts: 106

Original Poster
Rep: Reputation: 15
Thanks all.
Ive got my first cd drive to (sort off) work
Got rid of the 'No final new line at end of etc/fstab' problem
But have another question.
When the computer boots I get
mount: : dev/scd0 is not a valid block device ?
and should a mounted audio cd appear on desktop?
 
Old 09-25-2003, 08:47 AM   #15
michaelk
Moderator
 
Registered: Aug 2002
Posts: 16,430

Rep: Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938Reputation: 1938
You need to include the noauto as an option. This will keep the OS from trying to mount a CD on boot. see man pages for fstab and mount for additional help.

/dev/scd0 mnt/cdrom iso9660 noauto,user,defaults 0 0

Since you can't mount an audio CD it will not appear on the desktop.
 
  


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
newbie vs fstab. fstab wins :( blop Linux - Newbie 3 01-07-2005 06:54 AM
What is fstab? sceadu Linux - Newbie 2 11-02-2004 08:25 PM
(version 5.1 chapter 08 fstab) vs (man fstab) rgiggs Linux From Scratch 2 06-03-2004 06:55 PM
Help with /etc/fstab wawosz Linux - General 3 04-24-2003 03:12 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:28 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