You are not logged in.

#1 2012-02-16 00:08:21

B-Con
Member
From: USA
Registered: 2007-12-17
Posts: 554
Website

udev thinks there's a non-existent drive

I have an error

[sdb] Asking for cache data failed
[sdb] Assuming drive cache: write through

that is repeatedly output to my tty1 console (it outputs roughly every 50 seconds) and to my error logs.

The odd thing is that I have no sdb drive, which is presumably why the request for the cache data is failing. This is a laptop with the only hard disk as sda and the CD drive as sr0. There's nothing about sdb even mentioned in fstab or mtab.

But if I plug in my USB drive it is attached to sdc, so it thinks there's an sdb of some sort. When I plugged it in, I had similar messages:

[sdc] No Caching mode page present
[sdc] Assuming drive cache: write through

which was also displayed to tty1.

I was running a system fully updated as of that morning. udev had been updated the previous day so I reverted it back and the phantom drive problem went away. I assume this is a udev problem, both thinking that sdb exists and outputting annoying messages to tty1.

I've looked at the threads on here and the top results on Google (eg, a thread here. On LQ), but none of them has been useful for identifying the cause of the problem nor for suppressing the output. I tried doing update-usbids.sh and update-pciids, but that didn't fix anything. initscripts was also updated at the same time and I looked at that, but saw nothing in the changes that looked possibly related to udev.

So my questions are:

  • Why does udev think this phantom sdb exists and how to I eliminate it?

  • On a side note, why on earth does it output on tty1, and how do I stop that?

Last edited by B-Con (2012-02-16 04:43:03)

Offline

#2 2012-02-16 04:10:45

willbprog127
Member
Registered: 2011-11-09
Posts: 59

Re: udev thinks there's a non-existent drive

That's odd.  Could it be an onboard card reader?  What does

lsblk

say?

Offline

#3 2012-02-17 10:03:22

whzee
Member
Registered: 2011-12-23
Posts: 20

Re: udev thinks there's a non-existent drive

I've got the same error on my laptop too. My thread:
https://bbs.archlinux.org/viewtopic.php?id=135898
@willbprog127: I think it might be my card reader..

edit: it is the card reader

Just plugged in an sd card and it shows up at /dev/sdb1. Is there anyway to turn this off when nothing is inserted in the card reader?

Last edited by whzee (2012-02-17 10:04:01)

Offline

#4 2012-02-17 22:41:29

B-Con
Member
From: USA
Registered: 2007-12-17
Posts: 554
Website

Re: udev thinks there's a non-existent drive

willbprog127 wrote:

That's odd.  Could it be an onboard card reader?  What does

lsblk

say?

lsblk shows only sda and sr0, and fdisk -l shows only sda.

I do have an onboard card reader, and whzee's comment suggests that's a good thing to look at.

whzee wrote:

I've got the same error on my laptop too. My thread:
https://bbs.archlinux.org/viewtopic.php?id=135898
@willbprog127: I think it might be my card reader..

edit: it is the card reader

Just plugged in an sd card and it shows up at /dev/sdb1. Is there anyway to turn this off when nothing is inserted in the card reader?

Good find. I'll try that when I can get an sd card this evening to see if it's the same for me. If so, that does seem like undesirable behavior by udev.

[edit]

Yep, it's my sd card reader. It shows up as /dev/sdb1, and the log messages regarding inability to access it stop when I insert something into it. I too am interested in turning off that confounded output. I still have no idea why udev thinks it should be outputting to tty1.

Last edited by B-Con (2012-02-18 05:36:24)

Offline

#5 2012-02-18 16:19:36

PReP
Member
From: Sweden
Registered: 2010-06-13
Posts: 359
Website

Re: udev thinks there's a non-existent drive

"[sdd] No Caching mode page present
[sdd] Assuming drive cache: write through"

I get this too, have for a few updates.
I am hoping it will get fixed sometime.

For me it's my usb-harddrive,
and udev spams it about 4 times, right on top of my terminal login.


. Main: Intel Core i5 6600k @ 4.4 Ghz, 16 GB DDR4 XMP, Gefore GTX 970 (Gainward Phantom) - Arch Linux 64-Bit
. Server: Intel Core i5 2500k @ 3.9 Ghz, 8 GB DDR2-XMP RAM @ 1600 Mhz, Geforce GTX 570 (Gainward Phantom) - Arch Linux 64-Bit
. Body: Estrogen @ 90%, Testestorone @ 10% (Not scientific just out-of-my-guesstimate-brain)

Offline

#6 2012-02-18 18:32:05

B-Con
Member
From: USA
Registered: 2007-12-17
Posts: 554
Website

Re: udev thinks there's a non-existent drive

PReP wrote:

For me it's my usb-harddrive,
and udev spams it about 4 times, right on top of my terminal login.

So the messages stop? If so, I would assume that it stops when your USB  drive is detected and mounted.

Offline

#7 2012-02-18 19:14:06

PReP
Member
From: Sweden
Registered: 2010-06-13
Posts: 359
Website

Re: udev thinks there's a non-existent drive

Yes it stops after those four times, i just find it a bit odd that it prints it out on the login/daemon boot-space like that, and often ends up messing up any other text, or the login prompt itself afterwards.


. Main: Intel Core i5 6600k @ 4.4 Ghz, 16 GB DDR4 XMP, Gefore GTX 970 (Gainward Phantom) - Arch Linux 64-Bit
. Server: Intel Core i5 2500k @ 3.9 Ghz, 8 GB DDR2-XMP RAM @ 1600 Mhz, Geforce GTX 570 (Gainward Phantom) - Arch Linux 64-Bit
. Body: Estrogen @ 90%, Testestorone @ 10% (Not scientific just out-of-my-guesstimate-brain)

Offline

#8 2012-02-19 13:51:23

manouchk
Member
Registered: 2008-07-29
Posts: 313

Re: udev thinks there's a non-existent drive

I have problem with mass storage device here too. It is strange because a lot of people does not seem to have this problem. I use Arch64. Are you using too Arch64? That could explain why so few people are having this problem?

I don't know if my problem is the same but I can't read anymore some of my usb mass storage devices!

Here I can read a USB stick with a single partition:

Feb 19 10:31:25 localhost kernel: [22804.760501] sd 10:0:0:0: [sdc] Write Protect is off
Feb 19 10:31:25 localhost kernel: [22804.791584]  sdc: sdc1
Feb 19 10:31:25 localhost kernel: [22804.797761] sd 10:0:0:0: [sdc] Attached SCSI removable disk

and things go well, I can read the usbstick in Nautilus etc...

I have a external harddrive that have more than one partition, with linux partitions. fdsik recocgnise the disk so that I can find the right partitions to mount and I can mount manually one the partition which holds a reiserfs but it fails to mount one of the other partition. I don't remember the type of this partition ext2, ext3 or reiserfs...

dmesg gives this messages when plugging in the external HD:

[22745.048822] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.049237] scsi 9:0:0:0: Direct-Access     ST340083 3A                    PQ: 0 ANSI: 0
[22745.049707] sd 9:0:0:0: [sdb] 781422768 512-byte logical blocks: (400 GB/372 GiB)
[22745.050139] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.050689] sd 9:0:0:0: [sdb] Write Protect is off
[22745.050695] sd 9:0:0:0: [sdb] Mode Sense: 33 00 00 00
[22745.051143] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.051734] sd 9:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[22745.052598] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.053508] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.093763]  sdb: sdb1 sdb2 < sdb5 > sdb3
[22745.095246] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.096196] xhci_hcd 0000:05:00.0: WARN: Stalled endpoint
[22745.096740] sd 9:0:0:0: [sdb] Attached SCSI disk
[22775.763506] usb 3-2: reset high-speed USB device number 2 using xhci_hcd
[22775.777603] xhci_hcd 0000:05:00.0: WARN: short transfer on control ep
[22775.777764] xhci_hcd 0000:05:00.0: xHCI xhci_drop_endpoint called with disabled ep ffff88005614f200
[22775.777774] xhci_hcd 0000:05:00.0: xHCI xhci_drop_endpoint called with disabled ep ffff88005614f240
[22783.751621] usb 3-2: reset high-speed USB device number 2 using xhci_hcd
[22783.765843] xhci_hcd 0000:05:00.0: WARN: short transfer on control ep
[22783.765963] xhci_hcd 0000:05:00.0: xHCI xhci_drop_endpoint called with disabled ep ffff88005614f200
[22783.765971] xhci_hcd 0000:05:00.0: xHCI xhci_drop_endpoint called with disabled ep ffff88005614f240

I really don'tknow if my problem is correlated to the one discussed here, it seems different but it is strange that two new rare problems involving mass storage appears almost at the same time!

On february 18th udev and device-mapper have been updated:

 [2012-02-18 15:16] upgraded udev (180-1 -> 181-2)
[2012-02-18 15:16] upgraded device-mapper (2.02.88-1 -> 2.02.90-1)

I think the external disk on which I'm having a problem external is with logical partitions.

in fdisk:

Disque /dev/sdb : 400.1 Go, 400088457216 octets
255 têtes, 63 secteurs/piste, 48641 cylindres, total 781422768 secteurs
Unités = secteurs de 1 * 512 = 512 octets
Taille de secteur (logique / physique) : 512 octets / 512 octets
taille d'E/S (minimale / optimale) : 512 octets / 512 octets
Identifiant de disque : 0x0008385c

Périphérique Amorce  Début        Fin      Blocs     Id  Système
/dev/sdb1   *          63    18844244     9422091   83  Linux
/dev/sdb2        20884500   781417664   380266582+   5  Étendue
/dev/sdb3        18844245    20884499     1020127+  82  partition d'échange Linux / Solaris
/dev/sdb5        20884563   781417664   380266551   83  Linux

Could the problem with device mapper instead of udev?

Last edited by manouchk (2012-02-19 13:51:54)

Offline

#9 2012-02-21 00:40:22

B-Con
Member
From: USA
Registered: 2007-12-17
Posts: 554
Website

Re: udev thinks there's a non-existent drive

Yes, for the record I'm using 64-bit Arch.

Offline

#10 2012-03-05 13:15:30

PReP
Member
From: Sweden
Registered: 2010-06-13
Posts: 359
Website

Re: udev thinks there's a non-existent drive

I'm still getting the "no caching mode present, assuming mode write-trough"-spam,
four times, and it covers and messes up the tty1 login most of the times.

Has anyone found a way to fix/stop it from outputting that there?,
it should stay in a log, not on tty1 =/


. Main: Intel Core i5 6600k @ 4.4 Ghz, 16 GB DDR4 XMP, Gefore GTX 970 (Gainward Phantom) - Arch Linux 64-Bit
. Server: Intel Core i5 2500k @ 3.9 Ghz, 8 GB DDR2-XMP RAM @ 1600 Mhz, Geforce GTX 570 (Gainward Phantom) - Arch Linux 64-Bit
. Body: Estrogen @ 90%, Testestorone @ 10% (Not scientific just out-of-my-guesstimate-brain)

Offline

#11 2012-03-05 14:09:33

Wittfella
Member
From: Australia
Registered: 2008-05-27
Posts: 462

Re: udev thinks there's a non-existent drive

I'm not sure if this is the case for everyone, but on my laptop I can enable/disable the card reader though '/sys'.  Try searching /sys for 'card' or some such.  I suspect it will be in '/sys/devices/platform/*' somewhere.  You can also probably disable it completely in the bios if you never use it.

Offline

#12 2012-03-09 20:14:45

flan_suse
Member
Registered: 2010-10-28
Posts: 120

Re: udev thinks there's a non-existent drive

I thought I was alone until I came across this thread. Those annoying messages about /dev/sdb make it nearly impossible to do anything in TTY1 (or any active TTY), since it interferes with the text I am writing / reading. Not only is it annoying, but it interferes!

I would like to turn off these messages.

Even if someone figures out how to disable these messages, my question is why does udev care about a device that doesn't currently exist (no cards are inserted into the card reader), and why must it check every 50 seconds concerning the write cache? These messages are filling up my log with useless clutter; it's ridiculous!

Disabling my card reader would be a dirty workaround, and it's not the user's onus to circumvent something like this.

Last edited by flan_suse (2012-03-09 20:17:08)

Offline

#13 2012-03-09 20:41:34

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: udev thinks there's a non-existent drive

I'm surprised none of you has found the logverbose=3 option already.

This is happening because the realtek card-reader drivers (rts_pstor and rts5139) are crap really. There's a reason they're in staging. The first crap is that they present the cards as scsi devices instead of as, you know, cards. The second is that they embed an entire sd stack instead of using the existing kernel stack. A proper driver would be a fraction of the size of these drivers.

Offline

#14 2012-03-09 21:46:07

flan_suse
Member
Registered: 2010-10-28
Posts: 120

Re: udev thinks there's a non-existent drive

Gusar wrote:

I'm surprised none of you has found the logverbose=3 option already.

Appending loglevel=3 in my boot (menu.lst) options did the trick, partially. No longer does it spam any TTY with these messages. However, it is still filling up my log file with the same messages, basically every 50 seconds.

Either way, thank you, Gusar! This makes a big difference. I can use TTY1 (and any TTY) without any interference now.

Sad to see this is due to a poorly written driver by RealTek. I assume everyone else in this thread with the same issue has a RealTek card reader?

Offline

#15 2012-03-10 09:50:37

PReP
Member
From: Sweden
Registered: 2010-06-13
Posts: 359
Website

Re: udev thinks there's a non-existent drive

I will try the log-level setting.

Though,. to be clear, this issue is not only about card-readers,
In my case it is my external USB harddrive, which i mount "manually" in fstab,
since i don't care for udiskie/dbus automatic stuff on my system.

Will see if this helps me too (i bet it should as it looks) smile


Update:

This was a quick work-around,

loglevel=3 on the kernel line in /boot/grub/menu.lst worked fine smile

Thanks for the tip.


Now, i think the actual spamming of the message in the log,
is still a valid problem elsewhere (udev or kernel?)
But the actual tty-spamming has stopped atleast smile

Last edited by PReP (2012-03-10 09:55:27)


. Main: Intel Core i5 6600k @ 4.4 Ghz, 16 GB DDR4 XMP, Gefore GTX 970 (Gainward Phantom) - Arch Linux 64-Bit
. Server: Intel Core i5 2500k @ 3.9 Ghz, 8 GB DDR2-XMP RAM @ 1600 Mhz, Geforce GTX 570 (Gainward Phantom) - Arch Linux 64-Bit
. Body: Estrogen @ 90%, Testestorone @ 10% (Not scientific just out-of-my-guesstimate-brain)

Offline

#16 2012-03-10 16:26:17

Gusar
Member
Registered: 2009-08-25
Posts: 3,605

Re: udev thinks there's a non-existent drive

flan_suse wrote:

However, it is still filling up my log file with the same messages, basically every 50 seconds.

Yeah, that's kinda the point of logs, to you know, log stuff smile. The option only affects printing to the console.

flan_suse wrote:

Sad to see this is due to a poorly written driver by RealTek.

Now imagine you're using Windows. Where every driver is written like that. *shudders*

PReP wrote:

Though,. to be clear, this issue is not only about card-readers,

Other drivers don't spam. The messages are printed once, when the device is inserted, and that's it.

PReP wrote:

Now, i think the actual spamming of the message in the log,
is still a valid problem elsewhere (udev or kernel?)

There's no problem. Outside of the realtek drivers being weird, that is. It's just the storage system being a bit verbose. But the messages aren't errors.

Last edited by Gusar (2012-03-10 16:27:58)

Offline

#17 2012-03-11 10:06:26

PReP
Member
From: Sweden
Registered: 2010-06-13
Posts: 359
Website

Re: udev thinks there's a non-existent drive

Gusar wrote:

Other drivers don't spam. The messages are printed once, when the device is inserted, and that's it.

There's no problem. Outside of the realtek drivers being weird, that is. It's just the storage system being a bit verbose. But the messages aren't errors.

Well, a differ in quantity perhaps, but it stilled had a new default where it - yes, spammed - right over my tty1-login prompt about four times, (i don't boot into X).

And there is still what i label a problem - albeit not a vital one as i said - since this did not happen before, around a month or two ago (there was no need for loglevel lowering),
and kernel/udevd/drive seems to be the only one with a log-level-verbosity in skew smile


. Main: Intel Core i5 6600k @ 4.4 Ghz, 16 GB DDR4 XMP, Gefore GTX 970 (Gainward Phantom) - Arch Linux 64-Bit
. Server: Intel Core i5 2500k @ 3.9 Ghz, 8 GB DDR2-XMP RAM @ 1600 Mhz, Geforce GTX 570 (Gainward Phantom) - Arch Linux 64-Bit
. Body: Estrogen @ 90%, Testestorone @ 10% (Not scientific just out-of-my-guesstimate-brain)

Offline

#18 2012-03-11 18:01:25

tomegun
Developer
From: France
Registered: 2010-05-28
Posts: 661

Re: udev thinks there's a non-existent drive

The messages you are seeing are from the kernel, not udev. Udev would not be actively doing anything every 50 seconds to cause this, but it might have set an option in the kernel driver to do it.

If you want this fixed, please verify which was the first broken version of udev, and open a bug report with this information so I don't forget about it smile

Offline

Board footer

Powered by FluxBB