Skip to content

Commit

Permalink
Correct scratch guide re: bridge and iptables
Browse files Browse the repository at this point in the history
Replace "eth0" with "cbr0" in "ip add" command,
as reported by github user @kjvalencik.

Update iptables command to match changes in kubernetes#13348.
  • Loading branch information
erictune committed Oct 5, 2015
1 parent 284039c commit ae5da89
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/getting-started-guides/scratch.md
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ because of how this is used later.
1. Set appropriate MTU
- `ip link set dev cbr0 mtu 1460` (NOTE: the actual value of MTU will depend on your network environment)
1. Add the clusters network to the bridge (docker will go on other side of bridge).
- e.g. `ip addr add $NODE_X_BRIDGE_ADDR dev eth0`
- e.g. `ip addr add $NODE_X_BRIDGE_ADDR dev cbr0`
1. Turn it on
- e.g. `ip link set dev cbr0 up`

Expand All @@ -485,7 +485,7 @@ other, then you may need to do masquerading just for destination IPs outside
the cluster network. For example:

```sh
iptables -w -t nat -A POSTROUTING -o eth0 -j MASQUERADE \! -d ${CLUSTER_SUBNET}
iptables -t nat -A POSTROUTING ! -d ${CLUSTER_SUBNET} -m addrtype ! --dst-type LOCAL -j MASQUERADE
```

This will rewrite the source address from
Expand Down

0 comments on commit ae5da89

Please sign in to comment.