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

This is a discussion on did anyone know howto auto mount the u disk in embedded linux system - Embedded ; if I insert a U-disk into the device, How can I know the U-disk had inserted? Thank you!...

+ Reply to Thread
Results 1 to 3 of 3

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

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

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



  2. Re: did anyone know howto auto mount the u disk in embedded linuxsystem

    On Oct 10, 6:35 pm, "misty" wrote:
    > if I insert a U-disk into the device, How can I know the U-disk had
    > inserted? Thank you!


    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

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

    misty wrote:

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


    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

+ Reply to Thread