News for hackers. Stuff that matters.
Re:A cheaper, smaller Raspberry Pi 3 is now available by pulse7 on Thursday November 15, 2018 @12:21PM (#18461191)
First: Your SD cards are most probably not destroyed, but have corrupt file system due to the unsafe shutdown. Second: You can boot from USB with no micro SD with latest firmware. RPI will look first for SD card and then try to boot from USB if no SD card is found. You can even set a one-time-programmable (OTP) bit to skip SD card lookup.
Re:A cheaper, smaller Raspberry Pi 3 is now available by mrguyorama on Thursday November 15, 2018 @01:25PM (#18461839)
You can also do PXE boot too
Re:A cheaper, smaller Raspberry Pi 3 is now available by dijit on Thursday November 15, 2018 @03:43PM (#18463095)
How would PXE boot work on the 3+? It doesn't have Ethernet.
Re:A cheaper, smaller Raspberry Pi 3 is now available by mmetzger on Thursday November 15, 2018 @04:00PM (#18463254)
The 3B+ has ethernet (and it's gigabit - at least gig sync - ~250Mb/s max actual transfer due to USB2.) The new one (3A+) does not have ethernet but is still capable of USB booting.
Re:A cheaper, smaller Raspberry Pi 3 is now available by dijit on Friday November 16, 2018 @07:59AM (#18468399)
Sorry, I meant the 3A+.

The questions stands; how would it PXE?

Re:A cheaper, smaller Raspberry Pi 3 is now available by andyidsinga on Thursday November 15, 2018 @12:42PM (#18461392)
yep -- I've had this exact issue on zero w - corrupt FS, but not physically destroyed.
Re:A cheaper, smaller Raspberry Pi 3 is now available by mrsteveman1 on Thursday November 15, 2018 @06:26PM (#18464475)
I have probably 8-9 Zero W boards in projects at this point, running everything from cat cams, temperature sensors in various rooms, even my stereo amplifier is controlled by (but not passing audio through) a Pi Zero W.

All of them now have a very specific model industrial MicroSD card in them, and none have lost or corrupted data, or refused to boot, since those cards were added. They had SanDisk ultra cards before that, and they had to be reinstalled all the time.

I picked the card because it's an aMLC* model (cheap overall, $15 for 4GB, $25-28 for 8GB), which significantly improves write endurance even compared to MLC cards, and because the controller is designed to handle sudden power loss, which is where a lot of these Pi+SD problems come from; consumer MicroSD cards are generally designed for use in devices that have batteries and rarely if ever lose power suddenly, so the controller can take risks for optimization that it wouldn't otherwise want to take.

They're also rated down to 0C, which I can say is definitely true as I have some operating close to that right now.

This is the card: https://www.digikey.com/product-detail/en/atp-electronics-in...

4GB isn't huge in a world where 32/64GB cards are common for a similar price, but a full headless OS installation doesn't even take half of that, and there's no real use for more space most of the time.

* with aMLC mode, it's still MLC flash (so cheaper than SLC), but each cell only stores a single bit rather than 2 (MLC) or 3 (TLC), so there are only 2 voltage states it needs to be able to measure, rather than 4 (MLC) or 8 (TLC). That means you lose some storage capacity (half vs MLC), but the tolerances for the voltage measured in each cell is significantly relaxed, so it remains usable long past the point where a plain MLC mode card would not be able to accurately program and measure the voltages that represent the 2-bit values of 00, 01, 10, or 11 anymore.

Re:A cheaper, smaller Raspberry Pi 3 is now available by StavrosK on Thursday November 15, 2018 @07:08PM (#18464816)
You should use something else for most of these, as the Raspi is hugely overkill. Something like an ESP8266 is much better suited for sensors and things like that, and it comes with onboard storage that it uses to run its code from.

Plus, it costs $3 each, is stamp-sized and has Wifi.

Re:A cheaper, smaller Raspberry Pi 3 is now available by mrsteveman1 on Thursday November 15, 2018 @07:57PM (#18465194)
The Pi boards actually replaced ESP32 boards running ESP-IDF firmware I wrote, I probably have 15+ of them at this point and still plan to use them for other things.

The ESP32s were routinely dropping from WiFi (some being crashes, some just disassociating and never connecting again). ESP-IDF has had quite a few WiFi fixes, but it's difficult to guarantee that your own code isn't directly causing the problem (which you get for free running in userland on Linux), and dealing with it was becoming a huge time sink.

Most of the Pi Zero W boards I have were $5 at Microcenter, the MicroSD adds to the cost a little but they're extremely reliable as a result, and my own code is no longer running in the same address space with the scheduler and WiFi driver under extremely tight memory constraints :)

Re:A cheaper, smaller Raspberry Pi 3 is now available by andyidsinga on Thursday November 15, 2018 @07:28PM (#18464974)
I use the ESP8266 and ESP32 for projects too - but the PI is sooo much easier to work with with a full linux distro and programming languages and libs to go with.

the ESPs are most definitely better for higher volume solutions

Re:A cheaper, smaller Raspberry Pi 3 is now available by StavrosK on Thursday November 15, 2018 @07:35PM (#18465037)
Hmm, you think so? I hate having to always keep Linux up to date. I prefer to just load micropython onto an ESP and be done. I use the Pi for heavier workloads, but that does mean it very rarely gets used.
Re:A cheaper, smaller Raspberry Pi 3 is now available by andyidsinga on Thursday November 15, 2018 @08:42PM (#18465501)
well trade offs ¯\_(ツ)_/¯

EDIT : now that you mention it - micropython is pretty cool -- and I haven't used it - need to try that on the ESP :)

Re:A cheaper, smaller Raspberry Pi 3 is now available by andyidsinga on Thursday November 15, 2018 @01:39PM (#18461962)
fwiw - as an addendum to that comment - I like using S3 to get my data off the zero w ASAP. ..then corrupt os etc doesn't cause too much down time and data loss.
Re:A cheaper, smaller Raspberry Pi 3 is now available by jws on Thursday November 15, 2018 @05:33PM (#18464107)
If you store your data under /run (or /var/run) your district will probably put it on a RAM disk. You’ll lose it in a crash, but you won’t be writing to the SD card and provoking it to corrupt in that crash.

If you then adjust your systemd journal to not write very often you have eliminated most of your SD writes.

The remote sensor systems I run lose power from time to time during the year, sometimes once a day. I’d say each time there used to be something like a 0.1% to 1% chance of corruption. Since I’ve moved to /run and a slower journal I haven’t lost an SD card[1]. Thus far it seems I have at least an order of magnitude improvement.

[1] Well, I had a wind turbine tower collapse in an inaccessible location. The raspberry pi is in a lake now, but it can’t have gone far so I don’t call it “lost”. I’ll dive and recover it in the spring. That camera/sensor has spent a couple months underwater before. In fact, I’ve had three systems end up underwater for months and all the SD cards have been fine when recovered.

Re:A cheaper, smaller Raspberry Pi 3 is now available by ageofwant on Thursday November 15, 2018 @05:42PM (#18464164)
Mate, seems you have your data recovery issues licked. Perhaps now is the time to spend some time on the structural integrity of your windmills :-)
Re:A cheaper, smaller Raspberry Pi 3 is now available by mrsteveman1 on Thursday November 15, 2018 @08:10PM (#18465271)
> If you store your data under /run (or /var/run) your district will probably put it on a RAM disk. You’ll lose it in a crash, but you won’t be writing to the SD card and provoking it to corrupt in that crash.

> If you then adjust your systemd journal to not write very often you have eliminated most of your SD writes.

The trouble is that the OS isn't the only one writing to flash in the card, the MicroSD card controller is erasing and writing to it at random times as well even if the filesystem is read-only, with no coordination between it and the OS.

As a result you can easily end up in situations where the card decided to run some housekeeping to manage the flash just milliseconds before a power cycle or a power loss, and seemingly all consumer MicroSD cards are not up to the task of keeping the data intact at the same time.