Repository navigation
Closed
Description
I've recently staretd seeing this error with my USB attached SATA 3.5" HDD. The device has been under use for more than a year. This error has been seen very recently. My guess, given the error code, and what I've understood from the conversation on debian-user [1], this could be a generic problem than being a hardware malfunction.
[62711.477903] sd 0:0:0:0: [sda] UNKNOWN(0x2003) Result: hostbyte=0x00 driverbyte=0x00
[62711.485701] sd 0:0:0:0: [sda] CDB: opcode=0x28 28 00 9d 40 01 47 00 00 08 00
[62711.492910] blk_update_request: I/O error, dev sda, sector 2638217543
[84370.313684] sd 0:0:0:0: [sda] UNKNOWN(0x2003) Result: hostbyte=0x00 driverbyte=0x00
[84370.321532] sd 0:0:0:0: [sda] CDB: opcode=0x28 28 00 a1 40 01 47 00 00 08 00
[84370.328721] blk_update_request: I/O error, dev sda, sector 2705326407
Reporting here hoping the latter.
I forgot to mention that I had also run a full fsck on the device, with no errors reported.
130 pi@pi:~$ sudo fsck -cvkv /dev/sdb1
[sudo] password for pi:
fsck from util-linux 2.25.2
e2fsck 1.42.12 (29-Aug-2014)
Checking for bad blocks (read-only test): done
SEAGATE: Updating bad block inode.
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
SEAGATE: ***** FILE SYSTEM WAS MODIFIED *****
20013 inodes used (0.02%, out of 122101760)
8944 non-contiguous files (44.7%)
53 non-contiguous directories (0.3%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 16695/3216/62
416471936 blocks used (85.28%, out of 488378008)
0 bad blocks
63 large files
17086 regular files
2885 directories
0 character device files
0 block device files
0 fifos
0 links
33 symbolic links (32 fast symbolic links)
0 sockets
------------
20004 files
1 pi@pi:~$
[1] https://lists.debian.org/debian-user/2016/02/msg00194.html
Metadata
Metadata
Assignees
Labels
No labels
Activity
popcornmix commentedon Feb 10, 2016
What does
uname -areport?If you believe it used to be more reliable, then find an older kernel that does work better.
You can find older kernel/firmware releases here:
https://github.com/Hexxeh/rpi-firmware/commits/master
click on a commit and you will the git hash at the end of the URL.
sudo rpi-update <git hash>will get you that version.
If you can find an older version that doesn't have this issue that may give a starting point to diagnose.
Is this Pi1 or Pi2? How are Pi and disk powered? Insufficient power supply would be one possible cause of these errors. As would a failing disk drive.
rickysarraf commentedon Feb 11, 2016
Thank you for your reply.
On Wed, 2016-02-10 at 10:44 -0800, popcornmix wrote:
pi@pi:~$ uname -a
Linux pi 4.1.16-v7+ #833 SMP Wed Jan 27 14:32:22 GMT 2016 armv7l
GNU/Linux
I'm trying to recollect what all was changed recently. One item that
came to mind was smartmontools. I've purged it now and am waiting
(24+hrs) to see if the error pops up again.
This is good. Wasn't aware of it. Thanks for sharing this information.
This is an RPi2. The Pi is powered with its dedicated power cord, which
further is connected to my UPS. The USB HDD Drives are 3.5" disks and
they too have dedicated external power connected to the UPS.
With smartmontools purged, I'm still monitoring. I'll post my findings
here on this tracker.
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."
mathieugouin commentedon Jul 21, 2016
Hello,
I was wondering if you have updates for this issue because I'm experiencing very similar symptoms.
If it can help, I'm running a pi 3 with Seagate backup plus slim 2TB.
[75617.284826] sd 0:0:0:0: [sda] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x07 driverbyte=0x08
[75617.284849] sd 0:0:0:0: [sda] tag#0 Sense Key : 0x4 [current] [descriptor]
[75617.284857] sd 0:0:0:0: [sda] tag#0 ASC=0x0 ASCQ=0x0
[75617.284869] sd 0:0:0:0: [sda] tag#0 CDB: opcode=0xa1 a1 06 20 da 00 00 4f c2 00 b0 00 00
[77417.115145] sd 0:0:0:0: [sda] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x07 driverbyte=0x08
[77417.115163] sd 0:0:0:0: [sda] tag#0 Sense Key : 0x4 [current] [descriptor]
[77417.115172] sd 0:0:0:0: [sda] tag#0 ASC=0x0 ASCQ=0x0
[77417.115184] sd 0:0:0:0: [sda] tag#0 CDB: opcode=0xa1 a1 06 20 00 00 00 00 00 00 e5 00 00
rickysarraf commentedon Jul 21, 2016
@mathieugouin There are a couple of things I did.
Point no 1 and 2 are just physical precautions. I don't have data to prove if they have made any difference.
3 Given that my HDD and RPi had only 5 mins of UPS Backup, I ended up writing a vUPS (Virtual UPS) script to detect and cleanly unmount my HDD before the battery ran out and the RPi (and HDD) got off.
Maybe point no. 3 has made the difference. I haven't seen those errors since these changes, which now is around 4+ months.
And I'm currently running on:
rickysarraf commentedon Jul 21, 2016
I just did a quick 10 GiB write on the drive. And no SCSI errors. So it could very well be one of the points above, or just a fix with the newer kernel.
@mathieugouin What kernel are you on? And what kernel did you see the errors on?
mathieugouin commentedon Jul 21, 2016
I'm using
Linux xbian 4.4.14+ #1 SMP PREEMPT Wed Jun 29 13:04:58 CEST 2016 armv7l GNU/LinuxI hope the dd you did was not the cause of the repeated link down/up?
rickysarraf commentedon Jul 23, 2016
I am not sure. I do have my router rebooting once a day, but these links falling are much more frequent. And that many link changes have happened in the uptime of 3 days, so there definitely is another bug too.
But, btw, I did see the SCSI error in the logs again.
mathieugouin commentedon Jul 26, 2016
I just upgraded to kernel Linux xbian 4.4.15+ and the issue is still present.
ezar commentedon Aug 6, 2016
Same here!
Using minibian 4.4.16+
mathieugouin commentedon Aug 8, 2016
@ezar, just by curiosity what is the make and model of your USB drive?
Mine is Seagate Backup Slim 2TB. It is currently formatted as NTFS. Let's see if we can find commonalities...
ezar commentedon Aug 8, 2016
@mathieugouin mine is Seagate 3TB.
Model Family: Seagate Barracuda 7200.14 (AF)
Device Model: ST3000DM001-1ER166
It's formatted as EXT4.
mathieugouin commentedon Aug 9, 2016
I just found out by analyzing more the dmesg message that I always have the following 4 lines in block that are logged:
By enabling the "human readable output" (command line option
-T), I was able to see that the blocks repeat roughly every 30 minutes...dmesg -T | grep tag#0 | grep UNKNOWNCould you check if you have something similar?
jantyikt commentedon Aug 9, 2016
Hm, I am seeing in my rpi3-s dmesg the same lines for a while. (and never before)
My root fs is on an usb drive. Slightly overclocked, but with a dektop cpu cooler, with the official rpi3 power supply, with raspbian. I use it for light desktop workloads every day, plus as a wireless access point (via the onboard chip, bt disabled).
I have two and two "half" setup to reproduce this:
I cannot report any problems, data corruptions/loss, slowdowns or crashes.
From my dmesg: http://pastebin.com/atRCBkRQ
Linux ***** 4.4.16-v7+ #899 SMP Thu Jul 28 12:40:33 BST 2016 armv7l GNU/Linux
Bus 001 Device 005: ID 1058:1100 Western Digital Technologies, Inc.
I hope it helps somewhat, maybe, I don't know.
ps: sorry for my English
Ruffio commentedon Aug 17, 2016
@rickysarraf has your issue been resolved? If so, please close this issue. Thanks.
rickysarraf commentedon Aug 18, 2016
@Ruffio Resolved? No. But is it really a bug? I don't know.
My inclination is that it is just may be a faulty hardware. But then, like I mentioned in the comments above, I've been able to avoid the scsi errors most of the times.
But given the number of users that have reported this issue, I'm not sure if this is a sign of faulty hardware.
31 remaining items
JamesH65 commentedon Jun 12, 2020
This is very old issue, and closed, but, this is purely a power problem. The Pi can provide 1.2A total across all the USB ports. You are likely exceeding that. Use a powered hub.
marcotini commentedon Jun 12, 2020
And a cable like this one can make a difference (plugging the other one on a different power supply)?
tim-devel commentedon Jun 12, 2020
I have been having this issue for 2+ years with a usb hard drive via a powered hub so not sure it is a power issue. I've never lost any data so just ignore the errors
3dr14n commentedon Jul 5, 2020
Same issue with my powered (12V2A) external drive bay Orico NS1066 for my WD80EZAZ-11T (ext4) connected to Raspberry Pi 4. The behavior is repeatable because as soon as iowait become high while playing 60GB H265 video via Kodi installed in Raspbian, the HDD disconnects from, for example
sdbthen reconnects tosdc.Jul 5 19:04:04 megaserver kernel: [81232.365054] usb 2-2: Disable of device-initiated U1 failed.Jul 5 19:04:09 megaserver kernel: [81237.393757] usb 2-2: Disable of device-initiated U2 failed.Jul 5 19:04:18 megaserver kernel: [81246.141910] sd 1:0:0:0: [sdb] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x07 driverbyte=0x00Jul 5 19:04:18 megaserver kernel: [81246.141920] usb 2-2: USB disconnect, device number 3Jul 5 19:04:18 megaserver kernel: [81246.141930] sd 1:0:0:0: [sdb] tag#0 CDB: opcode=0x88 88 00 00 00 00 00 a4 ee 3e e0 00 00 04 00 00 00Jul 5 19:04:18 megaserver kernel: [81246.142295] sd 1:0:0:0: [sdb] tag#0 UNKNOWN(0x2003) Result: hostbyte=0x07 driverbyte=0x00Jul 5 19:04:18 megaserver kernel: [81246.142313] sd 1:0:0:0: [sdb] tag#0 CDB: opcode=0x88 88 00 00 00 00 00 a4 ee 4a e0 00 00 02 00 00 00The only solution is to restart, for the hdd to reconnect again via its default mount-point in fstab.
pelwell commentedon Jul 5, 2020
Try disabling UAS by following this guide: https://www.raspberrypi.org/forums/viewtopic.php?t=245931
3dr14n commentedon Jul 6, 2020
UAS was already disabled when issuing a
lsusb -tthe driver was already inusb-storageeven without applying quirks in cmdline.txt. Sure enough, I tried it anyway as instructed in the link provided for curiosity's sake but still the same behavior, disconnection and reconnection.My main issue now could be because Norelsys NS1066 could be faulty but this issue does not happen on the earlier days of Pi4. Before I can copy 100GB of zip file to the same drive without any problem (via ethernet) but now I can't do the same, even media playback via Kodi makes the drive disconnect and reconnect afterwards.
I won't associate this with power issue because the dock was already powered via 12V2A.
The drive disconnects as soon as iowait became red while being monitored via terminal using glances.
Thermal is not an issue either because the Pi and the HDD are cooled via 120mm fan intake. The Pi4 were kept cool below 55°C while playing Kodi.
I'm not doing any Overclocking with the Pi4.
I'm wondering if there were changes with the USB 3 chip in Pi4 that could cause this issue?
Addendum:
usb-storagedriver by default.sudo mount -awill remount it to its default mount-point specified in fstab. Reading small data such as opening files, images, videos (below 1GB) has no problem.I tried to copy a 2.6GB video from Windows 10 to the HDD connected via samba and the file were copied successfully, copying the same video from the HDD causes the drive to disconnect and reconnect which interrupts the file copy.
sudo mount -awill mount it to its proper mounting point specified in fstab.Update
Yep, the issue is due to Norelsys NS1066. Lots of reports in Linux forums with the same chip.
andrewufrank commentedon Dec 7, 2020
I had exectly the same error msg - with a very different setup (odroid xu4 - armbian debian buster) and remembered having seen it before: it was caused by insufficient power supply (as suggested above by others). I changed the powersupply from 4A to 6A and the problem is gone. -- This mostly as a message to others!
cslev commentedon Jan 4, 2024
While the thread's last comment is more than 3 years old, the problem still exists :)
I am having a raspberry pi 4 enclosed in a Geekworm Naspi Gemini https://geekworm.com/collections/raspberry-pi/products/x882?_pos=4&_ss=r.
While I have indeed two SSDs connected to the pi, I encounter this error also when writing/reading from only one of them. And because there are occasional writings/readings (e.g., media streams, downloads, nextcloud), I face this problem every day and only reboot helps.
Power and heating are not issues for me either. I purposely use a 12V5A charger to provide sufficient power. A fan is also inside the case, and has never been above 55 C (I monitor it with Prometheus and Grafana).
I believe that maybe the USB cable or the NASpi Gemini board causes the issue, but did not bother yet to open the case, and connect the disks by other means (e.g., powered USB SSD enclosure, other geekworm naspi products) before someone can confirm similar findings :)
andrewufrank commentedon Jan 4, 2024
i have now several raspi4 running the debian raspi images from https://raspi.debian.net/tested-images/ and have no problems - but my power supply is 6A. I saw the issue when i had a 4A power supply. perhaps the 5A are not enough to deal with the spikes when writing. before anything else, I would put in a larger powersupply and change the usb cable!
cslev commentedon Jan 4, 2024
I actually use a step-down converter which is precisely set to 5V from 12V. Since the charger can deliver 5A on 12V, after reducing the consumption to 5V only, I would not expect power issue.
But you are right, I should give it a try...however, I find it quite difficult to get 5V charger with more than 4A support. Do you have any good source for buying something like yours?
pelwell commentedon Jan 4, 2024
Be careful using chargers as power supplies - although they do the same job, the requirements for a charger are a bit more relaxed; a momentary loss of charging probably won't affect your device whereas a brief loss of power probably will.
cslev commentedon Jan 4, 2024
oh sorry, i am using power supply, not a charger. Just usually interchange those words, but thanks for pointing this out 👍
andrewufrank commentedon Jan 4, 2024
my 5v6a power supply i bought for another cpu. it is meanwell sga60e05 and then have a converter from barel connector to usb. i see it still on offer for $28 (I hope I paid less five years ago, I bought several!). it worked well with the odroid-xu4 and now with the raspi4. @pelwell Thank you for the hint. I had naively assumed they would be to the same specs.
andrewufrank commentedon Jan 9, 2024
I remember that I have troubles if added two hard drives (the second with its own power supply, the first is a regular 2.5" 3TB drive). I never investigated what was the cause; there were simpler ways to make a backup.
cslev commentedon Jan 11, 2024
I use one harddrive for media, and the other one for nextcloud. But I will merge them into the same drive and use only a USB enclosure with external power instead of buying the whole gemini board. Or maybe just buy a smaller board with a single SATA slot.
Thanks for the comments, though