TIP: Click on subject to list as thread! ANSI
echo: rberrypi
to: FPM@U.WASHINGTON.EDU
from: GORDON HENDERSON
date: 2017-04-16 19:42:00
subject: Re: Shutdown time for RPi

In article ,
Frank Miles   wrote:
>On Fri, 14 Apr 2017 19:25:11 +0100, Ahem A Rivet's Shot wrote:
>
>> On Fri, 14 Apr 2017 16:30:48 -0000 (UTC)
>> Frank Miles  wrote:
>>
>>> I have an embedded application for the RPi-3.  Unfortunately it's likely
>>> that uses will remove power without properly shutting the RPi down.
>>> Therefore I've got a 'power-going-down' bit of hardware which sets a GPIO
>>> bit causing a proper shutdown.  The question, of course, is how long does
>>> a shutdown take?
>>
>>  It depends - mostly on how fast the SD card is, how many dirty
>> buffers need to be flushed and how long processes take to die. Best bet is
>> to measure it under your worst case loads with the card you intend to use
>> and add a healthy safety factor.
>
>Ok, reframing :
>  What's the easiest way to detect when shutdown is complete?

Some boards use the serial Tx line. This is set low when shutdown is complete.


Other strategies are to minimise SD card writes during normal use, but we
don't know what the application is.. However stuff I do is things like
remove logging (like rsyslogd - no idea how to stop systemd writing to
SD card, I don't use it), mounting /tmp/ as ramdisk (see /etc/defaults/shm )
and generally tuning application to minimise writes, if possible.

Gordon

--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)

SOURCE: echomail via QWK@docsplace.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.