From a41b93c9fb61a02bba923d77919e0ef5df29a36b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20Franc=C3=A8s?= Date: Sun, 26 Jul 2015 10:10:42 +0200 Subject: [PATCH 1/3] Add arch install docs warning about systemd-network MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Oriol Francès Upstream-commit: 6bd15a68cf59043e05bd69fccbafcfed25d7c22e Component: engine --- .../engine/docs/installation/archlinux.md | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/components/engine/docs/installation/archlinux.md b/components/engine/docs/installation/archlinux.md index 1a28c5b1aa..b18be6c371 100644 --- a/components/engine/docs/installation/archlinux.md +++ b/components/engine/docs/installation/archlinux.md @@ -83,3 +83,26 @@ and volumes run the following command: $ rm -rf /var/lib/docker You must delete the user created configuration files manually. + +## Issues + +### systemd-network + +Users of systemd-network >= v220 who have configured their network manually by +creating an `.network` file in `/etc/systemd/network/` may have to add +the following line to make sure IP Forwarding is not disabled: + +``` +[Network] +... +IPForward=kernel +... +``` + +From systemd-network v220 onwards, the forwarding setting for a given network +defaults to *off* (instead of not being set). This prevents IP Forwarding to +happen, since docker only enables `net.ipv4.conf.all.forwarding` (which is +overriden by `net.ipv4.conf..forwarding` being disabled) + +Adding `IPForward=kernel` to the `.network` file prevents this +behavior, allowing IP Forwarding to function as expected. From 0560ee0b4513eaca9173ba35228208e290278e53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20Franc=C3=A8s?= Date: Sun, 26 Jul 2015 13:25:01 +0200 Subject: [PATCH 2/3] Change of wording, rearrange section ordering MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Oriol Francès Upstream-commit: e1b57b2a87a763fc9fac5fbd59f64dcf1e541e7e Component: engine --- .../engine/docs/installation/archlinux.md | 40 +++++++++---------- 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/components/engine/docs/installation/archlinux.md b/components/engine/docs/installation/archlinux.md index b18be6c371..8b0c40f6ef 100644 --- a/components/engine/docs/installation/archlinux.md +++ b/components/engine/docs/installation/archlinux.md @@ -66,27 +66,7 @@ If you need to add an HTTP Proxy, set a different directory or partition for the Docker runtime files, or make other customizations, read our systemd article to learn how to [customize your systemd Docker daemon options](/articles/systemd/). -## Uninstallation - -To uninstall the Docker package: - - $ sudo pacman -R docker - -To uninstall the Docker package and dependencies that are no longer needed: - - $ sudo pacman -Rns docker - -The above commands will not remove images, containers, volumes, or user created -configuration files on your host. If you wish to delete all images, containers, -and volumes run the following command: - - $ rm -rf /var/lib/docker - -You must delete the user created configuration files manually. - -## Issues - -### systemd-network +## Running docker with a manually defined network Users of systemd-network >= v220 who have configured their network manually by creating an `.network` file in `/etc/systemd/network/` may have to add @@ -106,3 +86,21 @@ overriden by `net.ipv4.conf..forwarding` being disabled) Adding `IPForward=kernel` to the `.network` file prevents this behavior, allowing IP Forwarding to function as expected. + +## Uninstallation + +To uninstall the Docker package: + + $ sudo pacman -R docker + +To uninstall the Docker package and dependencies that are no longer needed: + + $ sudo pacman -Rns docker + +The above commands will not remove images, containers, volumes, or user created +configuration files on your host. If you wish to delete all images, containers, +and volumes run the following command: + + $ rm -rf /var/lib/docker + +You must delete the user created configuration files manually. From b39a60e32389e88c13491fd6b900b22c028108c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oriol=20Franc=C3=A8s?= Date: Sun, 26 Jul 2015 19:11:27 +0200 Subject: [PATCH 3/3] much improved wording for manual network config setup on arch install docs by @moxiegirl MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Oriol Francès Upstream-commit: 26fa9b0d0d23700ba87aba7862fcf2baa5c26f1e Component: engine --- .../engine/docs/installation/archlinux.md | 23 +++++++++---------- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/components/engine/docs/installation/archlinux.md b/components/engine/docs/installation/archlinux.md index 8b0c40f6ef..4447d59d62 100644 --- a/components/engine/docs/installation/archlinux.md +++ b/components/engine/docs/installation/archlinux.md @@ -66,11 +66,17 @@ If you need to add an HTTP Proxy, set a different directory or partition for the Docker runtime files, or make other customizations, read our systemd article to learn how to [customize your systemd Docker daemon options](/articles/systemd/). -## Running docker with a manually defined network +## Running Docker with a manually-defined network -Users of systemd-network >= v220 who have configured their network manually by -creating an `.network` file in `/etc/systemd/network/` may have to add -the following line to make sure IP Forwarding is not disabled: +If you manually configure your network using `systemd-network` version 220 or +higher, containers you start with Docker may be unable to access your network. +Beginning with version 220, the forwarding setting for a given network +(`net.ipv4.conf..forwarding`) defaults to *off*. This setting +prevents IP forwarding. It also conflicts with Docker which enables the +`net.ipv4.conf.all.forwarding` setting within a container. + +To work around this, edit the `.network` file in +`/etc/systemd/network/` on your Docker host add the following block: ``` [Network] @@ -79,14 +85,7 @@ IPForward=kernel ... ``` -From systemd-network v220 onwards, the forwarding setting for a given network -defaults to *off* (instead of not being set). This prevents IP Forwarding to -happen, since docker only enables `net.ipv4.conf.all.forwarding` (which is -overriden by `net.ipv4.conf..forwarding` being disabled) - -Adding `IPForward=kernel` to the `.network` file prevents this -behavior, allowing IP Forwarding to function as expected. - +This configuration allows IP forwarding from the container as expected. ## Uninstallation To uninstall the Docker package: