A story of faulty hard disks, kernel panics, and broken pins

When I got a new laptop from my employer, I decided I wanted to use a pure GNOME 3 desktop. The only distribution to offer it out of the box was Fedora, which I didn't really want to use, so I took a completely different path: install Linux Mint Debian Edition with Cinammon, and install GNOME 3 on top of it.

And it is working great! On "my" Dell Latitude 6430u everything works but the Bluetooth adapter. I had some freezes from time to time, which I suspect are due to some bug in the video drivers, but it happened so rarely that it wasn't really a problem. Until yesterday. …Lately, an old USB disk of mine was screaming for retirement, so I bought a 1TB Seagate expansion drive (Model ID: SRD00F1, if you're really interested).

I tried to resize the partitions: kernel panic. To rule out any problems in gparted, I repartitioned it with fdisk and tried to mkfs on it: kernel panic again. Could it be a problem related to the port I was connecting it to? I tried it in both the normal USB2 port and to the high-speed one: guess that? Kernel panic. Any attempt to write a reasonable amount of data on that disk resulted in a kernel panic, and in less than reassuring messages in the logs, like:

Apr 13 23:04:43 murray kernel: [  354.522385] xhci_hcd 0000:00:14.0: WARN: Stalled endpoint


Apr 13 23:06:06 murray kernel: [  437.835970] xhci_hcd 0000:00:14.0: ERROR Unknown event condition, HC probably busted

I found out that other people had problems with the xhci driver, and they were actually recognized as nasty bugs. Bad stuff: I had a disk about to break, and no chance to copy the data over onto the replacement. Uhm…

The nicest thing is that LMDE is compatible with Debian repositories so, if you do that carefully, you can actually mix Debian packages with the official ones in LMDE.

And that I did: installed a more up to date kernel image from Wheezy, and the problem was half-solved. The good half is that I was able to make a filesystem on the disk; the bad half is that, according to syslog, there is still some problem left:

Apr 14 12:46:48 murray kernel: [  622.462040] usb 2-3: reset SuperSpeed USB device number 2 using xhci_hcd
Apr 14 12:46:48 murray kernel: [  622.478321] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep ffff8802157b0ac0
Apr 14 12:46:48 murray kernel: [  622.478330] xhci_hcd 0000:00:14.0: xHCI xhci_drop_endpoint called with disabled ep ffff8802157b0b00

When that happens, the writes on the disk stand still for a fraction of second and then continue as normal. Not really optimal, but at least usable.

Everything fine? Well, no… When I decided to use packages from wheezy, I wanted to do it by enabling the official wheezy repositories, and set apt pins so that I could install them only if I requested them explicitly. But I haven't made it. I read the man pages for apt_preferences (again), and google'd about the subject (again), but no: that didn't work. So, in case you'd be so kind to suggest where I was wrong, here you are:

this was my /etc/apt/sources.list.d/wheezy.list:

deb http://ftp.uninett.no/pub/linux/debian wheezy main contrib non-free

and this was the latest pref file:

Explanation: Disable Wheezy
Package: *
Pin: release o=Debian,n=wheezy
Pin-Priority: 1

I also tried with a simpler "Pin" line with just "n", or by using the origin "ftp.uninett.no", and with different pin priorities, just in case (50, 1, -10). No way: packages in wheezy always got priority 500 and were always the preferred ones.

If you know where I was wrong, please share. For now I had to live with a porkaround: enable wheezy just for the time needed to install the new kernel, and then disable it again.



Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.