1

I want to disable CDROM/CDRW/DVDROM/DVDRW for everyone in Ubuntu 14.04.1 desktop 64-bit edition.

I have tried following but not worked:

  1. Removed user from /etc/group, as following: cdrom:x:24:

    as defined at Permanently disable CD drive

  2. Defined rules in /etc/udev/rules.d/71-cdrom-block.rules and /lib/udev/rules.d/71-cdrom-block.rules as follows:

    ENV{UDISKS_SYSTEM}="1", ENV{UDISKS_AUTO}="0", ENV{UDISKS_SYSTEM_INTERNAL}="1",         ENV{UDISKS_AUTOMOUNT_HINT}="never"
    

    as defined at https://superuser.com/questions/693155/disable-device-node-using-udev-dev-sr0

But still I am able mount the CD-ROM. Kindly help how to disable it for everyone.

Vijay Singh
  • 21
  • 1
  • 2

1 Answers1

0

Can you do this to change the permissions of the drive to root only

sudo chmod 700 /media/path/to/your/DVDRom

Your mount point is in /media/DVDdrivenamehere

This will make it requier root password and

sudo chmod 777 /media/path/to/your/DVDRom

Will allow full accsess againg

To disable DVD auto-play open system settings and go to details

On the left choose removable media, you can easily set auto-play parameters. from here

Mark Kirby
  • 18,289
  • 19
  • 78
  • 113
  • I am getting error while running# "sudo fstab nouser" command Error : "sudo: fstab: command not found" Which package is needed to install fstab command in 14.04.1 ? – Vijay Singh Aug 27 '14 at 07:06
  • sudo apt-get install fstab, it should be installed. – Mark Kirby Aug 27 '14 at 07:08
  • If that does not work sudo chmod +x /etc/fstab.d and try again – Mark Kirby Aug 27 '14 at 07:10
  • Still fstab command not worked.
    # sudo chmod +x /etc/fstab.d # sudo fstab nouser sudo: fstab: command not found # ls -l /etc/fstab.d total 0 # cd /etc/fstab.d/ :/etc/fstab.d# ls :/etc/fstab.d# ls -l total 0
    – Vijay Singh Aug 27 '14 at 07:28
  • New answer for you – Mark Kirby Aug 27 '14 at 07:29
  • Now user is not able to mount CDrom but getting display error "Unable to open a folder for....No application is registred as handling this file". Can be it done silently. – Vijay Singh Aug 27 '14 at 07:50
  • I dont know what you meen silently you said you wanted it disabled for ALL user only root can mount the drive. – Mark Kirby Aug 27 '14 at 07:55
  • Actually doing chmod 700 to /mount folder block others users to mount cdrom but whenever anyone insert cdrom Ubuntu OS try to automount the media and dues to rights issue it gives message to user. How can I disable automount facility also. – Vijay Singh Aug 27 '14 at 08:04
  • Ok thanks for the clarification, I will update myanswer – Mark Kirby Aug 27 '14 at 08:05