Auto-Remediation: automatic correction of common issues

Night outages wake the team, and investigating recurring incidents eats up time. We set up auto-remediation turnkey: the system restarts services, clears locks, and rolls back changes on its own. Response time to typical problems is reduced severalfold.

Our competencies:

Frequently Asked Questions

Latest works

  • Development of a web application for FEEDME
    Development of a web application for FEEDME
    1365
  • Development of an online store for the company FURNORO
    Development of an online store for the company FURNORO
    1330
  • B2B Advance company logo design
    B2B Advance company logo design
    776
  • Development of a web application for Enviok
    Development of a web application for Enviok
    1077
  • AIDER company logo development
    AIDER company logo development
    1022
  • CRM development for Chasseurs
    CRM development for Chasseurs
    1113

Auto-remediation: where manual response breaks down

An overnight failure alert goes to the on-call engineer, and then the most expensive part begins: they open the dashboard, read logs, check notes from the previous shift, and only then decide what to do.

While this analysis is underway, the service is already unavailable, some requests are lost, and load shifts to neighboring nodes.

In this scheme, the on-call engineer's response time is measured in tens of minutes, and almost all of it goes not to fixing the issue but to recognizing the situation.

The second problem is quieter and therefore more costly — recurring failures. A disk fills up, a container drops out, a message queue stalls, a database connection pool is exhausted — the shift resolves each of these situations anew from memory.

One on-call engineer restarts the service, another frees up space on the node, a third waits for it to resolve itself.

Shift actions diverge: the same failure is closed in different ways, the resulting environment differs, and the incident returns — already with a different diagnosis and a new history in chat.

Manual incident response also scales poorly in terms of people. The more services and nodes there are, the more on-call engineers need to be kept in rotation, and the longer each new engineer takes to become independent.

Night shifts, where load is low but wakefulness is mandatory, are the clearest example: a person is essentially guarding the system instead of doing what truly requires an engineering decision.

The worst part is that most such failures have already been encountered by someone: it is known what signal precedes them and what action returns the system to normal.

But the knowledge lives in heads and notes, not in an executable form, so it does not trigger until the right person is nearby.

Next we look at how this is closed: which failures are safe to give to automation, by what signs it makes a decision, and where it must stop and call a human.

What automatic remediation of typical failures delivers

The effect of automatic failure remediation is measured by three numbers: the share of incidents closed without human involvement, service recovery time, and the number of on-call actions per shift.

They are measured before implementation and a month after — otherwise the talk about "it became more convenient" has nothing to rest on.

Typical failures — a crashed pod, a hung worker, a full disk, a lagging replica — account for the bulk of tickets. A rule-response to a specific signal restarts the process, initiates failover, or clears space and closes the incident in the monitoring system itself.

In mature automation, 70–90% of typical cases are handled this way, and the share grows as verified scenarios accumulate.

Service recovery time is reduced radically. The manual cycle "alert — console login — diagnostics — action" takes tens of minutes, while automation fits into seconds.

A new rule first runs in observation mode: it writes what it would do but does not touch the system, and switches to execution when its decisions match the engineers' actions.

Load on the on-call shift drops because of night firings. A whole class of failures goes away — those caused by a missed routine operation or on-call fatigue.

In Kubernetes, these are automatic probes and restarts: the service returns to service before the engineer has opened their laptop.

Shift attention shifts to non-typical failures, where a human still makes the decision.

Auto-remediation scenarios: from restart to rollback

Auto-remediation is not a single script but a set of rules: a signal (liveness check, growing error rate, stuck queue) is matched with a response, and the decision is made in seconds while the on-call engineer is still opening the dashboard.

The difference between scenarios is not in the tool but in the cost of a false positive — therefore the response should be chosen for the failure class, not "for maximum automation".

Response scenario When appropriate Limitations
Restart of a service instance Process hung, leak, degradation of one of several instances Does not help with a systemic cause: after restart the failure returns if the circuit breaker did not trip
Load redistribution and adding instances Traffic spike, queue lag, response time growth Useless when an external dependency degrades — scaling only increases pressure
Automatic release rollback Errors appeared immediately after rollout and correlate with the new version Requires backward compatibility of the data schema; rolling back code without rolling back the migration breaks the service worse
Cleanup of temporary resources Disk overflow, accumulation of artifacts and logs Risk of deleting needed data: the cleanup rule must rely on age and label, not on "everything unnecessary"
Alert only, without actions Rare, unstudied, or data-touching failures Recovery time is limited by human reaction speed

Protection against automation loops is built on three limiters: an attempt limit per incident, an observation window before a repeated response, and a prohibition on action until the previous one has completed.

Exhausting the limit is not a failure but a normal transition to on-call escalation. The boundaries of automation lie where the cost of an error is higher than the cost of downtime: data operations, irreversible migrations, and manual approvals remain with a human.

How implementation of automatic remediation proceeds

Implementation of auto-remediation starts not with scripts but with an analysis of what is already breaking.

We reconstruct the picture from metrics and logs: which failures recur, how they manifest under different conditions, and how much time the on-call engineer spends on manual actions.

Then the work order is fixed — this shows which scenarios are safe to give to automation and where a stop for a human decision is needed.

  1. Incident audit. We analyze failure history over several months and group it by signs and causes. The output is a list of failure classes sorted by frequency and cost of downtime.
  2. Response scheme. For each class, we define a trigger sign, a permissible action (restart, load shedding, configuration rollback), and the boundaries beyond which automation stays silent and raises the on-call engineer.
  3. Scenario configuration. We define thresholds, the triggering window, the number of retries, and the rate limit — so that the same problem does not cause an avalanche of actions.
  4. Scenario validation on training failures. We simulate failures in an isolated environment: automation must do exactly what is intended, not fight itself during a cascade, and correctly give up if remediation did not help.
  5. Operations procedure. We describe how to add a new scenario, how to disable automation with one command, and who is authorized to change thresholds.
  6. Handover to operations. For the first weeks, we support the shift: we measure the share of incidents closed without a human and adjust thresholds based on actual results.

Handover package: diagrams, rules, and procedures

Documentation is handed over not as a folder of files but as a working loop: from it, the on-call engineer restores the service without calling the author of the auto-remediation rule.

Each item below is verified at acceptance — if the rule cannot be read, disabled, and rolled back without its creator, it is not accepted.

  • Service map — owners, dependencies, critical paths, and acceptable degradation for each service.
  • Trigger rules — metric, threshold, observation window, number of repeated actions, and stop condition; separately, a list of situations where automation stays silent and hands over to the engineer.
  • Access policies and roles — under which account automation runs, what it changes itself, what only with human confirmation, and how rights are granted and revoked.
  • Change rollback procedure — how to disable a specific rule, return the configuration to the previous one, and verify that the service has not remained in an intermediate state.
  • On-call shift procedure — responsibility zones, response time, escalation procedure, and actions on a false positive.
  • Documentation package — diagrams, descriptions, and instructions are stored next to the configuration and edited by the same change as the rule itself.
  • Automation action log — what and when changed, by which signal, and who confirmed; on its basis the incident is analyzed and thresholds are refined.

Case study: eliminated recurring night incidents

The on-call engineer woke three to four times per night, and each time it was the same set of failures: a hung background job, exhausted log space, a dropped volume, an expired certificate.

Each case was closed manually by the same instruction — connect, check the state, restart, wait for metrics to normalize. Triage took 40–60 minutes, of which useful work was about three minutes, and the rest was context switching and checks.

In total, this gave 12–16 night failures per week and about 20 hours of routine instead of infrastructure development.

What changed

We collected trigger statistics over several weeks and identified four classes that were closed by a strictly deterministic algorithm.

For each, we described a scenario: launch condition, set of checks, action, and mandatory confirmation that the service returned to a working state.

In a cluster managed by Kubernetes, the scenarios first ran in report mode — reporting what they would do — and only after a week of complete matches with manual actions were they allowed to act themselves. Everything that did not fall into these four classes remained with a human.

What resulted

Nine out of ten night failures are closed without human involvement. Service recovery takes about two minutes instead of 45, and on-call wake-ups are one every two weeks instead of three to four per night.

Every automatic action goes into the log together with its cause and result: incident analysis takes minutes, and scenario rollback is one switch.

How does automatic remediation differ from alerts?

An alert is a signal, not an action. The on-call engineer receives a notification, opens panels, reads logs, and searches for the relevant procedure — and all this time the service remains in failure.

Between "the system learned about the problem" and "the problem is resolved" lie manual steps, and their duration depends on whether the engineer woke up and remembers this specific failure.

The maturity levels of response differ in what the system takes on itself. The first is alerting: the machine only notices a deviation.

The second is a hint to the on-call engineer: context is attached to the signal — metrics over the window, recent changes, a link to the procedure — and the human proceeds straight to the decision.

The third is auto-action: the system performs one step of the procedure itself, restarts the container, removes a stuck lock, clears the queue, and reports the result.

Alertmanager clearly shows the boundary of these levels: it groups, silences, and routes signals, but remediation remains with whoever connected the automation.

Auto-remediation begins where a typical failure has an unambiguous triggering criterion, a reversible action, and a result check — otherwise automation replicates the error faster than the on-call engineer can notice it.

Alerting removes blindness but not response time; a hint saves 5-15 minutes on diagnostics; auto-action removes the incident itself for a whole class of typical failures.

There is no need to go further when a failure is rare, irreversible, or requires a decision with consequences for data: there automation only masks the problem.

Escalation closes the loop — if auto-action did not finish within the allotted window or triggered repeatedly, the incident goes to a human together with the history of attempts and the collected context.

Common technical doubts before implementation

Automatic remediation is enabled not out of belief in magic, but because manually analyzing a typical failure takes the on-call engineer more time than the failure itself.

Doubts at the assessment stage are usually the same: what rights to give the system, how to cut off false positives, and how deeply services will need to be modified. Below are answers to what engineers ask most often.

What rights will the system get to make changes?

A separate account with the minimum necessary set of rights and actions only within the boundaries of the target environment. Each operation is time-limited and goes into the audit log, and critical steps are performed after human confirmation.

The rule applies: the system does not change what it cannot revert — the rollback scenario is prepared in advance.

What happens on false positives?

A trigger is not a single event but a condition sustained in the observation window, plus a deviation threshold from the baseline. An action limit is set for the interval: after that, intervention stops and the task goes to the on-call engineer.

Before enabling, scenarios are run on historical data — this shows the share of false reactions before production launch.

Is this compatible with current monitoring and on-call?

The system subscribes to existing alerts and does not replace them. The on-call engineer sees in the familiar channel what exactly was attempted and with what result; if the action did not help, escalation comes with context, not an empty notification. Enablement proceeds gradually, by failure types — from safe to those requiring caution.

How deeply will services need to be modified?

A significant portion of failures — disk overflow, hung process, lost connection to the queue — are closed at the infrastructure level without code changes. The service needs a state check point and repeatability of operations so the action can be safely repeated. The scope of modifications is assessed for each service separately, before work begins.

Let's discuss your task and come back with a plan

To come back with an estimate and work plan, not general wording, we need a short set of inputs. Gather what you have at hand — we will clarify the rest in conversation.

  • Recurring failures over recent months: what exactly fails, how often, and how much time manual intervention takes.
  • How you currently learn about the problem: monitoring systems, alert channels, on-call schedule.
  • Actions the on-call engineer performs per instruction: service restart, disk space cleanup, release rollback — we translate them into automatic scenarios first.
  • Environment map: where development, where the test bench, where production, and how they differ in access rights.
  • Automation boundaries: for which failures remediation proceeds without confirmation, and where on-call approval is needed.
  • Constraints: internal procedures, maintenance windows, requirements for the action log and history retention.
  • Who on your side approves changes and accepts the result.

Then the order is: discuss the inputs, compare them with the observed picture from logs and metrics, agree on automation boundaries — and after that we send a work plan with stages, timelines, and points where you make the decision.

Start is possible with one environment: first scenarios that remove the most frequent manual operation, then expansion to the others. Describe the task — we will come back with an estimate and plan.