Jump to content

/mnt/cdrom always showing same


sofasurfer
 Share

Recommended Posts

I had my home directory stored on a rw/cd. I view it in konqueror or midnight commander or terminal and it shows my home directory. Then I erased the cd. Viewed in all of the above methods it still shows 'home'. I put another cd in and it still shows 'home'. Whats going on? Am I not reading the cds or what? I know how to follow a path to my cdrom. Its like my path of /mnt/cdrom is actually going to / home.

 

 

[moved from Software by spinynorman]

Link to comment
Share on other sites

From the command prompt, try:

 

umount /mnt/cdrom

 

and then check to see if anything is listed here. If it is, check to see if /mnt/cdrom is a directory or symlink:

 

ls -l /mnt/cdrom

 

and see if it's pointing to a specific directory or not.

Link to comment
Share on other sites

I did this...

[root@localhost daryl]# umount /mnt/cdrom

umount: /mnt/cdrom: not mounted

 

I then put a blank cd in the drive. Browsed to /mnt/cdrom in konqueror and it still shows my home directory. Then I did a 'ls -l /mnt/cdrom' in terrminal and it listed my home directory.

 

No when I type "mount /mnt/cdrom" I get this message...

mount: wrong fs type, bad option, bad superblock on /dev/hdc,

or too many mounted file systems

 

The Linux Newbie Guide give this info on the mount command...

mount /mnt/cdrom

(as user or root) Mount a CD as user. The file /etc/fstab must be set up to do this. The directory /mnt/cdrom must not be your current directory.

I've edited fstab before, what is needed to be "set up" for this?

Link to comment
Share on other sites

OK, I need to see more info. Please post the results from these commands:

 

ls -l /mnt

 

also, post the results from this:

 

cat /etc/fstab

 

and:

 

mount

Link to comment
Share on other sites

[daryl@localhost daryl]$ ls -l /mnt

total 20

drwxr-xr-x 3 root root 4096 Mar 13 02:09 cdrom/

drwxrwxrwx 0 root root 0 Mar 13 02:13 floppy/

drwxrwxrwx 12 root root 16384 Dec 31 1969 windows/

------------------------------------------------------------------------

[daryl@localhost daryl]$ cat /etc/fstab

/dev/hda9 / ext3 defaults 1 1

/dev/hda5 /Archive ext3 defaults 1 2

none /dev/pts devpts mode=0620 0 0

/dev/hda6 /home ext3 defaults 1 2

/dev/hdc /mnt/cdrom supermount umask=0,user,iocharset=iso8859-1,codepage=850,noauto,ro,exec,users 0 0

none /mnt/floppy auto dev=/dev/fd0,fs=ext2:vfat,--,umask=0,iocharset=iso8859-1,sync,codepage=850 0 0

/dev/hda1 /mnt/windows vfat umask=0,iocharset=iso8859-1,codepage=850 0 0

none /proc proc defaults 0 0

/dev/hda7 /usr ext3 defaults 1 2

/dev/hda8 /var ext3 defaults 1 2

/dev/hda10 swap swap defaults 0 0

------------------------------------------------

[daryl@localhost daryl]$ mount

/dev/hda9 on / type ext3 (rw)

none on /proc type proc (rw)

none on /proc/bus/usb type usbfs (rw)

none on /sys type sysfs (rw)

/dev/hda5 on /Archive type ext3 (rw)

/dev/hda6 on /home type ext3 (rw)

none on /mnt/floppy type supermount (rw,sync,dev=/dev/fd0,fs=ext2:vfat,--,umask=0,iocharset=iso8859-1,codepage=850)

/dev/hda1 on /mnt/windows type vfat (rw,umask=0,iocharset=iso8859-1,codepage=850)

/dev/hda7 on /usr type ext3 (rw)

/dev/hda8 on /var type ext3 (rw)

Link to comment
Share on other sites

In your /etc/fstab, change your line so it matches this:

 

/dev/hdc /mnt/cdrom auto umask=0,user,iocharset=iso8859-15,codepage=850,noauto,ro,exec,users 0 0

 

I think this is why you're having problems.

Link to comment
Share on other sites

This made no differance.

I put a blank cd in and it tells me I have the one with the home directory.

I put a music cd in and the media player did not come up. I called up media player manually and it will play the cd. The cd icon does not come up on the decktop when I cd is put in.

When I have a music cd in and browse to /mnt/cdrom it still tells me I have the home directory.

Link to comment
Share on other sites

try deleting the /mnt/cdrom directory as root, and then recreating it.

 

also, have you rebooted the system since this problem started occuring?

 

you should see nothing when a music cd is in the directory, as a music cd can't be mounted since it has no filesystem.

Link to comment
Share on other sites

It appears that deleting the cdrom directory and recreating it did the trick. Did I accidently copy my home directory into the cdrom directory. From the point of veiw of a person who doesn't know very much I would say this is what happened.

 

Now however, I tried to save my home directory to cd again (using midnight commander as root) and I get this error...'Cannot create target directory '/mnt/cdrom/home' Read-only file system (30).

I dug down into my home directory and was able to save another file into my /home/tmp directory. What is the above error telling me?

Link to comment
Share on other sites

It's basically telling you that your /mnt/cdrom/home directory is read-only because the CD has probably been mounted in read-only mode. You can try to remount in rw:

 

mount /dev/hdc -o remount.rw

 

assuming that your cdrom is /dev/hdc, and then trying again.

Link to comment
Share on other sites

Woops! I had too many /s at the beginning of my /dev/cdrom line. Its fixed now.

 

So, I just copied my home directory to a cd again. I then took the cd out and inserted a blank cd. When K3b started it showed my home directory, just like before.

 

Well, I gotta go to work. I'll study on this later on.

Edited by sofasurfer
Link to comment
Share on other sites

how are you copying your home directory to CD? you can't just copy it, you have to burn it with a burning program such as K3B...

 

if you just copy the home directory into /mnt/cdrom it will just write it into that directory. that was the problem you were having before, it seems - it was writing it to the /mnt/cdrom directory not to the actual cd in the drive.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...