Simulate Stress Scenarios
You can create experiments using either Chaos Dashboard or the YAML configuration files.
Open Chaos Dashboard, and click NEW EXPERIMENT on the page to create a new experiment:
Fill out the experiment information, and specify the experiment scope and the scheduled experiment duration:
Write the experiment configuration to the YAML configuration file. In the following example, the file is used.
This experiment configuration will create a process in the selected container, continuously allocate and read and write in memory, occupying up to 256MB of memory.
After the configuration file is prepared, use
kubectl
to create an experiment:
Stressors
MemoryStressor
note
To avoid the high CPU load caused by the read and write pressure from stress-ng
, Chaos Mesh uses to simulate memory stress. This is because memStress simulates memory stress by consuming actual memory instead of applying the read and write pressure to memory.