Investigate RPi hardware watchdog for autonomous reboot
メンテナーはふだん 2 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 35/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 静か
- 技術スタック
- ansible, linux, python, raspberry-pi
調査の方向性
Raspberry Pi の /dev/watchdog にある watchdog インターフェースと /boot/config.txt の dtparam 設定から始め、続いてメインの Python スクリプトと Ansible のデプロイ/更新タスクを調べます。システムレベルまたはアプリケーションレベルの監視で十分かどうかを文書化し、ヘルスチェックとタイムアウトを選定し、正常なシャットダウンと更新処理を定義できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
This issue is part of the epic pyronear/roadmap#16 (Engine robustness).
Context
Pyronear stations run in the field, in quite remote areas. When a station freezes/bug (kernel panic, deadlock, full crash), the current recovery relies on a physical power cut, which risks filesystem corruption and requires human intervention or usually hardware timer relay.
The RPi has a built-in hardware watchdog (/dev/watchdog) that can trigger a clean software reboot automatically if the system stops responding ! no relay, no power cut.
How it works
The watchdog runs a hardware timer. Any process must periodically write to /dev/watchdog to reset it ("petting the dog"). If nothing writes for N seconds → the chip triggers a reboot.
It's deliberately dumb: it doesn't know why nothing wrote — freeze, crash, deadlock — it just reboots.
Two approaches to explore
1. System-level only (watchdog daemon)
- Activate via
dtparam=watchdog=onin/boot/config.txt - Let the
watchdogLinux daemon handle the petting - ✅ Simple, no code change
- ⚠️ Only covers full OS/kernel freeze — won't catch a live-but-broken capture pipeline
2. Application-level (from the main Python script)
- Pet the watchdog only when the system is actually healthy (camera alive, recent frame, model responding)
- If a check fails → stop petting → reboot triggered after timeout
- ✅ Covers applicative failures too
- ⚠️ Slightly more complexity, watchdog thread must be robust itself
Questions to answer
- Does approach 1 alone cover enough failure modes for our use case? Might be relevant to start from that
- What health checks are meaningful to gate the pet on (approach 2)?
- What's the right timeout value (balance between false reboot vs slow recovery)? -> 10 ? 30 min ?
- Impact on clean shutdown or an long update need to write magic char
Vto/dev/watchdogbefore closing -> Since deployments/updates are managed via Ansible, a natural solution is to add explicit steps around the update tasks (Disable watchdog before update and Re-enable watchdog after update)
- 主要言語
- Python
- スター
- 20
- フォーク
- 9
- 平均マージ
- 8日 19時間
- マージ済み PR(30日)
- 8
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
pyronear/pyro-engine のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100
pyronear/pyro-engine#368 ·
メンテナーはふだん 2 日以内に返信
-
topic: documentation
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
pyronear/pyro-engine#455 ·
メンテナーはふだん 2 日以内に返信
-
type: new feature
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
pyronear/pyro-engine#454 ·
メンテナーはふだん 2 日以内に返信
-
type: new feature
難易度 5/5 1週間以上 初心者へのやさしさ 28/100
pyronear/pyro-engine#453 ·
メンテナーはふだん 2 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 57/100
pyronear/pyro-engine#452 ·
メンテナーはふだん 2 日以内に返信
pyronear/pyro-engine の issue をすべて見る
似ている issue
-
Project submission:オープン
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
slavakurilyak/awesome-ai-agents#845 ·
メンテナーはふだん 1 日以内に返信
-
tests: pin that the atomic writers in utils/paths.py stage the temporary file in the target's directory対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンdifficulty:2 enhancement good first issue
難易度 1/5 1〜3時間 初心者へのやさしさ 92/100
MakazhanAlpamys/Soup#2178 ·
メンテナーはふだん 1 日以内に返信
-
[BUG] dcg.waggr permutation p-values are folded twice, so near-zero scores get the smallest p-valuesオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
scverse/rapids-singlecell#854 ·
メンテナーはふだん 1 日以内に返信
-
Slang input: int8_t4_packed and uint8_t4_packed are copied into CrossGL対応中かも @ninglinLiu が今日担当しました。 オープンarea:frontend backend:slang bug direction:input
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
メンテナーはふだん 1 日以内に返信
-
random_elements(unique=True) on an OrderedDict: ZeroDivisionError once only zero weights remain, AssertionError with use_weighting=False対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
メンテナーはふだん 13 日以内に返信