From owner-freebsd-embedded@freebsd.org Fri Sep 27 19:53:22 2019 Return-Path: Delivered-To: freebsd-embedded@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9450612B612 for ; Fri, 27 Sep 2019 19:53:22 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x729.google.com (mail-qk1-x729.google.com [IPv6:2607:f8b0:4864:20::729]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 46g2Xd4Rxpz4FSw for ; Fri, 27 Sep 2019 19:53:21 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x729.google.com with SMTP id u186so2961403qkc.5 for ; Fri, 27 Sep 2019 12:53:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=wasbeVCW2iasYPjmYRXN0+KqK28Wd3Je+P6pkrADSBc=; b=Z2FYAKWHXNUU2lFLjS/nI8Qt5w8/z+2P6ECCk/csQesd18noDQr/zOaDLDKgwzTDw4 Sy5KmnkT2+wNPNmHETCUaSdqMoijB1niqS+xqn8wZt9cyerRxp0Yyyqtea02I6DKYPLZ 8SJKU7oSOVYn6gGdwTJ63/MAHPJ7jCFU8Wtcz/fPq8EbLwDfe/zGqaQHz3vbF47e6WuL 29Hc7hqdE4R1BDUEgyDKJAKClPPRzd+CZIi3vVSjCvhPCXSSoE6E8sPV5qMv9Ae34aLo 5hrmn3zmwAzNdGC5k6S7YbySiyhCCf9SESyuWML6OVqTxIWxEx4q3/liRwVuiZmnHoK+ eBZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=wasbeVCW2iasYPjmYRXN0+KqK28Wd3Je+P6pkrADSBc=; b=MfWj9Gz//UH1brCKVOdtz/r887vb+MlYrOCiLL7abS9lJYv351L0KhOTRhTcyQd5jS IS/cnr9jP1gFGlrjqUqtWGQv6vDVQ5+oCrQo9xI9M1mk6HyrqTmc2HFIiA/FB+KJM1hH 2cAJZxYx5ajyQ7xYYjYA7izfLBigMMgr2y/puISyDuwaEvEI+IrxtGFpHYaJLSxIZA8j LCC9fIYOt95CHtx9qACGUhqBEygBeOxM5crNFCFh2SbjVOLLvfmkKghAANa/gF/9vZw/ mfEhxTtVfYC4pat86y2F4XRCwac+lYfDXg+KnZvTH3AdFZA8o9RM2o0oydDk2uGGhyS0 yUAg== X-Gm-Message-State: APjAAAWbsAAt5SE6SZ51GKv+XBiDqFNqOzpm78wsmQk8aDEURYCOCbi+ MFiszZ+gmhWdYlKLf/IgOvG/KxQBhj1nzwhVgQx4KA== X-Google-Smtp-Source: APXvYqzn7JYXsVoQGZ/h5FjwkMSB4L0Fi+QQs8vrmpg1R9LGouMvZG7sAl1o0GU529A7iZgIAg4zoQZeJaOHqdGHmQM= X-Received: by 2002:a37:7bc7:: with SMTP id w190mr6749314qkc.215.1569613999842; Fri, 27 Sep 2019 12:53:19 -0700 (PDT) MIME-Version: 1.0 References: <5eba25eb-9ba4-0c93-27c8-e834491298ad@sentex.net> <83831ae6-9275-4f0c-a23d-c9cca3dc28f4@sentex.net> In-Reply-To: <83831ae6-9275-4f0c-a23d-c9cca3dc28f4@sentex.net> From: Warner Losh Date: Fri, 27 Sep 2019 13:53:07 -0600 Message-ID: Subject: Re: watchdogd stat location To: Mike Tancsa Cc: Aleksandr Rybalko , freebsd-embedded X-Rspamd-Queue-Id: 46g2Xd4Rxpz4FSw X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=Z2FYAKWH; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::729) smtp.mailfrom=wlosh@bsdimp.com X-Spamd-Result: default: False [-3.82 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-embedded@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; URI_COUNT_ODD(1.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; RCVD_IN_DNSWL_NONE(0.00)[9.2.7.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; IP_SCORE(-2.82)[ip: (-9.27), ipnet: 2607:f8b0::/32(-2.59), asn: 15169(-2.17), country: US(-0.05)]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-embedded@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Dedicated and Embedded Systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Sep 2019 19:53:22 -0000 On Fri, Sep 27, 2019, 1:21 PM mike tancsa wrote: > On 9/27/2019 3:19 PM, Oleksandr Rybalko wrote: > > > > =D0=BF=D1=82, 27 =D0=B2=D0=B5=D1=80. 2019 =D0=BE 19:22 Warner Losh > > =D0=BF=D0=B8=D1=88=D0=B5: > > > > On Fri, Sep 27, 2019 at 9:36 AM mike tancsa > > wrote: > > > > > We sometimes run into an issue where our embedded devices that > > boot off > > > a read only SD card, hang with a controller error. Its not clear > if > > > this is a BIOS/firmware/SDCard or driver bug issue. Its pretty > > > infrequent, but annoying enough that I started to dig to see why > > the box > > > is not rebooting via the hardware watchdog. It seems to fail > > to reboot > > > the box as the stat that it does on the filesystem is off the md > > backed > > > /etc which is not impacted. I know I could run an external > > program, but > > > would it be safer to change the default directory where the stat > > is done > > > to something that is generally not mounted via ramdisk ? > > > > > > Why not just stat "/". > > > > I think embedded devices may have monolithic kernel w/o any loadable > > modules and book config. > > > I am all for that too. Just something other than /etc or /var which are > often mounted on ramdisk. > I think that / is too special to cause disk IO to ever happen. Other dirs will sometimes not be in the cache.... The notion here, perhaps bogus, is that we want to check the root FS is sane. The stat(2) is a cheap way to do this that will eventually fail if / goes wonky enough. It's weak. Warner ---Mike > > _______________________________________________ > freebsd-embedded@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-embedded > To unsubscribe, send any mail to "freebsd-embedded-unsubscribe@freebsd.or= g > " >