@@ -18,14 +18,11 @@ Two states give a resume, and their cost is not the same:
1818| Paused | On the node VM, and the resume prefers that node | Low. No download. |
1919| Suspended | In object storage (GCS or S3) | High. A download and an unpack. |
2020
21- ` ate.snapshot.kind ` tells you which snapshot the resume read:
22-
23- | Value | Meaning |
24- | ---| ---|
25- | ` local ` | A snapshot on the node. A pause wrote it. |
26- | ` latest ` | The durable snapshot of the actor. |
27- | ` golden ` | The image of the ActorTemplate. This is the first activation of a new actor. |
28- | ` boot ` | A start from nothing. A boot is not a restore, thus this value never occurs on the atelet histograms. |
21+ ` ate.snapshot.kind ` tells you which snapshot the resume read. The permitted
22+ values and their meaning are in the ` registry.ate.snapshot ` group of
23+ [ the registry] ( ../metrics/registry/metrics.yaml ) . One of them changes what you
24+ can query: a ` boot ` is a start from nothing, thus it is not a restore and the
25+ atelet restore histogram has no data for it.
2926
3027Two instruments measure a resume. They do not measure the same part:
3128
4441
4542Each step gives the query in two forms. Refer to
4643[ the naming rules] ( README.md#the-names-on-your-backend ) for which form your
47- backend needs, and for the three reasons a query can return nothing.
44+ backend needs, and for the reasons a query can return nothing.
4845
4946---
5047
@@ -81,11 +78,11 @@ histogram_quantile(0.95, sum by(le) (
8178* The router number is much larger — the time went to the queue or to the
8279 scheduler. Go to step 5.
8380
84- ** A quantile at the last bucket is saturated.** The lifecycle histogram of
85- ateapi stops at 30 s. The restore histogram of atelet stops at 60 s. A value at
86- or near the end of the range means only that the true value is somewhere above
87- the buckets, thus the two instruments cannot be compared there. Read the mean
88- instead, as step 2 does.
81+ ** A quantile at the last bucket is saturated.** The two instruments do not use
82+ the same buckets, and the lifecycle histogram of ateapi ends before the restore
83+ histogram of atelet. A value at or near the end of either range means only that
84+ the true value is somewhere above the buckets, thus the two cannot be compared
85+ there. Read the mean instead, as step 2 does.
8986* The restore query is empty but resumes occur — the resumes are boots. Confirm
9087 it:
9188
@@ -148,14 +145,16 @@ sum by("ate.snapshot.phase") (
148145 increase({__name__="ate.actor.restore.duration_count","ate.failure.reason"=""}[30m]))
149146```
150147
151- | Phase | What is slow | Go to |
152- | ---| ---| ---|
153- | ` volume_mount ` | The volumes of the actor. | The logs of atelet. |
154- | ` manifest_fetch ` | The read of the snapshot manifest. | Step 3. |
155- | ` download ` | Object storage. | Step 3. |
156- | ` oci_unpack ` | The node, or the image cache missed. | Step 4. |
157- | ` sandbox_assets ` | The sandbox assets on the node. | Step 4. |
158- | ` ateom_restore ` | The sandbox runtime. | The logs of ateom. |
148+ The ` registry.ate.snapshot ` group of
149+ [ the registry] ( ../metrics/registry/metrics.yaml ) says what each phase covers.
150+ The slowest phase says where to go next:
151+
152+ | Phase | Go to |
153+ | ---| ---|
154+ | ` volume_mount ` | The logs of atelet. |
155+ | ` manifest_fetch ` , ` download ` | Step 3. |
156+ | ` oci_unpack ` , ` sandbox_assets ` | Step 4. |
157+ | ` ateom_restore ` | The logs of ateom. |
159158
160159If the filtered numbers are small but the unfiltered numbers are large, the
161160subject is not the speed of the phase. It is the failures. Go to step 6.
@@ -204,21 +203,32 @@ A miss adds a pull and an unpack to each resume.
204203``` promql
205204sum by (ate_imagecache_outcome) (
206205 rate(ate_imagecache_requests_total[5m]))
206+
207+ sum by (error_type) (
208+ rate(ate_imagecache_requests_total{
209+ ate_imagecache_outcome="error"}[5m]))
207210```
208211
209212** Cloud Monitoring / GMP**
210213
211214``` promql
212215sum by("ate.imagecache.outcome") (
213216 rate({__name__="ate.imagecache.requests"}[5m]))
217+
218+ sum by("error.type") (
219+ rate({__name__="ate.imagecache.requests",
220+ "ate.imagecache.outcome"="error"}[5m]))
214221```
215222
216- Calculate the hit ratio as ` hit / (hit + miss) ` . Keep ` error ` , ` cancelled ` and
217- ` timeout ` out of the denominator.
223+ Calculate the hit ratio as ` hit / (hit + miss) ` . Keep the outcomes that are not
224+ a lookup result out of the denominator. The
225+ ` registry.ate.imagecache ` group of
226+ [ the registry] ( ../metrics/registry/metrics.yaml ) lists them.
218227
219- If the outcome is ` error ` , ` error.type ` holds the HTTP status of the registry.
220- The value ` 401 ` or ` 403 ` is a credential fault. The value ` 429 ` is a rate
221- limit. Each other status reports ` _OTHER ` .
228+ Only the ` error ` outcome carries ` error.type ` , which holds the HTTP status that
229+ the registry of the image returned. Group by it to divide a credential fault
230+ from a rate limit from a fault of the registry. The permitted values are on
231+ ` metric.ate.imagecache.requests ` in the same file.
222232
223233## Step 5. Examine the control plane
224234
@@ -290,18 +300,18 @@ sum by("ate.snapshot.phase", "ate.failure.reason") (
290300 "ate.failure.reason"!=""}[5m]))
291301```
292302
293- | Reason | Cause |
303+ The ` registry.ate.failure ` group of
304+ [ the registry] ( ../metrics/registry/metrics.yaml ) says what each reason means.
305+ The reason says which component to examine next:
306+
307+ | Reason | Examine |
294308| ---| ---|
295- | ` FAILED_GET_EXTERNAL_OBJECT ` | The storage backend has a fault. |
296- | ` TERMINAL_FILE_SYSTEM_ERROR ` | A permanent fault on the node. Usually the disks are full. |
297- | ` LOCAL_SNAPSHOT_GONE ` | The node no longer has the local snapshot. |
298- | ` INVALID_SANDBOX_ASSET ` | A sandbox asset is absent or bad. |
299- | ` INVALID_CHECKPOINT_RESULT ` | ateom returned a checkpoint that is not valid. |
300- | ` INVALID_CONTAINER_CONFIG ` | The ActorTemplate is not correct. |
301- | ` INVALID_OBJECT_URL ` | The URL of the snapshot object is bad. |
302- | ` FAILED_SAVE_SNAPSHOT ` | atelet could not write the snapshot. |
303- | ` WORKER_POD_GONE ` , ` WORKER_REASSIGNED ` , ` CORRUPTED_ASSIGNMENT ` | A control plane fault. Examine ateapi. |
304- | ` UNKNOWN ` | An infrastructure failure with no reason. Read the logs of atelet. |
309+ | ` FAILED_GET_EXTERNAL_OBJECT ` , ` INVALID_OBJECT_URL ` | The storage backend, and the URL of the snapshot object. |
310+ | ` TERMINAL_FILE_SYSTEM_ERROR ` , ` LOCAL_SNAPSHOT_GONE ` , ` INVALID_SANDBOX_ASSET ` | The node. Read the logs of atelet. |
311+ | ` INVALID_CHECKPOINT_RESULT ` , ` FAILED_SAVE_SNAPSHOT ` | The suspend path. A bad checkpoint makes the next resume fail. |
312+ | ` INVALID_CONTAINER_CONFIG ` | The ActorTemplate. |
313+ | ` WORKER_POD_GONE ` , ` WORKER_REASSIGNED ` , ` CORRUPTED_ASSIGNMENT ` | The control plane. Examine ateapi. |
314+ | ` UNKNOWN ` | Nothing else. The reason is absent, thus read the logs of atelet. |
305315
306316A slow resume and a failed suspend are related. A suspend that fails leaves no
307317good snapshot for the next resume. Read the crash counter, which uses the same
0 commit comments