Dashboard
Fault Injection

Process Killer Experiment

The Process Killer experiment kills targeted processes over a supplied interval throughout the length of the experiment.

When targeting processes with the <span class="code-class-custom">--process argument</span>, you can pass a regular expression, which matches processes in the same way that pgrep(1) does, or you can pass a specific Process ID (PID). When passing a regular expression, Gremlin will only match on the process name (<span class="code-class-custom">arg0</span>) unless <span class="code-class-custom">--full</span> is also supplied.

Terminating PID 1

PID 1 is most commonly reserved for the init process. On hosts, Process Killer does not work for PID 1. Instead, you should use a Shutdown experiment. On container-based systems (e.g. Kubernetes), you can terminate PID 1, which has the same effect as running a Shutdown experiment.

The only exception is if you want to repeatedly terminate a container process, which is only possible with Process Killer. In that case, you would need to run Process Killer on the container host, ensure that the Gremlin agent is deployed with <span class="code-class-custom">hostPID</span> set to <span class="code-class-custom">true</span>, and select the container process from the host.

Linux

The Process Killer experiment sends the signal supplied by <span class="code-class-custom">--signal</span> (defaults to <span class="code-class-custom">KILL</span>) to processes identified by the rest of the supplied arguments.

This experiment requires the <span class="code-class-custom">KILL</span> capability, which is enabled by default at installation time. See capabilities(7)

Options

ParameterFlagRequiredDefaultVersionDescription
Signal-s stringFalseKILL1.8.0The signal to send to target processes. Values: [HUP,INT,QUIT,ILL,TRAP,ABRT,FPE,KILL,SEGV,PIPE,ALRM,TERM,USR1,USR2]
Interval-i intFalse11.8.0The number of seconds to delay before kills.
Process-p reg ex or intTrue1.8.0The process name to match (allows regex) or the process ID.
Group-g stringFalse1.8.0The group name or ID to match against (name matches only).
User-u stringFalse1.8.0The user name or ID to match against (name matches only).
Newest-nFalseFalse1.8.0If set the newest matching process will be killed (name matches only, cannot be used with -o).
Oldest-oFalseFalse1.8.0If set the oldest matching process will be killed (name matches only, cannot be used with -n).
Exact-eFalseFalse1.8.0If set the match must be exact and not just a substring match (name matches only).
Kill Children-cFalseFalse1.8.0If set the processes children will also be killed.
Full Match-fFalseFalse1.8.0If set the processes name match will occur against the full command line string that the process was launched with.
Length-l intFalse601.8.0The length of the experiment (seconds).
No items found.
Previous
This is some text inside of a div block.
Compatibility
Installing the Gremlin Agent
Authenticating the Gremlin Agent
Configuring the Gremlin Agent
Managing the Gremlin Agent
User Management
Integrations
Health Checks
Notifications
Command Line Interface
Updating Gremlin
Quick Start Guide
Services and Dependencies
Detected Risks
Reliability Tests
Reliability Score
Targets
Experiments
Scenarios
GameDays
Overview
Deploying Failure Flags on AWS Lambda
Deploying Failure Flags on AWS ECS
Deploying Failure Flags on Kubernetes
Classes, methods, & attributes
API Keys
Examples
Container security
General
Linux
Windows
Chao
Helm
Glossary
Alfi
Additional Configuration for Helm
Amazon CloudWatch Health Check
AppDynamics Health Check
Application Level Fault Injection (ALFI)
Blackhole Experiment
CPU Experiment
Certificate Expiry
Custom Health Check
Custom Load Generator
DNS Experiment
Datadog Health Check
Disk Experiment
Dynatrace Health Check
Grafana Cloud Health Check
Grafana Cloud K6
IO Experiment
Install Gremlin on Kubernetes manually
Install Gremlin on OpenShift 4
Installing Gremlin on AWS - Configuring your VPC
Installing Gremlin on Kubernetes with Helm
Installing Gremlin on Windows
Installing Gremlin on a virtual machine
Installing the Failure Flags SDK
Jira
Latency Experiment
Memory Experiment
Network Tags
New Relic Health Check
Overview
Overview
Overview
Overview
Overview
Packet Loss Attack
PagerDuty Health Check
Preview: Gremlin in Kubernetes Restricted Networks
Private Network Integration Agent
Process Collection
Process Killer Experiment
Prometheus Health Check
Role Based Access Control
Running Failure Flags experiments
Scheduling Scenarios
Shared Scenarios
Shutdown Experiment
Slack
Teams
Time Travel Experiment
Troubleshooting Gremlin on OpenShift
User Authentication via SAML and Okta
Users
Webhooks
Integration Agent for Linux
Test Suites
Restricting Testing Times
Reports
Process Exhaustion Experiment
Enabling DNS collection