{"action":"created","issue":{"url":"https://api.github.com/repos/systemd/systemd/issues/9254","repository_url":"https://api.github.com/repos/systemd/systemd","labels_url":"https://api.github.com/repos/systemd/systemd/issues/9254/labels{/name}","comments_url":"https://api.github.com/repos/systemd/systemd/issues/9254/comments","events_url":"https://api.github.com/repos/systemd/systemd/issues/9254/events","html_url":"https://github.com/systemd/systemd/issues/9254","id":331111922,"node_id":"MDU6SXNzdWUzMzExMTE5MjI=","number":9254,"title":"[network] Setting the MTU on a vxlan interface is throwing an invalid argument error","user":{"login":"shibumi","id":3833685,"node_id":"MDQ6VXNlcjM4MzM2ODU=","avatar_url":"https://avatars3.githubusercontent.com/u/3833685?v=4","gravatar_id":"","url":"https://api.github.com/users/shibumi","html_url":"https://github.com/shibumi","followers_url":"https://api.github.com/users/shibumi/followers","following_url":"https://api.github.com/users/shibumi/following{/other_user}","gists_url":"https://api.github.com/users/shibumi/gists{/gist_id}","starred_url":"https://api.github.com/users/shibumi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shibumi/subscriptions","organizations_url":"https://api.github.com/users/shibumi/orgs","repos_url":"https://api.github.com/users/shibumi/repos","events_url":"https://api.github.com/users/shibumi/events{/privacy}","received_events_url":"https://api.github.com/users/shibumi/received_events","type":"User","site_admin":false},"labels":[{"id":219549709,"node_id":"MDU6TGFiZWwyMTk1NDk3MDk=","url":"https://api.github.com/repos/systemd/systemd/labels/network","name":"network","color":"fad8c7","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":15,"created_at":"2018-06-11T09:30:38Z","updated_at":"2018-06-15T10:44:07Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"**systemd version the issue has been seen with**\r\n> 237\r\n\r\n<!-- **NOTE:** Do not submit bug reports about anything but the two most recently released systemd versions upstream! -->\r\n<!-- For older version please use distribution trackers (see https://github.com/systemd/systemd/blob/master/.github/CONTRIBUTING.md#filing-issues). -->\r\n\r\n**Used distribution**\r\n > Ubuntu 18.04\r\n\r\n**Expected behaviour you didn't see**\r\nThe VXLAN Interface should come up with the right MTU.\r\n\r\n**Unexpected behaviour you saw**\r\nThe VXLAN interface doesn't come up when a Link section exists with a `MTUBytes` argument.\r\n`journalctl -u systemd-networkd.service` shows in this case:\r\n```\r\nJun 11 09:14:02 ubuntu-template18 systemd-networkd[4355]: vxlan1309: Could not bring up interface: Invalid argument \r\n```\r\n\r\n**Steps to reproduce the problem**\r\n\r\n`/etc/systemd/network/ens160.network`\r\n```\r\n[Match]\r\nName=ens160\r\n\r\n[Link]\r\nMTUBytes=9000\r\n\r\n[Network]\r\nAddress=xxx.xxx.xxx.100/27\r\nGateway=xxx.xxx.xxx.126\r\nDNS=xxx.xxx.xxx.2\r\nVXLAN=vxlan1309\r\n```\r\n\r\n`/etc/systemd/network/vxlan1309.netdev`:\r\n```\r\n[NetDev]\r\nName=vxlan1309\r\nKind=vxlan\r\n\r\n[VXLAN]\r\nId=1309\r\nMacLearning=false\r\nDestinationPort=4789\r\n```\r\n\r\n`/etc/systemd/network/vxlan1309.network`:\r\n```\r\n[Match]\r\nName=vxlan1309\r\n\r\n[Link]\r\nMTUBytes=8950\r\n\r\n[Network]\r\nBridge=vxbr1309\r\n```\r\n\r\n`/etc/systemd/networkd/vxbr1309.netdev`\r\n```\r\n[NetDev]\r\nName=vxbr1309\r\nKind=bridge\r\n```\r\n\r\n`/etc/systemd/networkd/vxbr1309.network`\r\n```\r\n[Match]\r\nName=vxbr1309\r\n```\r\n\r\n`networkctl status vxlan1309` : \r\n```\r\n● 7: vxlan1309\r\n       Link File: /lib/systemd/network/99-default.link\r\n    Network File: /etc/systemd/network/vxlan1309.network\r\n            Type: ether\r\n           State: off (configuring)\r\n          Driver: vxlan\r\n      HW Address: 3a:72:15:cf:c5:19\r\n```\r\n\r\n\r\nWhen I remove the `Link`-Section from `vxlan1309.network` the vxlan interfaces comes up as expected.\r\nMy Problem is that I want to a VXLAN Interface with MTU 8950 and a physical interface with MTU 9000.\r\nNormally when I would need todo this with the `iproute2`-utils I would just set the MTU 9000 on the physical interface `ens160` and then I would create the vxlan interface and the vxlan interface would have the right MTU `8950` automatically.\r\n`# ip link set ens160 mtu 9000`\r\n`# ip link add vxlan1309 type vxlan id 1309 nolearning dstport 4789 dev ens160`\r\n\r\nMy suspicion is that the VXLAN interface get not up because it tries to set the MTU 8950, but the physical interface has only MTU 1500, because systemd-networkd fails to set the MTU via udev for the physical interface.\r\n\r\nSo I guess the main problem here is that the MTU settings get not applied when I restart `systemd-networkd`.\r\n\r\nMy Questions are:\r\n1. Is defining the MTU in a `link`-Section in the network file even the right way?\r\n2. how to set the MTU without restarting the whole machine? When I reboot the MTU for both interfaces get applied as expected. But without reboot and just restart `systemd-networkd` or `systemd-udev-trigger` the MTU will not get applied. (setting it manually via `ip link set..` works)\r\n3. I have also tried setting the MTU in the netdev file of the vxlan interface. Same result.The MTU will not get applied.\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/systemd/systemd/issues/comments/397584123","html_url":"https://github.com/systemd/systemd/issues/9254#issuecomment-397584123","issue_url":"https://api.github.com/repos/systemd/systemd/issues/9254","id":397584123,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NzU4NDEyMw==","user":{"login":"shibumi","id":3833685,"node_id":"MDQ6VXNlcjM4MzM2ODU=","avatar_url":"https://avatars3.githubusercontent.com/u/3833685?v=4","gravatar_id":"","url":"https://api.github.com/users/shibumi","html_url":"https://github.com/shibumi","followers_url":"https://api.github.com/users/shibumi/followers","following_url":"https://api.github.com/users/shibumi/following{/other_user}","gists_url":"https://api.github.com/users/shibumi/gists{/gist_id}","starred_url":"https://api.github.com/users/shibumi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shibumi/subscriptions","organizations_url":"https://api.github.com/users/shibumi/orgs","repos_url":"https://api.github.com/users/shibumi/repos","events_url":"https://api.github.com/users/shibumi/events{/privacy}","received_events_url":"https://api.github.com/users/shibumi/received_events","type":"User","site_admin":false},"created_at":"2018-06-15T10:44:07Z","updated_at":"2018-06-15T10:44:07Z","author_association":"CONTRIBUTOR","body":"The MTU for eth0 get set but VXLAN will not get created.. maybe because of the netlink permission errors although I am root (are here kernel capabilities involved?) or maybe because systemd-networkd has the wrong sequence and tries to create the vxlan interface with MTU 8950 before setting the MTU for the physical interface"}}
{"actor":{"display_login":"shibumi"}}