-
Notifications
You must be signed in to change notification settings - Fork 881
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
send SIGHUP to docker daemon after change daemon.json , docker network doesn't reload correctly #1264
Comments
See https://github.com/docker/libnetwork/blob/master/drivers/overlay/overlay.go#L292 Initial requirement was to only accept a datastore config if one was not already present. |
@aboch so you mean, if I want to change a datastore config, I can't send SIGHUP to docker daemon to make it works, because it still hold the last datastore config. |
yeah, libnetwork drivers will discard a new datastore config (received via SIGHUP daemon reload) if they already have a global scope datastore configured |
@aboch Will it support reconfigure already configured datestore config without requiring to restart docker daemon in the future? |
@wangweihong It is not on the plans at the moment. Will go ahead and close this issue, as what can be done with SIGHUP was clarified. |
environment:
Linux bogon 3.10.0-229.el7.x86_64 #1 SMP Fri Mar 6 11:36:42 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux
docker Version:
1.11.2
{
"cluster-advertise": "192.168.14.87:2375",
"cluster-store": "etcd://192.168.14.130:2379"
}
node2 is fresh, it didn't configure docker cluster configuration before.
pidof docker
", docker info command get right infos:[root@bogon ~]# docker info
...
Labels:
com.example.environment="production"
Cluster store: etcd://192.168.14.130:2379
Cluster advertise: 192.168.14.87:2375
docker netowork ls
shows[root@bogon ~]# docker network ls
NETWORK ID NAME DRIVER
fc1fa519d860 bridge bridge
a34729eddc3e bridge10 overlay
63795cfb1874 bridge11 overlay
c8f6150341f0 bridge2 overlay
c8f6150341f0 bridge2 overlay
f7caa25698eb bridge5 overlay
e21e3206baff bridge6 overlay
4bfd9837011f bridge7 overlay
d83655b1d8dc bridge9 overlay
71f7ce2a1f59 host host
864d033a3a1d isolated_Network overlay
394cbced64d6 none null
f44205d44b1b test1 overlay
fe691a8573c8 test2 overlay
{
"cluster-advertise": "192.168.14.87:2375",
"cluster-store": "etcd://192.168.14.130:2379**/test3**"
}
5.run setp 2, 3 again
[root@bogon ~]# kill -SIGHUP
pidof docker
[root@bogon ~]# docker info
...
Labels:
com.example.environment="production"
Cluster store: etcd://192.168.14.130:2379/test3
Cluster advertise: 192.168.14.87:2375
[root@bogon ~]# docker network ls
NETWORK ID NAME DRIVER
fc1fa519d860 bridge bridge
a34729eddc3e bridge10 overlay
63795cfb1874 bridge11 overlay
c8f6150341f0 bridge2 overlay
docker network ls
show infos stored in etcd://192.168.14.130:2379 instead of etcd://192.168.14.130:2379/test3docker network ls
show correct infos after restart docker daemon[root@bogon ~]# systemctl restart docker
[root@bogon ~]# docker network ls
NETWORK ID NAME DRIVER
fd8072220683 bridge bridge
082f0f6947bd bridge3 overlay
958c9f00d0e5 bridge4 overlay
9f380b2f9829 bridge5 overlay
bce851833ab5 docker_gwbridge bridge
cc1c38e19959 host host
b1f56b75853a network 1 overlay
4d52f6e74d73 network 2 overlay
4f74db38d8f2 network 3 overlay
841cce023697 network 4 overlay
182a7c53433d none null
Is this a bug?
The text was updated successfully, but these errors were encountered: