-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
network: add networkctl reload and reconfigure #13452
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
Conversation
|
@mrc0mmand and @evverx What happens to the CIs?? |
|
@yuwata I'm not sure what happened on CentOS CI but it seems the fuzzers are failing to compile on Travis CI and Azure Pipelines with FAILED: clang -Isrc/network/70b1c79@@networkd-core@sta -Isrc/network -I../src/network -Isrc/basic -I../src/basic -Isrc/boot -I../src/boot -Isrc/shared -I../src/shared -Isrc/systemd -I../src/systemd -Isrc/journal -I../src/journal -Isrc/journal-remote -I../src/journal-remote -Isrc/nspawn -I../src/nspawn -Isrc/resolve -I../src/resolve -Isrc/timesync -I../src/timesync -I../src/time-wait-sync -Isrc/login -I../src/login -Isrc/udev -I../src/udev -Isrc/libudev -I../src/libudev -Isrc/core -I../src/core -Isrc/shutdown -I../src/shutdown -I../src/libsystemd/sd-bus -I../src/libsystemd/sd-device -I../src/libsystemd/sd-event -I../src/libsystemd/sd-hwdb -I../src/libsystemd/sd-id128 -I../src/libsystemd/sd-netlink -I../src/libsystemd/sd-network -I../src/libsystemd/sd-resolve -Isrc/libsystemd-network -I../src/libsystemd-network -I. -I../ -Xclang -fcolor-diagnostics -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=gnu99 -g -fsanitize=fuzzer-no-link -Wextra -Werror=undef -Wmissing-include-dirs -Wold-style-definition -Wpointer-arith -Winit-self -Wfloat-equal -Werror=missing-prototypes -Werror=implicit-function-declaration -Werror=missing-declarations -Werror=return-type -Werror=incompatible-pointer-types -Werror=format=2 -Wstrict-prototypes -Wredundant-decls -Wmissing-noreturn -Wshadow -Wendif-labels -Wstrict-aliasing=2 -Wwrite-strings -Werror=overflow -Werror=shift-count-overflow -Wdate-time -Wnested-externs -Wno-unused-parameter -Wno-missing-field-initializers -Wno-unused-result '-Wno-error=#warnings' -Wno-string-plus-int -Wno-error=nonnull -ffast-math -fno-common -fdiagnostics-show-option -fno-strict-aliasing -fvisibility=hidden -fstack-protector -fstack-protector-strong --param=ssp-buffer-size=4 -Wno-typedef-redefinition -Wno-gnu-variable-sized-type-not-at-end -Werror=shadow -include config.h -O1 -fno-omit-frame-pointer -gline-tables-only -DFUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION -fsanitize=address -fsanitize-address-use-after-scope -fPIC -MD -MQ 'src/network/70b1c79@@networkd-core@sta/networkd-manager-bus.c.o' -MF 'src/network/70b1c79@@networkd-core@sta/networkd-manager-bus.c.o.d' -o 'src/network/70b1c79@@networkd-core@sta/networkd-manager-bus.c.o' -c ../src/network/networkd-manager-bus.c
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:33:8: error: redefinition of 'in6_addr'
struct in6_addr {
^
/usr/include/netinet/in.h:211:8: note: previous definition is here
struct in6_addr
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:41:9: warning: 's6_addr' macro redefined [-Wmacro-redefined]
#define s6_addr in6_u.u6_addr8
^
/usr/include/netinet/in.h:221:9: note: previous definition is here
#define s6_addr __in6_u.__u6_addr8
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:43:9: warning: 's6_addr16' macro redefined [-Wmacro-redefined]
#define s6_addr16 in6_u.u6_addr16
^
/usr/include/netinet/in.h:223:10: note: previous definition is here
# define s6_addr16 __in6_u.__u6_addr16
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:44:9: warning: 's6_addr32' macro redefined [-Wmacro-redefined]
#define s6_addr32 in6_u.u6_addr32
^
/usr/include/netinet/in.h:224:10: note: previous definition is here
# define s6_addr32 __in6_u.__u6_addr32
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:50:8: error: redefinition of 'sockaddr_in6'
struct sockaddr_in6 {
^
/usr/include/netinet/in.h:254:8: note: previous definition is here
struct sockaddr_in6
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:60:8: error: redefinition of 'ipv6_mreq'
struct ipv6_mreq {
^
/usr/include/netinet/in.h:290:8: note: previous definition is here
struct ipv6_mreq
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:132:9: warning: 'IPPROTO_HOPOPTS' macro redefined [-Wmacro-redefined]
#define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop options */
^
/usr/include/netinet/in.h:102:9: note: previous definition is here
#define IPPROTO_HOPOPTS IPPROTO_HOPOPTS
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:133:9: warning: 'IPPROTO_ROUTING' macro redefined [-Wmacro-redefined]
#define IPPROTO_ROUTING 43 /* IPv6 routing header */
^
/usr/include/netinet/in.h:104:9: note: previous definition is here
#define IPPROTO_ROUTING IPPROTO_ROUTING
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:134:9: warning: 'IPPROTO_FRAGMENT' macro redefined [-Wmacro-redefined]
#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header */
^
/usr/include/netinet/in.h:106:9: note: previous definition is here
#define IPPROTO_FRAGMENT IPPROTO_FRAGMENT
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:135:9: warning: 'IPPROTO_ICMPV6' macro redefined [-Wmacro-redefined]
#define IPPROTO_ICMPV6 58 /* ICMPv6 */
^
/usr/include/netinet/in.h:108:9: note: previous definition is here
#define IPPROTO_ICMPV6 IPPROTO_ICMPV6
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:136:9: warning: 'IPPROTO_NONE' macro redefined [-Wmacro-redefined]
#define IPPROTO_NONE 59 /* IPv6 no next header */
^
/usr/include/netinet/in.h:110:9: note: previous definition is here
#define IPPROTO_NONE IPPROTO_NONE
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:137:9: warning: 'IPPROTO_DSTOPTS' macro redefined [-Wmacro-redefined]
#define IPPROTO_DSTOPTS 60 /* IPv6 destination options */
^
/usr/include/netinet/in.h:112:9: note: previous definition is here
#define IPPROTO_DSTOPTS IPPROTO_DSTOPTS
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:138:9: warning: 'IPPROTO_MH' macro redefined [-Wmacro-redefined]
#define IPPROTO_MH 135 /* IPv6 mobility header */
^
/usr/include/netinet/in.h:114:9: note: previous definition is here
#define IPPROTO_MH IPPROTO_MH
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:171:9: warning: 'IPV6_ADD_MEMBERSHIP' macro redefined [-Wmacro-redefined]
#define IPV6_ADD_MEMBERSHIP 20
^
/usr/include/x86_64-linux-gnu/bits/in.h:209:9: note: previous definition is here
#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP
^
In file included from ../src/network/networkd-manager-bus.c:12:
In file included from ../src/network/networkd-manager.h:18:
In file included from ../src/network/networkd-network.h:10:
In file included from ../src/network/netdev/bridge.h:5:
In file included from ../src/basic/linux/if_bridge.h:19:
../src/basic/linux/in6.h:172:9: warning: 'IPV6_DROP_MEMBERSHIP' macro redefined [-Wmacro-redefined]
#define IPV6_DROP_MEMBERSHIP 21
^
/usr/include/x86_64-linux-gnu/bits/in.h:210:9: note: previous definition is here
#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP
^
12 warnings and 3 errors generated.
ninja: build stopped: subcommand failed.It can be reproduced by installing |
|
Having said that, I can't seem to reproduce it on Fedora. Looks like it has something to do with the headers on Ubuntu Xenial. |
|
Ouch. Thanks. |
d0a71d4 to
a99b6a0
Compare
a99b6a0 to
ba384d1
Compare
|
@yuwata could you make different PR for reload and reconfigure only via networkctl and bus . Let's take issues one by one. Then add other features later. |
|
Needs rebase now. |
ba384d1 to
edf048a
Compare
|
Rebased. PTAL. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks very nice. I found some nitpicks with indentation and other minor things.
edf048a to
dcd9f07
Compare
|
@keszybz Thank you for your review. I've force-pushed a revised version. I hope all your comments are addressed. PTAL. |
|
LGTM! |
Why not? I face the problem that an actually full reload (including modified and deleted netdevs) requires reboot. |
No description provided.