LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Red Hat (https://www.linuxquestions.org/questions/red-hat-31/)
-   -   mount: Not a directory (https://www.linuxquestions.org/questions/red-hat-31/mount-not-a-directory-263350/)

perturbation 12-06-2004 04:22 PM

mount: Not a directory
 
I'm using Red Hat Linux 9, and I'm having problems mounting my CD or disk drive. The CD and disk drive both worked when I installed the system; boot disk booted OK, and installation was from CD.
Now that Red Hat is installed, however, it refuses to auto-mount either the disk drive or the CD ROM (data, music, or whatever, it seems to make no difference), and when I try to mount manually from the terminal, I get this:

[root@localhost home]# mount -t iso9660 /dev/cdrom /mnt/cdrom
mount: block device /dev/cdrom is write-protected, mounting read-only
mount: Not a directory

I've seen posts on various other forums from people with what sounds like the exact same problem. I've seen suggestions of a few different permutations on the above mount command. However...

mount /dev/cdrom -t iso9660 /mnt/cdrom
mount /dev/cdrom -t "iso9660" /mnt/cdrom

..both produce the same result.
I've confirmed that /mnt/cdrom is a directory.
My /etc/fstab file looks like this:

[root@localhost home]# more /etc/fstab
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/hda3 swap swap defaults 0 0
/dev/cdrom /mnt/cdrom udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0

I've tried removing "udf" from the /dev/cdrom entry. I get the same result.

All the other threads I've seen for this problem on other forums peter out before a solution is arrived at. But judging from the number of people who apparently experience this, someone must have a solution. Any ideas anyone?

Thanks

acid_kewpie 12-06-2004 05:25 PM

/mnt/cdrom is presumably not a directory, most likely because it doesn't exist.

perturbation 12-06-2004 09:42 PM

I took the following to mean that /mnt/cdrom is a directory:

[root@localhost cdrom]# pwd
/mnt/cdrom
[root@localhost cdrom]#

My apologies if I'm wrong of that point. Thanks for straightening me out. But do you have ny suggestions to get the CD ROM to mount?

newatthis 12-20-2004 12:49 PM

Ive got the same exact problem. I looked at my /etc/fstab and everythin looks like it should but I cannot mount my cdrom or my floppy. If anyone has any suggestions I would apreciate it.

d.weeks 01-04-2005 10:06 PM

Same problem on Slackware
 
Has anyone worked out what is going on here?

root@test1:/mnt# mount -o ro -t iso9660 /dev/hdc /mnt/cdrom/
mount: Not a directory

I am running Slackware Linux on common PC hardware with IDE drives.
I can boot from the install CD, but when I try to mount the file system things go bad.

/mnt/cdrom/ is definately a directory, by the way.

riluve 01-10-2005 02:35 PM

Well, I wish I could help. I was just thinking when I read this that it doesn't bode well for RedHat Linux or this forum that such a 'common' and 'basic' problem hasn't been addressed.

Just makes me kinda sad

brianko 06-01-2005 01:45 PM

I discovered this little gem that might solve your problem:

Disable DMA on your CDROM:

hdparm -d0 -X /dev/hdc

(or whatever device name your drive might be)

This worked on a Slackware 9.1/10.1 install I was trying to do...

--Brian

bramhastra 06-02-2005 04:37 AM

well according to me default fstab shuld be like this


/dev/hdb5 / ext2 defaults 1 1
/dev/hdb2 /home ext2 defaults 1 2
/dev/hdc /mnt/cdrom iso9660 noauto,ro,user 0 0
/dev/hda1 /mnt/dos/c msdos defaults 0 0
/dev/hdb1 /mnt/dos/d msdos defaults 0 0
/dev/fd0 /mnt/floppy ext2 noauto,user 0 0
/dev/hdb4 none ignore defaults 0 0

none /proc proc defaults
/dev/hdb3 none swap sw



well u can also try to use the command mount -t auto /mnt/cdrom

brianko 06-02-2005 07:26 PM

The original poster had this to say:

---

mount /dev/cdrom -t iso9660 /mnt/cdrom
mount /dev/cdrom -t "iso9660" /mnt/cdrom

..both produce the same result.
I've confirmed that /mnt/cdrom is a directory.

---

So it doesn't matter what is in /etc/fstab, because that file isn't consulted when attempting a mount command which contains both the device filename and the mountpoint.

rajivb 06-05-2005 12:21 AM

i think this problem has nothing to do with /etc/fstab because i have my CD-ROM, CD-RW, floppy drives working right.

/mnt/cdrom is a directory if a cdrom is installed

i don't know why this problem has come but if anybody wants to compare any other data to sort this out , i am always available.

brianko 06-05-2005 12:59 AM

Have you tried disabling the DMA as in the previous post?

hdparm -d0 -X /dev/hdc (or whatever your device is...)

rajivb 06-05-2005 02:20 AM

i didn't have a problem from the start. It was working right from start brianko.

brianko 06-05-2005 08:50 AM

My bad, should have followed the thread more closely. I believe we're both in agreement that this problem has nothing to do with /etc/fstab...

Ogi 06-25-2005 09:19 AM

I got exactly the same problem, execept that i am trying to mount a loopback filesystem

mount /image.iso /mnt/temp -o loop

gives me exactly the same error. I know that /mnt/temp is a directory.

It is really strange, any tips anyone?

Cheers

Khen1950fx 06-26-2005 12:47 AM

re: mount not a directory
 
I was getting a "mount not a directory' message. I tried editing /etc/fstab, and I used hdparm---but I still had the same results. I tried a different cd, and then the cdrom mounted. Evidently, the "mount not a directory" message is the result of a bad disk or one with errors. I hope the helps(smile).


All times are GMT -5. The time now is 01:34 PM.