did anyone know howto auto mount the u disk in embedded linux system

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
if I insert a U-disk into the device, How can I know the U-disk had
inserted? Thank you!



Re: did anyone know howto auto mount the u disk in embedded linux system
Quoted text here. Click to load it

you can type "dmesg" after you insert a u-disk , to  find the dev name
of the u-disk
and type  mount command
for example:
      mount /dev/sda /mnt/usb
     /mnt/usb is your mount point
     sda is the dev name of the u-disk

Re: did anyone know howto auto mount the u disk in embedded linux system

Quoted text here. Click to load it

Create a udev rule that starts a specific programm and/or shell script when
one insert a USB mass storage device:

KERNEL=="sd[a-z]*", SUBSYSTEMS=="usb", RUN+="/bin/bash
/usr/local/sbin/do_something"

In the "do_something" script you can do whatever you want.

jbe

Site Timeline