I'd like to map an usb drive to a path under ubuntu 16.04. The idea is to use rsync to backup some folders to this usb drive whenever I plug it. Is there any way for the system to recognize the usb drive from its manufacturer id for instance and then map it to a unchanging path?

Thank you!


There is a package called usbmount which looks awesome! https://unix.stackexchange.com/questions/134797/how-to-automatically-mount-an-usb-device-on-plugin-time-on-an-already-running-sy?rq=1

Alternately, you can employ SystemD to help: Automount USB drives with systemd

Initially I would have suggested to use UUID & autofs, there have been a few answers already that might help. Udev rules would work for "when you plug it in", however, that answer is better.




Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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