USB forceful removal

Greg Freemyer greg.freemyer at gmail.com
Tue Jul 8 18:17:56 EDT 2014


On Tue, Jul 8, 2014 at 2:55 PM, Greg KH <greg at kroah.com> wrote:
> On Wed, Jul 09, 2014 at 12:13:28AM +0530, AYAN KUMAR HALDER wrote:
>> Hi All,
>>
>> When a usb mass-storage is attached for the first time, it gets a
>> device (/dev/sda).
>>
>> When it is mounted and the device is manually removed and then when it
>> is attached again, it gets a different name ie /dev/sdb.
>
> Really?  Not on my system, what kernel are you using?

Greg, I just tried the experiment and had the above described behavior:

- Connect external USB-3 drive, drive assigned /dev/sdb
- mount -r /dev/sdb1 /mnt
- pull the usb connector
- wait 30 seconds, and reconnect
- drive assigned /dev/sdc

I'm running openSUSE with the distro kernel 3.11.6-4-desktop.

I then added "umount /mnt" before pulling the usb connector and
/dev/sdc was re-used on reconnect.

<snip>

> thanks,
>
> greg k-h

the other greg



More information about the Kernelnewbies mailing list