Results 1 to 6 of 6
Hi
Sometimes when I hotplug a SATA device to/from say /dev/sdb, it malfunctions/times out, and cannot be detected. Then when I plug in another SATA device, it gets detected as ...
- 08-14-2009 #1Linux Newbie
- Join Date
- Apr 2008
- Posts
- 110
How to reclaim device name after malfunction?
Hi
Sometimes when I hotplug a SATA device to/from say /dev/sdb, it malfunctions/times out, and cannot be detected. Then when I plug in another SATA device, it gets detected as /dev/sdc even though /dev/sdb is no longer there. How can I reclaim /dev/sdb in this case?
Thanks
- 08-14-2009 #2forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 17,788
I'm not sure, but wonder if restarting udev would do it?
oz
→ new users: read this first
→ no private messages requesting computer support - post them on the forums!
- 08-14-2009 #3Linux Newbie
- Join Date
- Apr 2008
- Posts
- 110
How would I do that? Thanks.
- 08-14-2009 #4forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 17,788
Different distributions use different methods for restarting udev. What distro are you running?
You might also be able to setup some custom udev rules so that you don't loose any devices along the way.oz
→ new users: read this first
→ no private messages requesting computer support - post them on the forums!
- 08-14-2009 #5Linux Newbie
- Join Date
- Apr 2007
- Posts
- 210
I may be wrong, but I think that creating specific udev rules may help. I don't know much about how to go about doing it though. Here's how it works for an external USB hdd:
or alternativelyCode:BUS=="usb", KERNEL=="sd?1", ATTRS{manufacturer}=="Sunplus Technology Inc.", ATTRS{serial}=="0", NAME="%k", SYMLINK="usbhdd1"
You don't copy it as it is, but you rather have to set the proper values according to the output of a command like:Code:BUS=="usb", KERNEL=="sd?1", SYSFS{manufacturer}=="", NAME="%k", SYMLINK+="usbhdd1"
udevinfo -a -p $(udevinfo -q path -n /dev/sdc)
Or whatever is the "name" it gets at the time instead of sdc.
Source.
This is saved at /etc/udev/rules.d/10-local.rules
But if it does not look crispy clear to you, "how I didn't think of this before", wait for someone else more knowedgeable than me to comment on it.
- 08-19-2009 #6Linux Newbie
- Join Date
- Apr 2008
- Posts
- 110
OK, how would I also quicken the process of the kernel finding out that a SATA device has been unplugged?
Let's say I have a SATA drive that I connect to 1 of the SATA ports. The kernel will see it(a popup appears) and fdisk will be able to see it as well. When I unplug it, it takes a few seconds for fdisk to register that it's not there anymore. Is there anything I can command I can run to speed this up?


Reply With Quote
