# UDEV: device names are changing

## Dominique_71

I have a few USB devices: 2 drives, one with 3 partitions, the other with 1 partition, 1 camera and 1 mp3 player YP-K3. All are using the USB Mass Storage support. All the USB stuffs and fs types are compiled directly into the kernel.

I want the 2 drives to be checked by fsck and mounted at boot time. That is working fine. They also are correctly unmounted  at shutdown.

The problem is that, when I plug in the MP3 player, it get recognized and mounted, but at the same time, the device in /dev for one of the drives (the b drive) is changed. The symlink in /dev is changed accordingly, but the result is that this drive get unmounted.

```
# cat /etc/fstab

/dev/usbdrivea1      /mnt/usbdisk_2  reiserfs   auto,noatime,notail,exec 1 2

/dev/usbdrivea2      /mnt/usbdisk_1   ext2      auto,noatime,exec 1 2

/dev/usbdrivea3      /mnt/usbdisk   reiserfs   auto,noatime,notail,exec 1 2

/dev/usbdriveb1      /mnt/usb   reiserfs   auto,noatime,notail,exec 1 2

/dev/usbK31      /mnt/K3      vfat      noauto,user   0 0

```

```
# cat /etc/udev/rules.d/10-local.rules

# Drives

SUBSYSTEMS=="usb", ATTRS{serial}=="200711020016023C", KERNEL=="sd?", NAME="%k", SYMLINK="usbdriveb"

SUBSYSTEMS=="usb", ATTRS{serial}=="200711020016023C", KERNEL=="sd?1", NAME="%k", SYMLINK="usbdriveb1"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?", NAME="%k", SYMLINK="usbdrivea"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?1", NAME="%k", SYMLINK="usbdrivea1"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?2", NAME="%k", SYMLINK="usbdrivea2"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?3", NAME="%k", SYMLINK="usbdrivea3"

# YP-K3

SUBSYSTEMS=="usb", ATTRS{serial}=="260D7456000028040853918BF0041F04", KERNEL=="sd?1", NAME="%k", SYMLINK="usbK3"

```

Is it some way to tell UDEV to use "fixed" devices in /dev or some other way to make sure that those drives will not be unmounted when I plug in the mp3 player or the camera?Last edited by Dominique_71 on Wed Mar 26, 2008 5:24 pm; edited 1 time in total

----------

## venquessa2

KERNEL=="sd?1"

Try setting that to

KERNEL=="mp3?1"

The consequence is that programs looking for /dev/sd?? devices will not see it.

*I should point out I've never tried this before, but in theory it shoud name your mp3 player /dev/mp3a1

----------

## Dominique_71

 *venquessa2 wrote:*   

> KERNEL=="sd?1"
> 
> Try setting that to
> 
> KERNEL=="mp3?1"

 

Thanks, but that doesn't work. The device for the drive get changed and the mp3 is on /dev/sdo.

----------

## Dominique_71

I try to modify the udev rules:

```
# Drives

SUBSYSTEMS=="usb", ATTRS{serial}=="200711020016023C", KERNEL=="sd?", NAME=sdb", SYMLINK="usbdriveb"

SUBSYSTEMS=="usb", ATTRS{serial}=="200711020016023C", KERNEL=="sd?1", NAME="sdb1", SYMLINK="usbdriveb1"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?", NAME="sda", SYMLINK="usbdrivea"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?1", NAME="sda1", SYMLINK="usbdrivea1"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?2", NAME="sda2", SYMLINK="usbdrivea2"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?3", NAME="sda3", SYMLINK="usbdrivea3"

# YP-K3

SUBSYSTEMS=="usb", ATTRS{serial}=="260D7456000028040853918BF0041F04", KERNEL=="sd?", NAME="sdc", SYMLINK="usbK3"

SUBSYSTEMS=="usb", ATTRS{serial}=="260D7456000028040853918BF0041F04", KERNEL=="sd?1", NAME="sdc1", SYMLINK="usbK31"

```

and fstab:

```
/dev/sda1      /mnt/usbdisk_2  reiserfs   auto,noatime,notail,exec 1 2

/dev/sda2      /mnt/usbdisk_1   ext2      auto,noatime,exec 1 2

/dev/sda3      /mnt/usbdisk   reiserfs   auto,noatime,notail,exec 1 2

/dev/sdb1      /mnt/usb   reiserfs   auto,noatime,notail,exec 1 2

/dev/usbK31      /mnt/K3      vfat      noauto,user   0 0

```

After the boot, when the mp3 is not plugged, I get that:

```
# ls -lR /dev/disk

...

/dev/disk/by-id:

total 0

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 ata-IBM-DTLA-307030_YK0YKT66062 -> ../../hda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 ata-IBM-DTLA-307030_YK0YKT66062-part1 -> ../../hda1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 ata-MAXTOR_STM3250820A_6RT0066D -> ../../hdb

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 ata-MAXTOR_STM3250820A_6RT0066D-part1 -> ../../hdb1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100 -> ../../sda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100-part1 -> ../../sda1

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100-part2 -> ../../sda2

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100-part3 -> ../../sda3

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 usb-SAMSUNG_HD501LJ_200711020016023C-0:0 -> ../../sdb

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-SAMSUNG_HD501LJ_200711020016023C-0:0-part1 -> ../../sdb1

```

but after that I plugged in the mp3, it become:

```
/dev/disk/by-id:

total 0

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 ata-IBM-DTLA-307030_YK0YKT66062 -> ../../hda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 ata-IBM-DTLA-307030_YK0YKT66062-part1 -> ../../hda1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 ata-MAXTOR_STM3250820A_6RT0066D -> ../../hdb

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 ata-MAXTOR_STM3250820A_6RT0066D-part1 -> ../../hdb1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100 -> ../../sda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100-part1 -> ../../sda1

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100-part2 -> ../../sda2

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 usb-Myson_Century__Inc._USB_Mass_Storage_Device_100-part3 -> ../../sda3

lrwxrwxrwx 1 root root  9 2008-03-19 20:25 usb-SAMSUNG_HD501LJ_200711020016023C-0:0 -> ../../sdc

lrwxrwxrwx 1 root root 10 2008-03-19 20:25 usb-SAMSUNG_HD501LJ_200711020016023C-0:0-part1 -> ../../sdb1

lrwxrwxrwx 1 root root  9 2008-03-19 20:25 usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0 -> ../../sdc

lrwxrwxrwx 1 root root 10 2008-03-19 20:25 usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1 -> ../../sdc1

```

and /mnt/usb is not mounted anymore. (I can mount it with 'mount /mnt/usb', but I don't want that it get unmounted when I plug in in something.)

Another problem I can see is that both the usb-SAMSUNG drive and the YP-K3 are using the same device node: /dev/sdc. That look like a bug to me. But who really know?

From the same commands:

```
/dev/disk/by-path:

total 0

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-0:0 -> ../../hda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:02.5-ide-0:0-part1 -> ../../hda1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-0:1 -> ../../hdb

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:02.5-ide-0:1-part1 -> ../../hdb1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-1:0 -> ../../hdc

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-1:1 -> ../../hdd

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0 -> ../../sda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0-part1 -> ../../sda1

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0-part2 -> ../../sda2

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0-part3 -> ../../sda3

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:03.3-usb-0:5:1.0-scsi-0:0:0:0 -> ../../sdb

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:5:1.0-scsi-0:0:0:0-part1 -> ../../sdb1

```

```
/dev/disk/by-path:

total 0

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-0:0 -> ../../hda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:02.5-ide-0:0-part1 -> ../../hda1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-0:1 -> ../../hdb

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:02.5-ide-0:1-part1 -> ../../hdb1

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-1:0 -> ../../hdc

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:02.5-ide-1:1 -> ../../hdd

lrwxrwxrwx 1 root root  9 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0 -> ../../sda

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0-part1 -> ../../sda1

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0-part2 -> ../../sda2

lrwxrwxrwx 1 root root 10 2008-03-19 20:21 pci-0000:00:03.3-usb-0:3:1.0-scsi-0:0:0:0-part3 -> ../../sda3

lrwxrwxrwx 1 root root  9 2008-03-19 20:25 pci-0000:00:03.3-usb-0:5:1.0-scsi-0:0:0:0 -> ../../sdc

lrwxrwxrwx 1 root root 10 2008-03-19 20:25 pci-0000:00:03.3-usb-0:5:1.0-scsi-0:0:0:0-part1 -> ../../sdb1

lrwxrwxrwx 1 root root  9 2008-03-19 20:25 pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0 -> ../../sdc

lrwxrwxrwx 1 root root 10 2008-03-19 20:25 pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1 -> ../../sdc1

```

All this with udev-115-r1 and a 2.6.23-gentoo-r9 kernel.

----------

## Dominique_71

One more strange issue:

```
 $ df -h

Sys. de fich.         Tail. Occ. Disp. %Occ. Monté sur

/dev/hda1              29G   27G  1,7G  95% /

udev                   10M  240K  9,8M   3% /dev

/dev/hdb1             233G  135G   99G  58% /mnt/data

/dev/sda1              47G   36G   11G  77% /mnt/usbdisk_2

/dev/sda2              16M   11M  3,5M  76% /mnt/usbdisk_1

/dev/sda3             140G  103G   38G  74% /mnt/usbdisk

/dev/sdb1             932G  219G  713G  24% /mnt/usb

tmpfs                 760M     0  760M   0% /dev/shm

/dev/sdc1             1,9G  1,5G  376M  81% /mnt/K3

/dev/sdb1             932G  219G  713G  24% /mnt/usb

```

```
$ cat /proc/partitions

major minor  #blocks  name

   3     0   30018240 hda

   3     1   30018208 hda1

   3    64  244198584 hdb

   3    65  244196001 hdb1

   8     0  195360984 sda

   8     1   48837568 sda1

   8     2      16065 sda2

   8     3  146504767 sda3

   8    32  976773168 sdc

   8    33  976768033 sdc1

   8    48    1931264 sdd

   8    49    1930680 sdd1
```

The output of 'cat /proc/partitions' is correct, but I get no /dev/sdb1 and 'df -h' give me 2 times "/dev/sdb1".

EDIT: That's UDEV rules!   :Laughing: 

EDIT2: After booting without the K3, both drives was sharing the same sdb device. It look like UDEV doesn't like when we force the device name, even if that work. So, back to the starting point like in the first post.

----------

## PaulBredbury

Stop assigning NAME="blah". Let udev itself assign the name. You should just be assigning the symlink, and using the symlink.

```
SYMLINK+="blah"
```

Yes, it's += rather than =, in case udev has added a symlink at an earlier point in the rule-processing to your rule.

----------

## Dominique_71

Thank you Paul for the answer. I modified the rules according to your advice:

```
# Drives

SUBSYSTEMS=="usb", ATTRS{serial}=="200711020016023C", KERNEL=="sd?", SYMLINK+="usbdriveb"

SUBSYSTEMS=="usb", ATTRS{serial}=="200711020016023C", KERNEL=="sd?1", SYMLINK+="usbdriveb1"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?", SYMLINK+="usbdrivea"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?1", SYMLINK+="usbdrivea1"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?2", SYMLINK+="usbdrivea2"

SUBSYSTEMS=="usb", ATTRS{serial}=="100", KERNEL=="sd?3", SYMLINK+="usbdrivea3"

# YP-K3

SUBSYSTEMS=="usb", ATTRS{serial}=="260D7456000028040853918BF0041F04", KERNEL=="sd?", SYMLINK+="usbK3"

SUBSYSTEMS=="usb", ATTRS{serial}=="260D7456000028040853918BF0041F04", KERNEL=="sd?1", SYMLINK+="usbK31"

```

but the drive still get unmounted.

----------

## Dominique_71

Up with this thread. Any clue to the horizon?

----------

## PaulBredbury

Turn on udev debugging, and see what rules are being triggered.

```
udevadm control --log_priority=debug
```

(from "man udev")

----------

## Dominique_71

 *PaulBredbury wrote:*   

> Turn on udev debugging, and see what rules are being triggered.
> 
> ```
> udevadm control --log_priority=debug
> ```
> ...

 

"man udev" show me nothing about udevadm. This command is not in my system. But I found in /etc/udev/udev.conf another command that will hopefully do the same thing:

```
udevcontrol log_priority=debug
```

I get this in /var/log/everything/current:

```
May  1 12:18:55 [udevd] msg_queue_insert: seq 1985 forked, 'add' 'scsi'

May  1 12:18:55 [udevd] udev_event_run: seq 1985 forked, pid [7373], 'add' 'scsi', 0 seconds old

May  1 12:18:55 [udevd] msg_queue_insert: seq 1986 forked, 'add' 'scsi_disk'

May  1 12:18:55 [udevd-event] wait_for_sysfs: wait for '/sys/devices/pci0000:00/0000:00:03.3/usb1/1-6/1-6:1.0/host3/target3:0:0/3:0:0:0/ioerr_cnt' for 20 mseconds

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] 3862528 512-byte hardware sectors (1978 MB)

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] Write Protect is off

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] Assuming drive cache: write through

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] 3862528 512-byte hardware sectors (1978 MB)

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] Write Protect is off

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] Assuming drive cache: write through

May  1 12:18:55 [udevd] msg_queue_insert: seq 1987 forked, 'add' 'block'

May  1 12:18:55 [udevd] msg_queue_insert: seq 1988 forked, 'add' 'block'

May  1 12:18:55 [kernel] sd 3:0:0:0: [sdd] Attached SCSI removable disk

May  1 12:18:55 [udevd] msg_queue_insert: seq 1989 forked, 'add' 'scsi_device'

May  1 12:18:55 [udevd] msg_queue_insert: seq 1990 forked, 'add' 'scsi_generic'

May  1 12:18:55 [kernel] sd 3:0:0:0: Attached scsi generic sg2 type 0

May  1 12:18:55 [udevd-event] wait_for_sysfs: file '/sys/devices/pci0000:00/0000:00:03.3/usb1/1-6/1-6:1.0/host3/target3:0:0/3:0:0:0/ioerr_cnt' appeared after 1 loops

May  1 12:18:55 [udevd-event] wait_for_sysfs: file '/sys/devices/pci0000:00/0000:00:03.3/usb1/1-6/1-6:1.0/host3/target3:0:0/3:0:0:0/bus' appeared after 0 loops

May  1 12:18:55 [udevd-event] match_rule: writing '60' to sysfs file '/sys/devices/pci0000:00/0000:00:03.3/usb1/1-6/1-6:1.0/host3/target3:0:0/3:0:0:0/timeout'

May  1 12:18:55 [udevd-event] run_program: 'modprobe.sh scsi:t-0x00'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/modprobe.sh' returned with status 0

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed 264 bytes to socket '/org/freedesktop/hal/udev_event', 

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed -1 bytes to socket '/org/kernel/udev/monitor', 

May  1 12:18:55 [udevd-event] udev_event_run: seq 1985 finished with 0

May  1 12:18:55 [udevd] udev_done: seq 1985, pid [7373] exit with 0, 0 seconds old

May  1 12:18:55 [udevd] udev_event_run: seq 1986 forked, pid [7387], 'add' 'scsi_disk', 0 seconds old

May  1 12:18:55 [udevd] udev_event_run: seq 1987 forked, pid [7388], 'add' 'block', 0 seconds old

May  1 12:18:55 [udevd] udev_event_run: seq 1989 forked, pid [7389], 'add' 'scsi_device', 0 seconds old

May  1 12:18:55 [udevd] udev_event_run: seq 1990 forked, pid [7390], 'add' 'scsi_generic', 0 seconds old

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'usbK3'

May  1 12:18:55 [udevd-event] match_rule: '/sys/module/sg' exists

May  1 12:18:55 [udevd-event] udev_rules_get_name: rule applied, 'sdd' becomes 'sdd'

May  1 12:18:55 [udevd-event] match_rule: set ENV 'DEVTYPE=disk'

May  1 12:18:55 [udevd-event] run_program: 'usb_id --export /block/sdd'

May  1 12:18:55 [usb_id] usb_id: /devices/pci0000:00/0000:00:03.3/usb1/1-6/1-6:1.0: if_class 8 protocol 6_

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed 251 bytes to socket '/org/freedesktop/hal/udev_event', 

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed -1 bytes to socket '/org/kernel/udev/monitor', 

May  1 12:18:55 [udevd-event] udev_event_run: seq 1986 finished with 0

May  1 12:18:55 [udevd] udev_done: seq 1986, pid [7387] exit with 0, 0 seconds old

May  1 12:18:55 [udevd-event] run_program: 'modprobe.sh sd_mod'

May  1 12:18:55 [udevd-event] udev_rules_get_name: no node name set, will use kernel name ''

May  1 12:18:55 [udevd-event] udev_db_get_device: no db file to read /dev/.udev/db/\x2fclass\x2fscsi_generic\x2fsg2: No such file or directory

May  1 12:18:55 [udevd-event] udev_node_add: creating device node '/dev/sg2', major=21, minor=2, mode=0660, uid=0, gid=0

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/sg2/\x2fclass\x2fscsi_generic\x2fsg2'

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed 286 bytes to socket '/org/freedesktop/hal/udev_event', 

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed -1 bytes to socket '/org/kernel/udev/monitor', 

May  1 12:18:55 [udevd-event] udev_event_run: seq 1990 finished with 0

May  1 12:18:55 [udevd] udev_done: seq 1990, pid [7390] exit with 0, 0 seconds old

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_VENDOR=SAMSUNG'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_MODEL=YP-K3'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_REVISION=1.00'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_SERIAL=SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_SERIAL_SHORT=260D7456000028040853918BF0041F04'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_TYPE=disk'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_INSTANCE=0:0'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' (stdout) 'ID_BUS=usb'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/usb_id' returned with status 0

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0'

May  1 12:18:55 [udevd-event] run_program: 'path_id /block/sdd'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/path_id' (stdout) 'ID_PATH=pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/path_id' returned with status 0

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0'

May  1 12:18:55 [udevd-event] run_program: 'edd_id --export /dev/.tmp-8-48'

May  1 12:18:55 [edd_id] main: no kernel EDD support

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/edd_id' (stderr) 'no kernel EDD support'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/edd_id' returned with status 2

May  1 12:18:55 [udevd-event] udev_db_get_device: no db file to read /dev/.udev/db/\x2fblock\x2fsdd: No such file or directory

May  1 12:18:55 [udevd-event] udev_node_add: creating device node '/dev/sdd', major=8, minor=48, mode=0660, uid=0, gid=6

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/usbK3/\x2fblock\x2fsdd'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/disk\x2fby-id\x2fusb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0/\x2fblock\x2fsdd'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/disk\x2fby-path\x2fpci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0/\x2fblock\x2fsdd'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/sdd/\x2fblock\x2fsdd'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'usbK3' of '/block/sdd'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/usbK3'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'usbK3'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd' for 'usbK3'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'usbK3' with target 'sdd' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/usbK3' to 'sdd'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0' of '/block/sdd'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/disk\x2fby-id\x2fusb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd' for 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0' with target 'sdd' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0' to '../../sdd'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0' of '/block/sdd'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/disk\x2fby-path\x2fpci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd' for 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0' with target 'sdd' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0' to '../../sdd'

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed 667 bytes to socket '/org/freedesktop/hal/udev_event', 

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed -1 bytes to socket '/org/kernel/udev/monitor', 

May  1 12:18:55 [udevd-event] udev_event_run: seq 1987 finished with 0

May  1 12:18:55 [udevd] udev_done: seq 1987, pid [7388] exit with 0, 0 seconds old

May  1 12:18:55 [udevd] udev_event_run: seq 1988 forked, pid [7400], 'add' 'block', 0 seconds old

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'usbK31'

May  1 12:18:55 [udevd-event] udev_rules_get_name: rule applied, 'sdd1' becomes 'sdd1'

May  1 12:18:55 [udevd-event] match_rule: set ENV 'DEVTYPE=partition'

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1'

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1'

May  1 12:18:55 [udevd-event] run_program: 'vol_id --export /dev/.tmp-8-49'

May  1 12:18:55 [vol_id] volume_id.c:351 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] linux_raid.c:70 probing at offset 0x75d50000, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d50000(1976893440), len 0x800

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d50000 len:0x800

May  1 12:18:55 [vol_id] linux_raid.c:124 probing at offset 0x75d6c000, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6c000(1977008128), len 0x800

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6c000 len:0x800

May  1 12:18:55 [vol_id] linux_raid.c:124 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x0(0), len 0x800

May  1 12:18:55 [vol_id] util.c:355 read sbbuf len:0x800

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/modprobe.sh' returned with status 0

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed 257 bytes to socket '/org/freedesktop/hal/udev_event', 

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed -1 bytes to socket '/org/kernel/udev/monitor', 

May  1 12:18:55 [udevd-event] udev_event_run: seq 1989 finished with 0

May  1 12:18:55 [udevd] udev_done: seq 1989, pid [7389] exit with 0, 0 seconds old

May  1 12:18:55 [vol_id] linux_raid.c:124 probing at offset 0x1000, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x1000(4096), len 0x800

May  1 12:18:55 [vol_id] util.c:355 read sbbuf len:0x1800

May  1 12:18:55 [vol_id] ddf_raid.c:49 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6de00(1977015808), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6de00 len:0x200

May  1 12:18:55 [vol_id] isw_raid.c:47 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6dc00(1977015296), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6dc00 len:0x200

May  1 12:18:55 [vol_id] lsi_raid.c:42 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6de00(1977015808), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6de00 len:0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6de00(1977015808), len 0x200

May  1 12:18:55 [vol_id] silicon_raid.c:57 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6de00(1977015808), len 0x200

May  1 12:18:55 [vol_id] nvidia_raid.c:45 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6dc00(1977015296), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6dc00 len:0x200

May  1 12:18:55 [vol_id] promise_raid.c:46 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d66200(1976984064), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d66200 len:0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d4e200(1976885760), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d4e200 len:0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d4e000(1976885248), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d4e000 len:0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6c000(1977008128), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6c000 len:0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d3c200(1976812032), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d3c200 len:0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6ca00(1977010688), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6ca00 len:0x200

May  1 12:18:55 [vol_id] adaptec_raid.c:90 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6de00(1977015808), len 0x200

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x75d6de00 len:0x200

May  1 12:18:55 [vol_id] jmicron_raid.c:43 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x75d6de00(1977015808), len 0x200

May  1 12:18:55 [vol_id] lvm.c:49 probing at offset 0x0

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x400(1024), len 0x800

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x0(0), len 0x800

May  1 12:18:55 [vol_id] highpoint.c:52 probing at offset 0x0

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x1200(4608), len 0x200

May  1 12:18:55 [vol_id] volume_id.c:382 probing at offset 0x0, size 0x75d6e000

May  1 12:18:55 [vol_id] fat.c:273 probing at offset 0x0

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x0(0), len 0x400

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x200(512), len 0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x0(0), len 0x200

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x3b1000(3870720), len 0x1000

May  1 12:18:55 [vol_id] util.c:391 read seekbuf off:0x3b1000 len:0x1000

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x4008(16392), len 0x1000

May  1 12:18:55 [vol_id] util.c:355 read sbbuf len:0x5008

May  1 12:18:55 [vol_id] util.c:342 get buffer off 0x0(0), len 0x200

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_USAGE=filesystem'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_TYPE=vfat'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_VERSION=FAT32'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_UUID=46E4-6C4C'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_UUID_ENC=46E4-6C4C'

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_LABEL='

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_LABEL_ENC='

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' (stdout) 'ID_FS_LABEL_SAFE='

May  1 12:18:55 [udevd-event] run_program: '/lib/udev/vol_id' returned with status 0

May  1 12:18:55 [udevd-event] udev_rules_get_name: add symlink 'disk/by-uuid/46E4-6C4C'

May  1 12:18:55 [udevd-event] udev_db_get_device: no db file to read /dev/.udev/db/\x2fblock\x2fsdd\x2fsdd1: No such file or directory

May  1 12:18:55 [udevd-event] udev_node_add: creating device node '/dev/sdd1', major=8, minor=49, mode=0660, uid=0, gid=6

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/usbK31/\x2fblock\x2fsdd\x2fsdd1'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/disk\x2fby-id\x2fusb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1/\x2fblock\x2fsdd\x2fsdd1'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/disk\x2fby-path\x2fpci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1/\x2fblock\x2fsdd\x2fsdd1'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/disk\x2fby-uuid\x2f46E4-6C4C/\x2fblock\x2fsdd\x2fsdd1'

May  1 12:18:55 [udevd-event] name_index: creating index: '/dev/.udev/names/sdd1/\x2fblock\x2fsdd\x2fsdd1'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'usbK31' of '/block/sdd/sdd1'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/usbK31'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'usbK31'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd/sdd1' for 'usbK31'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd/sdd1' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'usbK31' with target 'sdd1' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/usbK31' to 'sdd1'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1' of '/block/sdd/sdd1'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/disk\x2fby-id\x2fusb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd/sdd1' for 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd/sdd1' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1' with target 'sdd1' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/disk/by-id/usb-SAMSUNG_YP-K3_260D7456000028040853918BF0041F04-0:0-part1' to '../../sdd1'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1' of '/block/sdd/sdd1'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/disk\x2fby-path\x2fpci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd/sdd1' for 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd/sdd1' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1' with target 'sdd1' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/disk/by-path/pci-0000:00:03.3-usb-0:6:1.0-scsi-0:0:0:0-part1' to '../../sdd1'

May  1 12:18:55 [udevd-event] udev_node_update_symlinks: update symlink 'disk/by-uuid/46E4-6C4C' of '/block/sdd/sdd1'

May  1 12:18:55 [udevd-event] udev_db_get_devices_by_name: found index directory '/dev/.udev/names/disk\x2fby-uuid\x2f46E4-6C4C'

May  1 12:18:55 [udevd-event] update_link: found 1 devices with name 'disk/by-uuid/46E4-6C4C'

May  1 12:18:55 [udevd-event] update_link: found '/block/sdd/sdd1' for 'disk/by-uuid/46E4-6C4C'

May  1 12:18:55 [udevd-event] update_link: compare (our own) priority of '/block/sdd/sdd1' 0 >= 0

May  1 12:18:55 [udevd-event] update_link: 'disk/by-uuid/46E4-6C4C' with target 'sdd1' has the highest priority 0, create it

May  1 12:18:55 [udevd-event] node_symlink: creating symlink '/dev/disk/by-uuid/46E4-6C4C' to '../../sdd1'

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed 877 bytes to socket '/org/freedesktop/hal/udev_event', 

May  1 12:18:55 [udevd-event] pass_env_to_socket: passed -1 bytes to socket '/org/kernel/udev/monitor', 

May  1 12:18:55 [udevd-event] udev_event_run: seq 1988 finished with 0

May  1 12:18:55 [udevd] udev_done: seq 1988, pid [7400] exit with 0, 0 seconds old

```

And when trying to access the previously correctly mounted usb drive:

```
May  1 12:22:40 [kernel] scsi 1:0:0:0: rejecting I/O to dead device

May  1 12:22:40 [kernel] ReiserFS: sdb1: warning: zam-7001: io error in reiserfs_find_entry

May  1 12:22:40 [kernel] scsi 1:0:0:0: rejecting I/O to dead device

May  1 12:22:40 [kernel] ReiserFS: sdb1: warning: zam-7001: io error in reiserfs_find_entry

May  1 12:22:47 [kernel] scsi 1:0:0:0: rejecting I/O to dead device

```

----------

## Dominique_71

'umount /mnt/usb' :

```
May  1 12:22:40 [kernel] scsi 1:0:0:0: rejecting I/O to dead device

May  1 12:22:40 [kernel] ReiserFS: sdb1: warning: zam-7001: io error in reiserfs_find_entry

May  1 12:22:40 [kernel] scsi 1:0:0:0: rejecting I/O to dead device

May  1 12:22:40 [kernel] ReiserFS: sdb1: warning: zam-7001: io error in reiserfs_find_entry

May  1 12:22:47 [kernel] scsi 1:0:0:0: rejecting I/O to dead device
```

??? :

```
May  1 12:30:01 [cron] (root) CMD (test -x /usr/sbin/run-crons && /usr/sbin/run-crons )

May  1 12:32:08 [kernel] scsi 1:0:0:0: rejecting I/O to dead device

May  1 12:32:08 [kernel] Buffer I/O error on device sdb1, logical block 8113

May  1 12:32:08 [kernel] lost page write due to I/O error on sdb1

May  1 12:32:08 [kernel] Buffer I/O error on device sdb1, logical block 8114

May  1 12:32:08 [kernel] lost page write due to I/O error on sdb1
```

'mount /mnt/usb' :

```
May  1 12:35:29 [kernel] ReiserFS: sdc1: found reiserfs format "3.6" with standard journal

May  1 12:35:29 [kernel] ReiserFS: sdc1: using ordered data mode

May  1 12:35:29 [kernel] ReiserFS: sdc1: journal params: device sdc1, size 8192, journal first block 18, max trans len 1024, max batch 900, max commit age 30, max trans age 30

May  1 12:35:29 [kernel] ReiserFS: sdc1: checking transaction log (sdc1)

May  1 12:35:29 [kernel] ReiserFS: sdc1: replayed 1 transactions in 0 seconds

May  1 12:35:29 [kernel] ReiserFS: sdc1: Using r5 hash to sort names

```

----------

