fastbike
Posts: 7
Joined: Fri Sep 22, 2023 1:51 am

Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Mon Sep 25, 2023 6:11 am

I'm looking for a reliable solution for an automation project and do not want to be subject to microSD card corruption if there are power supply issues.

I've ordered a board which attaches under the Pi (2GB model) and can mount a M.2 SATA SSD. Power and data is supplied by a USB jumper connection.

How much power is this likely to realistically require ?
I've read that SSDs are reasonably low power when idle but can draw up to 5 or 6 W when active (writing etc).

How much more should I add for the Pi ?

User avatar
Gavinmc42
Posts: 8005
Joined: Wed Aug 28, 2013 3:31 am

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Mon Sep 25, 2023 7:19 am

One SSD is usually ok, I run one on a USB4/Sata adapter on this Pi400.
The USB ports can handle 1.2Amps max, so about 6Watts.
Look at low power/current SSD's, check the specs.

The driver/interface chip is important too, one brand/chip is notoriously bad.

The Pi4 itself is about 5-9W, depending on CPU/GPU load.
I'm dancing on Rainbows.
Raspberries are not Apples or Oranges

kip_the_elder
Posts: 658
Joined: Mon May 03, 2021 3:49 pm
Location: Third Rock from the Sun

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Mon Sep 25, 2023 7:38 am

There is a sticky about USB/Sata adapters.

You will save yourself a lot of hassle if you read it. :D
Always be kind to beginner geeks. They will be the ones programming your ventilator. :)

fastbike
Posts: 7
Joined: Fri Sep 22, 2023 1:51 am

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Mon Sep 25, 2023 6:31 pm

A link would be helpful thanks.
Don't think I posted here without doing my research first :)

bjtheone
Posts: 2722
Joined: Mon May 20, 2019 11:28 pm
Location: The Frozen North (AKA Canada)

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Mon Sep 25, 2023 6:45 pm

fastbike wrote:
Mon Sep 25, 2023 6:11 am
I'm looking for a reliable solution for an automation project and do not want to be subject to microSD card corruption if there are power supply issues.
You are potentially solving the wrong problem.

The issue is not that microSD cards are significantly more susceptible to corruption than SSD, the issue is that Linux file systems do not like being powered down in an unclean state. At first pass, a microSD card based solution may be more reliable since it will be well within the power envelope of the Pi and not subject to the quirks and potential pitfalls of the USB-SATA adaptor required for the SSD solution. Ensuring stable power and controlled shutdowns will solve most of your file system corruption issues. Moving to a read only file system for the OS will also help ensure that the Pi comes back up after an unscheduled power outage.

Depending out your use case requirements, a small HAT based UPS, providing enough power for clean shutdowns and some power filtering may be adequate. Longer runtimes are going to require a larger capacity UPS. A small APC UPS may be the most cost effective solution.

The SSD based solution will have higher performance access to the filesystem which may or may not be relevant to your use case.

User avatar
Gavinmc42
Posts: 8005
Joined: Wed Aug 28, 2013 3:31 am

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Tue Sep 26, 2023 1:43 am

You are potentially solving the wrong problem.

The issue is not that microSD cards are significantly more susceptible to corruption than SSD, the issue is that Linux file systems do not like being powered down in an unclean state.
Yep, a ram based OS like PiCore that does not write to the uSD is much more reliable.
I run those 24/7 for years.
A small baremetal Kernel like Ultibo can even get away with using a 64MB single level flash uSD.
I'm dancing on Rainbows.
Raspberries are not Apples or Oranges

redvli
Posts: 1542
Joined: Thu Sep 03, 2020 8:09 am

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Tue Sep 26, 2023 5:04 am

fastbike wrote:
Mon Sep 25, 2023 6:11 am
I'm looking for a reliable solution for an automation project and do not want to be subject to microSD card corruption if there are power supply issues.

I've ordered a board which attaches under the Pi (2GB model) and can mount a M.2 SATA SSD. Power and data is supplied by a USB jumper connection.

How much power is this likely to realistically require ?
I've read that SSDs are reasonably low power when idle but can draw up to 5 or 6 W when active (writing etc).

How much more should I add for the Pi ?
If you want reliability, don't use that setup as is, but power the SSD via extra own power, usually people use an externally powered USB3 hub. Maybe you are lucky and that SSD behaves well w.r.t. power.
My home automation was and is simply unreliable if I don't use an externally powered USB3 hub, although the Samsung SSD says 0.87A and the USB3-SATA adaptor is the well-known/reliable Startech with ASMedia chipset. I have been looking so much at USB3 restart handler stuff from my the Pi4-8GB, that I won't buy a similar hardware setup again. Mission to use aarch64 system instead of x86_64 system is completed for me over the last 15 years or so.

redvli
Posts: 1542
Joined: Thu Sep 03, 2020 8:09 am

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Tue Sep 26, 2023 5:44 am

bjtheone wrote:
Mon Sep 25, 2023 6:45 pm
The issue is not that microSD cards are significantly more susceptible to corruption than SSD, the issue is that Linux file systems do not like being powered down in an unclean state.
The Ext4 filesystem has no emotions, it is not a matter of whether it likes sudden power loss or not. Maybe you have had have too much bad experiences with Ext2 (or FAT). Maybe a Linux Copy-On-Write filesystem also don't like sudden power loss, I have never asked such a filesystem for its feelings about it. What I know is that I don't like to spend money on some overpriced Pi UPS. And I like that I can have my solar powered Pi3B losing its power randomly at least once a day without worrying about filesystem corruption. And still be able to push a Gigabyte or so per day to it on its USB2 connected HDD.

bjtheone
Posts: 2722
Joined: Mon May 20, 2019 11:28 pm
Location: The Frozen North (AKA Canada)

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Tue Sep 26, 2023 7:37 pm

redvli wrote:
Tue Sep 26, 2023 5:44 am
bjtheone wrote:
Mon Sep 25, 2023 6:45 pm
The issue is not that microSD cards are significantly more susceptible to corruption than SSD, the issue is that Linux file systems do not like being powered down in an unclean state.
The Ext4 filesystem has no emotions, it is not a matter of whether it likes sudden power loss or not. Maybe you have had have too much bad experiences with Ext2 (or FAT). Maybe a Linux Copy-On-Write filesystem also don't like sudden power loss, I have never asked such a filesystem for its feelings about it. What I know is that I don't like to spend money on some overpriced Pi UPS. And I like that I can have my solar powered Pi3B losing its power randomly at least once a day without worrying about filesystem corruption. And still be able to push a Gigabyte or so per day to it on its USB2 connected HDD.
Fair callout for imprecise language phrasing, though I suspect that most would translate "do not like" to in this context to "is unadvisable to". I am very aware that neither software or hardware has feelings or emotions.

I have personally experienced corruption and unclean file systems after power disruptions. fsck can usually repair the issue.

User avatar
thagrol
Posts: 10406
Joined: Fri Jan 13, 2012 4:41 pm
Location: Darkest Somerset, UK

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Tue Sep 26, 2023 9:45 pm

redvli wrote:
Tue Sep 26, 2023 5:04 am
If you want reliability, don't use that setup as is, but power the SSD via extra own power, usually people use an externally powered USB3 hub. Maybe you are lucky and that SSD behaves well w.r.t. power.
My home automation was and is simply unreliable if I don't use an externally powered USB3 hub, although the Samsung SSD says 0.87A and the USB3-SATA adaptor is the well-known/reliable Startech with ASMedia chipset. I have been looking so much at USB3 restart handler stuff from my the Pi4-8GB, that I won't buy a similar hardware setup again. Mission to use aarch64 system instead of x86_64 system is completed for me over the last 15 years or so.
0.87A plus current for the bridge adapter is getting close to the theoretical limit for bus powered devices - that's the most likely reason for any SSD related problems you were seeing.

Having a separate power supply won't actually help with many of the problems - most are caused by unsafe/unclean shutdowns of the Pi or its OS. Plus in a battery powered situation it's double the number of batteries to monitor and manage.* And you'll still need some way to power the drive off as current consumption is not zero even when the drive is idle.

Does a separate PSU for the drive reduces the likelyhood of brown outs and related failures compared to a single PSU? Yes. But it does nothing to protect against other sources of damage.

[edit]*: that doesn't apply in the OP's case[/edit]
Knowledge, skills, & experience have value. If you expect to profit from someone's you should expect to pay for them.

All advice given is based on my experience. it worked for me, it may not work for you.
Need help? https://github.com/thagrol/Guides

kip_the_elder
Posts: 658
Joined: Mon May 03, 2021 3:49 pm
Location: Third Rock from the Sun

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Thu Sep 28, 2023 6:19 am

Does your application require any writes to the drive?

If not, one way to improve reliability might be to make the SD card RO. Or could you write to a virtual disk in RAM? Corruption only tends to occur when the file system is being written to. Then you could dispense with the SSD too..one less point of failure.

I use PIs with SD card only on a yacht. System voltage tends to be all over the place. So, with any that need to be left on, I set them as RO. Touch wood; no problems with corruption.
Always be kind to beginner geeks. They will be the ones programming your ventilator. :)

redvli
Posts: 1542
Joined: Thu Sep 03, 2020 8:09 am

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Thu Sep 28, 2023 7:11 am

thagrol wrote:
Tue Sep 26, 2023 9:45 pm
redvli wrote:
Tue Sep 26, 2023 5:04 am
If you want reliability, don't use that setup as is, but power the SSD via extra own power, usually people use an externally powered USB3 hub. Maybe you are lucky and that SSD behaves well w.r.t. power.
My home automation was and is simply unreliable if I don't use an externally powered USB3 hub, although the Samsung SSD says 0.87A and the USB3-SATA adaptor is the well-known/reliable Startech with ASMedia chipset. I have been looking so much at USB3 restart handler stuff from my the Pi4-8GB, that I won't buy a similar hardware setup again. Mission to use aarch64 system instead of x86_64 system is completed for me over the last 15 years or so.
0.87A plus current for the bridge adapter is getting close to the theoretical limit for bus powered devices - that's the most likely reason for any SSD related problems you were seeing.
The Startech would then draw more than 0.33A. Maybe it does. If I want to know, I should measure it long term with a high enough sampling rate. Maybe the Samsung uses more than 0.87A every now and then. Same thing, measure. But it is not worth the effort for me. I have same low-power Intel hardware that hasn't that problem and the Pi4 is relatively old and slow if I look at the current competing solutions. It is more effective to buy a 1T low-power NVME and faster board that has a single 12V barrel jack as power. It saves me quite some work. Or 48V (PoE base).
Having a separate power supply won't actually help with many of the problems - most are caused by unsafe/unclean shutdowns of the Pi or its OS. Plus in a battery powered situation it's double the number of batteries to monitor and manage.* And you'll still need some way to power the drive off as current consumption is not zero even when the drive is idle.

Does a separate PSU for the drive reduces the likelyhood of brown outs and related failures compared to a single PSU? Yes. But it does nothing to protect against other sources of damage.
It creates another risk I would say. The system stability responsibility is on you as user, not on supplier/factory.
There can always be other issues unknown. Like that the APC UPS does nasty things to the Pi official PSU for example. But my Asrock Intel fanless board is on the same APC UPS and doesn't crash. unsafe/unclean shutdowns is simply out of scope, problems are not on filesystem level, but kernel module for VIA USB3 and/or Pi4 (my 8GB 1.4. variant) _hardware+firmware. They were also there with openSUSE Tumbleweed. I don't use Ext4 but Btrfs, if it would be that area I would be easy to notice.

hippy
Posts: 15169
Joined: Fri Sep 09, 2011 10:34 pm
Location: UK

Re: Power Consumption for Pi4B and M.2 SATA SSD (512GB)

Thu Sep 28, 2023 5:04 pm

fastbike wrote:
Mon Sep 25, 2023 6:11 am
I've read that SSDs are reasonably low power when idle but can draw up to 5 or 6 W when active (writing etc).
I was gifted a 256GB NVMe recently and I was trying to figure out how to use it, if it was even worth it, given it's rated at "3.3V 2A" according to its label. I'm not even sure it would work with a Pi 5 and a suitable HAT without an extra power supply.

Return to “Troubleshooting”