Connecting NTFS drive crashes RPi4- power issue? Topic is solved

Having issues with your DietPi installation or found a bug? Post it here.
Post Reply
chucklesmcgee
Posts: 51
Joined: Tue Jun 02, 2020 7:19 pm

Connecting NTFS drive crashes RPi4- power issue?

Post by chucklesmcgee »

Running an RPi4 on a clean install of Dietpi 7.3.2 off of a USB connected NVME running headless. Seems fine.

Now connecting a 5TB NTFS 2.5" drive over USB to the second USB3.0 port seems to cause the system to crash. I tried connecting it while running Dietpi-drive_manager. Drive_Manager just closes, and then all other commands stop working.

Code: Select all

[FAILED] DietPi-Drive_Manager | Failed to remove scripts working directory: /tmp                   /DietPi-Drive_Manager
root@DietPi:~# htop
-bash: /usr/bin/htop: Input/output error
root@DietPi:~# nano /boot/dietpi.txt
-bash: nano: command not found
root@DietPi:~# ls
-bash: ls: command not found
root@DietPi:~# dietpi-config
-bash: /boot/dietpi/dietpi-config: /bin/bash: bad interpreter: Input/output error
root@DietPi:~# reboot
-bash: reboot: command not found
Trying to boot with the drive connected results in the Rpi4 being inaccessible when headless.

Is this consistent with insufficient power? I'll invest in a cable to separately power the drive but wanted to check first.
User avatar
Joulinar
Posts: 5090
Joined: Sat Nov 16, 2019 12:49 am

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by Joulinar »

Hi,

usually we recommend to have external drives powered externally to avoid power issues.

what happen if you connect the 2nd drive to one of the USB2 ports?

Are you able to check for kernel error massages once your system fails?

Code: Select all

dmesg -l err,crit,alert,emerg
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
chucklesmcgee
Posts: 51
Joined: Tue Jun 02, 2020 7:19 pm

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by chucklesmcgee »

After I connect the drive I get nothing. But before I connect the drive I get:

Code: Select all

[    4.966452] Under-voltage detected! (0x00050005)
[   17.060163] Under-voltage detected! (0x00050005)
[   47.300189] Under-voltage detected! (0x00050005)
[ 1188.356210] Under-voltage detected! (0x00050005)
[ 2089.508141] Under-voltage detected! (0x00050005)
[ 2988.644137] Under-voltage detected! (0x00050005)
[ 3530.948138] Under-voltage detected! (0x00050005)
[ 3889.796153] Under-voltage detected! (0x00050005)
[ 4788.932652] Under-voltage detected! (0x00050005)
[ 5331.236130] Under-voltage detected! (0x00050005)
[ 5688.068147] Under-voltage detected! (0x00050005)
[ 6589.220129] Under-voltage detected! (0x00050005)
[ 7131.524127] Under-voltage detected! (0x00050005)
[ 7488.356163] Under-voltage detected! (0x00050005)
[ 8389.508132] Under-voltage detected! (0x00050005)
[ 8931.812101] Under-voltage detected! (0x00050005)
[ 9288.644134] Under-voltage detected! (0x00050005)
[ 9407.588123] Under-voltage detected! (0x00050005)
[10187.784171] Under-voltage detected! (0x00050005)
[10732.100120] Under-voltage detected! (0x00050005)
[11088.932094] Under-voltage detected! (0x00050005)
[11558.660105] Under-voltage detected! (0x00050005)
I think I'll try a cable that separately supplies the drive.
User avatar
Joulinar
Posts: 5090
Joined: Sat Nov 16, 2019 12:49 am

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by Joulinar »

You have the message right from the start of the system. Ensure your device is correctly powered
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
chucklesmcgee
Posts: 51
Joined: Tue Jun 02, 2020 7:19 pm

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by chucklesmcgee »

Good point. I had switched the power adapter for what I thought was beefier, but that was creating errors. Switched that back, no undervolt errors before or after plugging into USB 2.0 port.

Plugged the 2.5" HDD into the USB 2.0 port, device did not crash immediately, but on running dietpi-drive_manager had the device hang and:

Code: Select all

/boot/dietpi/func/dietpi-globals: line 464: mawk: command not foundnux-gnu/libne/boot/dietpi/func/dietpi-globals: line 471: stty: command not found
/boot/dietpi/func/dietpi-globals: line 473: ((: <= 120 : syntax error: operand expected (error token is "<= 120 ")line 160: ((: i<: syntax error: operand expect/boot/dietpi/func/dietpi-globals: line 479: ((: >= 7 : syntax error: operand expected (error token is ">= 7 ")
/boot/dietpi/func/dietpi-globals: line 774: /bin/rm: Input/output error
/boot/dietpi/func/dietpi-globals: line 464: mawk: command not found
/boot/dietpi/func/dietpi-globals: line 471: stty: command not found
/boot/dietpi/func/dietpi-globals: line 473: ((: <= 120 : syntax error: operand expected (error token is "<= 120 ")
/boot/dietpi/func/dietpi-globals: line 479: ((: >= 7 : syntax error: operand expected (error token is ">= 7 ")
/boot/dietpi/func/dietpi-globals: line 693: /usr/bin/whiptail: Input/output error
/boot/dietpi/func/dietpi-globals: line 159: stty: command not found
/boot/dietpi/func/dietpi-globals: line 160: ((: i<: syntax error: operand expected (error token is "<")
I think it probably is a power issue. Ordered a cable and we'll see what happens.
User avatar
Joulinar
Posts: 5090
Joined: Sat Nov 16, 2019 12:49 am

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by Joulinar »

looks like you are loosing connection to your USB connected NVME. Try to have external devices powered external. As well check if the power supply of the RPi is working correctly. Use an original one and not a mobile device charger.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
chucklesmcgee
Posts: 51
Joined: Tue Jun 02, 2020 7:19 pm

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by chucklesmcgee »

Great, using a decent charger gives me no undervolting errors even when overclocking.

I then acquired a dual USB power to separately power this USB drive here- https://www.amazon.com/gp/product/B00VJ ... UTF8&psc=1

Connecting the power end of the HDD cable to a 2 amp charger then seemed to do the trick.

I first plugged the data end into the RPi4 after the power cable while the RPi4 was on and it seems to have made it crash and lock up. Restarting the RPi4 fixed this. Ran dietpi-drive_manager and the system automatically installed NTFS drivers and the drive mounted smoothly with decent benchmarks

I got these messages, but I assume that's fine.

Code: Select all

[    0.444739] bcm2708_fb soc:fb: Unable to determine number of FBs. Disabling driver.
[    2.341907] sd 1:0:0:0: [sdb] No Caching mode page found
[    2.341914] sd 1:0:0:0: [sdb] Assuming drive cache: write through
Thanks for your help! Hope this helps other people running int odrive issues.
User avatar
MichaIng
Site Admin
Posts: 3088
Joined: Sat Nov 18, 2017 6:21 pm

Re: Connecting NTFS drive crashes RPi4- power issue?

Post by MichaIng »

Great :). Yes those three "errors" are expected with USB drives attached and with no screen attached.
Post Reply