Search This Blog

Monday 9 January 2017

Disable USB storage device in Ubuntu

gksudo gedit /etc/modprobe.d/blacklist.conf  

enter image description here

When it opens add blacklist usb_storage as the last line, then with the command below open the rc.local file

gksudo gedit /etc/rc.local  

When it opens, add modprobe -r usb_storage before the line exit 0

enter image description here

Now go ahead and reboot your system.

To mount, open a Terminal and use the following command.

sudo modprobe usb_storage  

To Unmount the USB device, just right click on the device in file manager, and choose safley remove, or Unmount device, and run

sudo rmmod usb_storage  

No comments:

Post a Comment