Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

How can I stop CentOS 5.3 from trying to mount my CD-ROM drives during boot?

What will it affect if I disable it? Will my USB Drives still automount?

Additional Information

There is no entries in the fstab or mtab to automount the drives. It is the first place I checked. Also a grep of the etc and underlying directories for /media/cdrom did not bring up anything remotely useful in this regard.

The machine is not running a GUI, no X-Windows installed. It also doesn't have autofs installed.

CentOS is trying to mount both my internal and external drives. There is no discs in them so these fail, however I want to stop the process altogether.

share|improve this question
    
Also, are you running a gui? –  geeklin Sep 14 '09 at 21:16
    
No Gui. Base install and no X. This is a headless server and there was no need for it. –  Diago Sep 14 '09 at 21:47
add comment

3 Answers

up vote 1 down vote accepted

I was under the impression that was handled via hald.

Maybe not, but another option (presuming you don't need them), would be to just disable them via your server's BIOS. I've done that when I wanted to hold onto the drive, but not have it active in the system.

share|improve this answer
    
@warren It think you may be on the right track. I am going through the process now to find a way to stop it using an fdi file. –  Diago Sep 18 '09 at 13:21
    
I believe that it it handled via a udev rule. –  fpmurphy1 Sep 18 '09 at 14:08
add comment

Just remove this line from /etc/fstab

/dev/hda                /media/cdrom            auto    pamconsole,exec,noauto,managed 0

Or better yet, just comment it out. #

share|improve this answer
    
I would love to. Except it is not there. It was the first place I looked, both in mtab and fstab. I have no idea where it is picking up the mounts which is the reason for the question. I will update accordingly. –  Diago Sep 14 '09 at 20:30
    
Strange, I'm guessing autofs is mounting it automatically. –  geeklin Sep 14 '09 at 21:08
    
autofs is not installed either. Was about to check on that and realised it wasn't one of the packages I installed as I didn't need it. –  Diago Sep 14 '09 at 21:50
add comment
fuser /dev/cdrom

should get you started figuring out what process is attached to it....I woulda guessed autofs as well...

share|improve this answer
    
interesting problem. I second the use of fuser to try to get some idea of what could be going one. Is there anything in /var/log/messages? –  egorgry Sep 15 '09 at 0:42
    
The problem is there is no disc in the drive, it fails to mount due to this. I want to stop it from happening completely. –  Diago Sep 15 '09 at 7:16
    
I guess I'm kinda confused as to why you would want to, but when BIOS informs the system that there's a drive there, it's going to try to spin it up to see whether or not to mount it. I'm not sure exactly where in system bootup that occurs, but if you really want to disable it, perhaps turning off the drive in BIOS? –  Greeblesnort Sep 17 '09 at 2:02
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.