XU4 v139 lost SSD

Having issues with your DietPi installation, or, found a bug? Post it here.
Post Reply
User avatar
johnvick
Legend
Posts: 693
Joined: Wed Jun 08, 2016 11:53 am
Location: New Zealand

XU4 v139 lost SSD

Post by johnvick »

Hi all,

I have an SSD mounted as USB_2 that is primarily used to store automated downloads and backups - the file system is on an eMMC. I was away on holiday and accessing the XU4 by SSH when the SSD appeared to fail. Rebooting did not make any difference. On return home power cycling the device brought it back to life (incidentally "shutdown now" caused a reboot, not a shutdown, but this is probably unrelated - I had to pull the plug to achieve a power cycle).

Any ideas on how to investigate this? This is not the first time I have lost the SSD in this way. The PSU I have is rated at 6A and usually the device runs for days on end without problem and I only reboot for dietpi updates.
User avatar
Fourdee
Site Admin
Posts: 2782
Joined: Tue Feb 06, 2007 1:36 pm

Re: XU4 v139 lost SSD

Post by Fourdee »

Hi John,

Sounds like a few possible issues, all wrapped up into one :(

In the middle of basting/cooking Turkey, back and forth, so most of this is in note form lol :)

SSD Things to try/check/thoughts
  • Odroid SATA converter failing (if used)?
  • insufficient power (6A should be more than enough though). How many other USB devices are attached to the XU4? Might also be worth capping CPU limit to 1.0Ghz to reduce the power spike under full load (dietpi-config > performance), possible PSU is dropping voltage below 4.8v?
  • Check SMART status for failure rates/values on the drive. Possible its past its MBTF/Write limit.
(incidentally "shutdown now" caused a reboot, not a shutdown
We had users report this with a corrupt image (c1/c2 a while back). I'll redo the XU4 image after Xmas just in case its corrupt at our end. Probably best to do a fresh install once thats done, due to issues you are experiencing on current install.

Merry Xmas :)
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal or become a DietPi patron.
User avatar
k-plan
Posts: 416
Joined: Sun Feb 28, 2016 5:28 pm

Re: XU4 v139 lost SSD

Post by k-plan »

Hi John,

Which device is your SSD in your installation? sda?

If so, it is worth to have a look at the end of:

Code: Select all

cat /etc/hdparm.conf


and disable spindown and APM for your SSD device.

Or it is possible, your SSD you are using, need some special hdparm commands, to work proper.

In spite of everything, we wish you and all your family a merry Christmas.

cu
k-plan
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal and Bitcoin.
User avatar
johnvick
Legend
Posts: 693
Joined: Wed Jun 08, 2016 11:53 am
Location: New Zealand

Re: XU4 v139 lost SSD

Post by johnvick »

Hi and merry Christmas -

Fourdee - the SSD is on the cloudshell SATA to USB3 adaptor and seems back to normal. I'll hold off on reducing the CPU as to me it seems like keeping a car in second gear :) How do I check SMART status on the drive?

As to "shutdown now" causing a reboot, poweroff does as it should. I'll live with this rather than do a fresh install.

K-plan - cat /etc/hdparm.conf gibes this:

#/dev/sda {
# #10 mins
# spindown_time = 120
#
# #
# apm = 254
#}

Obviously spindown is not needed for an SSD but how do I disable this and APM?

John
User avatar
k-plan
Posts: 416
Joined: Sun Feb 28, 2016 5:28 pm

Re: XU4 v139 lost SSD

Post by k-plan »

Hi John,
johnvick wrote:Obviously spindown is not needed for an SSD...
Totally agree, so I ask for this, because DiePi will do this by default:

Code: Select all

root@Odroid-C1:~# cat /etc/hdparm.conf

...

#DietPi external USB drive. Power management settings.
/dev/sda {
        #10 mins
        spindown_time = 120

        #
        apm = 254
}
It was only a idea you can have a look.
johnvick wrote: ... but how do I disable this and APM?
If I read your summary of hdparm.conf, it is currently disable by comment out.

cu
k-plan
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal and Bitcoin.
User avatar
Fourdee
Site Admin
Posts: 2782
Joined: Tue Feb 06, 2007 1:36 pm

Re: XU4 v139 lost SSD

Post by Fourdee »

johnvick wrote:How do I check SMART status on the drive?
I was going to suggest trying this: https://www.howtoforge.com/checking-har ... ian-ubuntu

But appears the XU4 Sata > USB converter doesnt support reading SMART data:

Code: Select all

root@DietPi:~# smartctl -a /dev/sda
smartctl 6.4 2014-10-07 r4002 [armv7l-linux-3.10.103+] (local build)
Copyright (C) 2002-14, Bruce Allen, Christian Franke, www.smartmontools.org

/dev/sda: Unknown USB bridge [0x05e3:0x0735 (0x1003)]
Please specify device type with the -d option.

Use smartctl -h to get a usage summary

So your best bet would be to plug it into another system via SATA cable. On Windows you could use something like : http://www.howtogeek.com/134735/how-to- ... -is-dying/
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal or become a DietPi patron.
User avatar
johnvick
Legend
Posts: 693
Joined: Wed Jun 08, 2016 11:53 am
Location: New Zealand

Re: XU4 v139 lost SSD

Post by johnvick »

Thanks Fourdee I'll give this a try this weekend.

John
Post Reply