Merge pull request #751 from seaweedfs/docs/troubleshooting-head-log

docs(troubleshooting): reading the HEAD write log lines
This commit is contained in:
Ping Qiu authored and GitHub committed 2026-11-29 02:05:39 -08:00
commit 8e131ca2b0
1 file changed
+20
+20
View File
@@ -167,3 +167,23 @@ difference plus half the round trip reaches half of the shell's `-max-clock-skew
on each volume host.
**Fix:** [clock safety requirement](operator-guide.md#clock-safety-requirement).
## Reading HEAD write logs
Every HEAD write that the filer acknowledges is logged by the process that made it: blockvolume for a holder's writes, blockmaster for a volume's create, restore and delete. One line per write:
```text
layout: HEAD write level=INFO volume="v1" volume_id=<id> gen=12->13 head_write=commit session="<session>" epoch=3 holder="s1" claim="<claim>" activity=idle state=live current="<root>" position=4096 snapshots=2 dependents=0 took_ms=1.234
```
- **`head_write`** says why HEAD was written. It is one of: `create`, `claim`, `start-rollback-snap`, `start-rollback-clean`, `session-begin`, `session-rollback`, `commit`, `snapshot-unchanged`, `stop-abort`, `clean-begin`, `clean-end`, `snapshot-retire`, `snapshot-delete`, `dependent-add`, `delete-marking`, `delete-done`, `dependent-release`, `tombstone`.
- **`gen=A->B`** is HEAD's generation before and after the write.
- **`took_ms`** is the time the conditional write took.
A write whose answer was lost is logged at WARN, because it may or may not have applied:
```text
layout: HEAD write level=WARN outcome=unknown volume="v1" volume_id=<id> expected_gen=12 head_write=commit session="<session>" took_ms=2000.000 err="<error>"
```
The next attempt reads HEAD and settles it. A definite refusal by the filer (the generation moved, the HEAD exists or is missing) is not an unknown outcome and is not logged here. Several `outcome=unknown` lines in a row for one volume mean the filer is not answering HEAD writes: see [filer.single](#filersingle).