You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
--destination value, --dest value destination IP filter; supports multiple IPs; supports CIDR notation
469
474
--src-port value, --sport value source port filter; supports multiple ports (comma-separated)
470
475
--dst-port value, --dport value destination port filter; supports multiple ports (comma-separated)
471
-
--iptables-image value Docker image with iptables and tc tools (default: "ghcr.io/alexei-led/pumba/pumba-alpine-nettools:latest")
476
+
--iptables-image value Docker image with iptables and tc tools (default: "ghcr.io/alexei-led/pumba-alpine-nettools:latest")
472
477
--pull-image force pull iptables-image
473
478
--help, -h show help
474
479
```
@@ -493,7 +498,8 @@ OPTIONS:
493
498
494
499
#### Using the `iptables` Commands
495
500
496
-
Pumba's `iptables` command allows you to simulate packet loss for incoming network traffic, with powerful filtering options. This can be used to test application resilience to network issues.
501
+
Pumba's `iptables` command allows you to simulate packet loss for incoming network traffic, with powerful filtering options. This can be
502
+
used to test application resilience to network issues.
497
503
498
504
##### Examples
499
505
@@ -525,34 +531,36 @@ You have two options:
525
531
526
532
1. Make sure the target container has the `iptables` tool installed
527
533
(install the `iptables` package)
528
-
534
+
529
535
2. Use the `--iptables-image` option to specify a Docker image with
530
536
the `iptables` tool.
531
-
537
+
532
538
Pumba will create a helper container from this image with `NET_ADMIN`
533
539
capability and reuse the target container's network stack.
Both images support multiple architectures (amd64, arm64).
540
546
541
547
### Advanced Network Chaos Scenarios
542
548
543
-
Pumba allows you to create complex and realistic network chaos scenarios by combining multiple network manipulation commands. This is particularly useful for simulating real-world network conditions where multiple issues might occur simultaneously.
549
+
Pumba allows you to create complex and realistic network chaos scenarios by combining multiple network manipulation commands. This is
550
+
particularly useful for simulating real-world network conditions where multiple issues might occur simultaneously.
544
551
545
552
#### Asymmetric Network Conditions
546
553
547
-
In real networks, upload and download speeds/quality often differ. You can simulate this using a combination of `netem` for outgoing traffic and `iptables` for incoming traffic:
554
+
In real networks, upload and download speeds/quality often differ. You can simulate this using a combination of `netem` for outgoing traffic
--source service-c-ip --duration 5m loss --probability 0.2 service-b &
585
593
```
586
594
587
595
#### Example Script
588
596
589
597
You can find a complete example script for combined chaos testing in the [examples directory](examples/pumba_combined.sh).
590
598
591
-
For detailed guidance on advanced network chaos testing scenarios, best practices, and troubleshooting, see the [Advanced Network Chaos Testing Documentation](docs/advanced-network-chaos.md).
599
+
For detailed guidance on advanced network chaos testing scenarios, best practices, and troubleshooting, see
600
+
the [Advanced Network Chaos Testing Documentation](docs/advanced-network-chaos.md).
Copy file name to clipboardExpand all lines: docs/advanced-network-chaos.md
+40-37
Original file line number
Diff line number
Diff line change
@@ -4,20 +4,23 @@ This guide provides detailed instructions for creating advanced network chaos te
4
4
5
5
## Overview
6
6
7
-
Pumba now offers support for both outgoing traffic manipulation (using `tc` with `netem`) and incoming traffic manipulation (using `iptables`). By combining these tools, you can create more realistic and complex network chaos scenarios.
7
+
Pumba now offers support for both outgoing traffic manipulation (using `tc` with `netem`) and incoming traffic manipulation (using
8
+
`iptables`). By combining these tools, you can create more realistic and complex network chaos scenarios.
The diagram above illustrates how Pumba uses a single nettools container to manipulate both incoming traffic (via iptables) and outgoing traffic (via tc/netem) for the target application container.
12
+
The diagram above illustrates how Pumba uses a single nettools container to manipulate both incoming traffic (via iptables) and outgoing
13
+
traffic (via tc/netem) for the target application container.
12
14
13
15
## Nettools Images
14
16
15
17
Pumba uses multi-architecture container images that include both `tc` and `iptables` tools:
0 commit comments