Wrong capacity detected for hard drives attached to external enclosure after reboot
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- c, linux
- Domain
- operating-systems
Research direction
Start by reproducing the Raspberry Pi 4 setup with the Orico 4 Bay enclosure, rebooting while it remains powered, and comparing blockdev --getsize64 and df -PTh for the affected disk. Use the reported Raspberry Pi OS and kernel version as the baseline. Done means the disk capacity is detected correctly after reboot or power cycling the Pi without powering off the enclosure.
Written by the indexing model from the issue text.
Description
Is this the right place for my bug report?
I've reported this bug that I was thinking was related to blockdev command, but the developer suggested that it is a Kernel issue
Describe the bug
I have an Orico 4 Bay enclosure that I use with 2 HDDs for now on a Rspberry Pi4 64 bit updated to the latest version of Debian Buster and running OMV.
If I turn on the enclosure and afterwards the system everything works fine. If I reboot the system, or if I turn it of and turn it on again without turning off the enclosure at the next boot the blockdev
This is the output of the command when I turn on the enclosure and power up the system afterwards:
pi@raspberrypi:~ $ sudo blockdev --getsize64 /dev/sdb
8001563222016
pi@raspberrypi:~ $ sudo df -PTh | grep /dev/sdb
/dev/sdb1 btrfs 7.3T 2.2T 5.2T 29% /srv/dev-disk-by-label-01
This is the output of the command if I reboot or if I shutdown and power on again without turning off and on the enclosure:
pi@raspberrypi:~ $ sudo blockdev --getsize64 /dev/sdc
129986248068418560
pi@raspberrypi:~ $ sudo df -PTh | grep /dev/sdc
/dev/sdc1 btrfs 7.3T 2.2T 5.2T 29% /srv/dev-disk-by-label-01
If I use the system in this condition after some minutes it becomes unstable and I have to turn everything off and back on.
To reproduce
I've tried and I experience this issue even on new OS installation of Raspberry OS 32 and 64 bits
Expected behaviour
Be able to detect the disk capacity correctly if I reboot the Pi or if I turn it off and back on again without powering off the enclosure.
System
- Which model of Raspberry Pi?
Pi4 4GB - Which OS and version (
cat /etc/rpi-issue)?
Raspberry Pi reference 2020-05-27
Generated using pi-gen, https://github.com/RPi-Distro/pi-gen, 30e2dd32ba47cc3bec15ab1413c16a17e5797775, stage4 - Which firmware version (
vcgencmd version)?
Copyright (c) 2012 Broadcom
version ab1181cc0cb6df52bfae3b1d3fef0ce7c325166c (clean) (release) (start_cd) - Which kernel version (
uname -a)?
Linux raspberrypi 5.4.79-v8+ #1373 SMP PREEMPT Mon Nov 23 13:32:41 GMT 2020 aarch64 GNU/Linux
- Dominant language
- C
- Stars
- 13.2k
- Forks
- 5.5k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 21
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from raspberrypi/linux
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
raspberrypi/linux#7415 · 2 comments · 1 reaction ·
-
rp1-cfe doesn't forward V4L2_EVENT_SOURCE_CHANGE event from csi-2 sensor driver to userspace app Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
raspberrypi/linux#7399 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 82/100
raspberrypi/linux#7357 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
raspberrypi/linux#7054 · 2 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
raspberrypi/linux#7634 · 8 comments · 1 reaction ·
All issues in raspberrypi/linux
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
zephyrproject-rtos/zephyr#119726 ·
-
[Bounty proposal] fix(web): memory insights count an evening memory on the next day ($25 proposed) Open
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
BasedHardware/omi#15320 ·
-
[adam] AdamNet network read doesn't cap to MAX_ADAM_PACKET_LEN, overflows client receive buffers Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
FujiNetWIFI/fujinet-firmware#1649 · 2 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
HarbourMasters/Shipwright#7229 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
riscv-software-src/riscv-isa-sim#2435 · 1 comment ·