Dashboard
Platform

Command Line Interface

Gremlin Command line interface allows the user to perform commands directly from the host. The impact of the attack will be localized to that host.

Commands

Attacks

Important
Attacks are now called Experiments. The commands will remain the same.

The <span class="code-class-custom">attack</span> command starts a localized Gremlin experiment. Please visit experiments for all experiments and parameters.

BASH

# Example of a CPU attack
gremlin attack cpu -l 60 -c 1
Setting up cpu gremlin with guid 'd626a85b-6303-11e9-bdf9-4029fe350366' for 60 seconds on 1 core
Setup successfully completed
Running cpu gremlin with guid 'd626a85b-6303-11e9-bdf9-4029fe350366' for 60 seconds on 1 core
Attack on cpu_1 completed successfully


Attack-container

The <span class="code-class-custom">attack-container</span> command starts an experiment against a locally-hosted Docker container. Please visit experiments for all experiments and parameters.

In order to run <span class="code-class-custom">attack-container</span>, the container must reside on the host and must be specified.

BASH

# Example of a Container experiment
gremlin attack-container a1a9ee7eb256 -l 60 -c 1

Check

The <span class="code-class-custom">check</span> command inspects the state of your Gremlin installation. The currently-supported set of checks is: <span class="code-class-custom">api</span>, <span class="code-class-custom">auth</span>, <span class="code-class-custom">docker</span>, <span class="code-class-custom">env</span>, <span class="code-class-custom">files</span>, <span class="code-class-custom">os</span>, <span class="code-class-custom">proxy</span>, <span class="code-class-custom">tags</span>, <span class="code-class-custom">version</span>.

You may run an individual check by passing it as an argument to the <span class="code-class-custom">check</span> command. For example, <span class="code-class-custom">gremlin check proxy</span>. If you leave this off (<span class="code-class-custom">gremlin check</span>), then all checks will be run.

This output is not sent to Gremlin, but it may be helpful to contact Gremlin Support to triage an installation issue.

BASH

# Example of running "gremlin check os":
gremlin check os

os
====================================================
OS Name                              : Ubuntu
OS Version                           : 16.04
System Time                          : 1569450673 (2019-09-25 22:31:13)
NTP Time                             : 1569450673 (2019-09-25 22:31:13)

Help

The <span class="code-class-custom">help</span> command list all of the available commands and displays help.

Init

The init commands sets up the agent configuration. A prompt will appear to request a <span class="code-class-custom">Team ID</span> and <span class="code-class-custom">Team Secret</span>.

BASH

# Registers agent to control plane using specified Team ID and Team Secret. Gremlind will restart after completion
gremlin init
Please input your Team ID:
9676868b-60d2-5ebe-aa66-b8b3cef23bb9
Please input your Team Secret:

Using 9676868b-60d2-5ebe-aa66-b8b3cef23bb9 for Organization Id
Using 172.31.0.108 for identifier

Please see the table below for optional parameters.

ParameterFlagDescription
Service-s stringThe service the client belongs to.
Region-r stringThe region the client is in.
Zone-z stringThe zone the client is in.
Public IP-i IP AddressThe public IP Address for the client.
Hostname-h hostnameThe public hostname for the client.
Tags-t stringA tag to apply to the client for identification and description purposes (see also GREMLIN_CLIENT_TAGS in Advanced Configuration.)

Logout

The <span class="code-class-custom">logout</span> command removes this Gremlin Agent from the Gremlin Control Plane.

Rollback

The <span class="code-class-custom">rollback</span> command interrupts an active experiment. It can also revert the last impact.

BASH

gremlin rollback
Rolling back f1c1e96c-630e-11e9-92d3-ad4cfee292e2
Rollback running in PID 28383, attack running in PID 28155, rollback issuing a kill to attack process, which will roll itself back
Reverted 1 attack

Rollback-container

The <span class="code-class-custom">rollback-container</span> command interrupts an active experiment against a local Docker container.

Status

The <span class="code-class-custom">status</span> command will display the status of any experiments.

BASH

# Example of gremlin status
gremlin status
        ARGS                 START                END                  GUID
↻       cpu -l 300 -c 1      2019-04-20 01:52:24                       f1c1e96c-630e-11e9-92d3-ad4cfee292e2

To display a specific attack use <span class="code-class-custom">-u</span> followed by the <span class="code-class-custom">GUID</span>.

BASH

# Example of status of a specific GUID
gremlin status -u 601e52e7-630f-11e9-bdf9-4029fe350366
601e52e7-630f-11e9-bdf9-4029fe350366 - Successful

Start Time              End Time
2019-04-20 01:55:29     2019-04-20 02:00:30

Args
cpu -l 300 -c 1

Version

The <span class="code-class-custom">version</span> command will state the installed version of Gremlin.

BASH

gremlin version
gremlin version 2.10.0


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