- 论坛徽章:
- 13
|
There are 3 way to disable the USB storage device on Red Hat Enterprise Linux .
1)
You can add the usb_storage driver to the blacklist.
Add the following line in the file /etc/modprobe.d/blacklist
blacklist usb_storage
Then when you restart the system, the system will not load the usb_storage driver.
2)
You can move the usb_storage.ko driver simply.
# mv /lib/modules/$(uname -r)/kernel/drivers/usb/storage/usb-storage.ko /root/
3)
You can use udev rule to ignore the usb storage plug in / out event .
Create file "ignore_usb_device.rules" in /etc/udev/rules.d/ directory and write the following rules:
# cat /etc/udev/rules.d/ignore_usb_storage.rules
ACTION=="add", bus=="usb", DRIVER=="usb-storage", OPTIONS:="ignore_device"
Then the system will ignore all use storage devices plug in / out event . |
|