# udev Alias Rules

## anonybosh

I have a couple of identical external USB drives that I would like udev to create symlinks to upon connect. However, the only static hardware descriptor that seems to differentiate between the different drives is the 'iSerial' that is output from lsusb. None of the attributes output by 'udevadm info --attribute-walk' seem to help (ATTRS{serial}=="0000:02:07.2" looks like a USB access path).

How can I 'access' this attribute via udev (for making a symlink rule)?

Thanks in advance!

-Ryan

----------

## anonybosh

Bump!

----------

## fangorn

This is possible, as udev can execute external programs at <event>, but in most cases is not necessary. 

If you just want to get different devices to mount them to different places, I'd suggest using filesystem labels instead. 

you can then mount the devices under

/dev/disk/by-label/<label>

for the usual filesystems you can change the label at any time (if not mounted). For example for XFS the command would be 

```
xfs_adm -L <label> /dev/<device>
```

----------

