Page MenuHomeVyOS Platform

1.2.0 LTS cant delete wireguard wg0 interface
Closed, ResolvedPublicBUG

Description

I tried after updating to VyOS 1.2.0 LTS from rolling release RC4 to remove my wireguard interface since it is no longer working and i wanted to try to reapply it.

This is the error i get

[edit]
fma@glos1ce1dk# comp
[edit interfaces]
-wireguard wg0 {
-    address 10.0.100.1/24
-    description Core
-    peer colowall {
-        allowed-ips 10.0.90.0/24
-        allowed-ips 10.20.30.0/24
-        allowed-ips 10.0.1.0/24
-        allowed-ips 10.201.201.0/24
-        allowed-ips 10.202.202.0/24
-        allowed-ips 172.20.1.0/24
-        endpoint 83.X.X.X:54321
-        pubkey secret=
-    }
-    port 54321
-}
[edit]
fma@glos1ce1dk# commit
[ interfaces wireguard wg0 ]
Traceback (most recent call last):
  File "/usr/libexec/vyos/conf_mode/wireguard.py", line 356, in <module>
    apply(c)
  File "/usr/libexec/vyos/conf_mode/wireguard.py", line 152, in apply
    buf = open('/sys/class/net/' + dev + '/uevent', 'r').read()
NotADirectoryError: [Errno 20] Not a directory: '/sys/class/net/bonding_masters/uevent'

delete [ interfaces wireguard wg0 ] failed
Commit failed
[edit]
fma@glos1ce1dk#

Details

Version
1.2.0 LTS

Event Timeline

I can't replicate it, but I'm using also the rolling release.
Can you please provide the output of:

  1. show version
  1. sh conf comm

thx

fma@glos1ce1dk:~$ sh ver
Version:          VyOS 1.2.0
Built by:         Sentrium S.L.
Built on:         Sun 27 Jan 2019 19:08 UTC
Build ID:         795d6338-c1ce-4ebb-992f-d064f5af9309

Architecture:     x86_64
Boot via:         installed image
System type:      bare metal

Hardware vendor:  To be filled by O.E.M.
Hardware model:   To be filled by O.E.M.
Hardware S/N:     Unknown
Hardware UUID:    Unknown

Copyright:        VyOS maintainers and contributors
fma@glos1ce1dk:~$ 
fma@glos1ce1dk:~$ sh conf commands 
set firewall all-ping 'enable'
set firewall broadcast-ping 'disable'
set firewall config-trap 'disable'
set firewall group address-group desktop address '10.0.1.89'
set firewall group port-group desktopports port '2626'
set firewall ip-src-route 'disable'
set firewall ipv6-receive-redirects 'disable'
set firewall ipv6-src-route 'disable'
set firewall log-martians 'enable'
set firewall name outside-in default-action 'drop'
set firewall name outside-in rule 10 action 'accept'
set firewall name outside-in rule 10 state established 'enable'
set firewall name outside-in rule 10 state related 'enable'
set firewall name outside-in rule 32 action 'accept'
set firewall name outside-in rule 32 destination address '10.0.1.89'
set firewall name outside-in rule 32 destination port '2626'
set firewall name outside-in rule 32 protocol 'udp'
set firewall name outside-in rule 32 state new 'enable'
set firewall name outside-in rule 33 action 'accept'
set firewall name outside-in rule 33 destination address '10.0.1.89'
set firewall name outside-in rule 33 destination port '80'
set firewall name outside-in rule 33 protocol 'tcp'
set firewall name outside-in rule 33 state new 'enable'
set firewall name outside-in rule 34 action 'accept'
set firewall name outside-in rule 34 destination address '10.0.1.89'
set firewall name outside-in rule 34 destination port '443'
set firewall name outside-in rule 34 protocol 'tcp'
set firewall name outside-in rule 34 state new 'enable'
set firewall name outside-in rule 35 action 'accept'
set firewall name outside-in rule 35 destination address '10.0.1.89'
set firewall name outside-in rule 35 destination port '6672'
set firewall name outside-in rule 35 protocol 'udp'
set firewall name outside-in rule 35 state new 'enable'
set firewall name outside-in rule 36 action 'accept'
set firewall name outside-in rule 36 destination address '10.0.1.89'
set firewall name outside-in rule 36 destination port '61455'
set firewall name outside-in rule 36 protocol 'udp'
set firewall name outside-in rule 36 state new 'enable'
set firewall name outside-in rule 37 action 'accept'
set firewall name outside-in rule 37 destination address '10.0.1.89'
set firewall name outside-in rule 37 destination port '61457'
set firewall name outside-in rule 37 protocol 'udp'
set firewall name outside-in rule 37 state new 'enable'
set firewall name outside-in rule 38 action 'accept'
set firewall name outside-in rule 38 destination address '10.0.1.89'
set firewall name outside-in rule 38 destination port '61457'
set firewall name outside-in rule 38 protocol 'udp'
set firewall name outside-in rule 38 state new 'enable'
set firewall name outside-in rule 39 action 'accept'
set firewall name outside-in rule 39 destination address '10.0.1.89'
set firewall name outside-in rule 39 destination port '61458'
set firewall name outside-in rule 39 protocol 'udp'
set firewall name outside-in rule 39 state new 'enable'
set firewall name outside-local default-action 'drop'
set firewall name outside-local rule 10 action 'accept'
set firewall name outside-local rule 10 state established 'enable'
set firewall name outside-local rule 10 state related 'enable'
set firewall name outside-local rule 20 action 'accept'
set firewall name outside-local rule 20 icmp type-name 'echo-reply'
set firewall name outside-local rule 20 protocol 'icmp'
set firewall name outside-local rule 20 state new 'enable'
set firewall name outside-local rule 30 action 'drop'
set firewall name outside-local rule 30 destination port '22'
set firewall name outside-local rule 30 protocol 'tcp'
set firewall name outside-local rule 30 recent count '4'
set firewall name outside-local rule 30 recent time '60'
set firewall name outside-local rule 30 state new 'enable'
set firewall name outside-local rule 31 action 'accept'
set firewall name outside-local rule 31 destination port '22'
set firewall name outside-local rule 31 protocol 'tcp'
set firewall name outside-local rule 31 state new 'enable'
set firewall name outside-local rule 32 action 'accept'
set firewall name outside-local rule 32 destination address '10.0.1.89'
set firewall name outside-local rule 32 destination port '2626'
set firewall name outside-local rule 32 protocol 'tcp_udp'
set firewall name outside-local rule 32 state new 'enable'
set firewall receive-redirects 'disable'
set firewall send-redirects 'enable'
set firewall source-validation 'disable'
set firewall syn-cookies 'enable'
set firewall twa-hazards-protection 'disable'
set interfaces bonding bond0 description 'Bundle of eth0-3 4Gbit'
set interfaces bonding bond0 hash-policy 'layer2'
set interfaces bonding bond0 mode '802.3ad'
set interfaces bonding bond0 vif 101 address '10.0.1.1/24'
set interfaces bonding bond0 vif 101 address 'X:X:71a::/48'
set interfaces bonding bond0 vif 101 description 'LAN'
set interfaces bonding bond0 vif 200 address '85.204.X.X/26'
set interfaces bonding bond0 vif 200 address 'X:X:0:b::1a/64'
set interfaces bonding bond0 vif 200 firewall in name 'outside-in'
set interfaces bonding bond0 vif 200 firewall local
set interfaces ethernet eth0 bond-group 'bond0'
set interfaces ethernet eth0 description 'member of bond0'
set interfaces ethernet eth0 duplex 'auto'
set interfaces ethernet eth0 hw-id '00:0e:c4:ce:7c:98'
set interfaces ethernet eth0 smp-affinity 'auto'
set interfaces ethernet eth0 speed 'auto'
set interfaces ethernet eth1 bond-group 'bond0'
set interfaces ethernet eth1 description 'member of bond0'
set interfaces ethernet eth1 duplex 'auto'
set interfaces ethernet eth1 hw-id '00:0e:c4:ce:7c:99'
set interfaces ethernet eth1 smp-affinity 'auto'
set interfaces ethernet eth1 speed 'auto'
set interfaces ethernet eth2 bond-group 'bond0'
set interfaces ethernet eth2 description 'member of bond0'
set interfaces ethernet eth2 duplex 'auto'
set interfaces ethernet eth2 hw-id '00:0e:c4:ce:7c:9a'
set interfaces ethernet eth2 smp-affinity 'auto'
set interfaces ethernet eth2 speed 'auto'
set interfaces ethernet eth4 bond-group 'bond0'
set interfaces ethernet eth4 description 'member of bond0'
set interfaces ethernet eth4 duplex 'auto'
set interfaces ethernet eth4 hw-id '00:0e:c4:ce:7c:9b'
set interfaces ethernet eth4 smp-affinity 'auto'
set interfaces ethernet eth4 speed 'auto'
set interfaces wireguard wg0 address '10.0.100.1/24'
set interfaces wireguard wg0 description 'Core'
set interfaces wireguard wg0 peer colowall allowed-ips '10.0.0.0/8'
set interfaces wireguard wg0 peer colowall endpoint '83.X.X.X:54321'
set interfaces wireguard wg0 peer colowall pubkey 'secret='
set interfaces wireguard wg0 port '54321'
set nat destination rule 10 description 'port forward: 2929 to 10.0.1.89'
set nat destination rule 10 destination port '2929'
set nat destination rule 10 inbound-interface 'bond0.200'
set nat destination rule 10 protocol 'udp'
set nat destination rule 10 translation address '10.0.1.89'
set nat destination rule 11 description 'port forward: 2626 to 10.0.1.89'
set nat destination rule 11 destination port '2626'
set nat destination rule 11 inbound-interface 'bond0.200'
set nat destination rule 11 protocol 'tcp_udp'
set nat destination rule 11 translation address '10.0.1.89'
set nat destination rule 11 translation port '2626'
set nat destination rule 12 description 'port forward: 80 to 10.0.1.89'
set nat destination rule 12 destination port '80'
set nat destination rule 12 inbound-interface 'bond0.200'
set nat destination rule 12 protocol 'tcp_udp'
set nat destination rule 12 translation address '10.0.1.89'
set nat destination rule 13 description 'port forward: 443 to 10.0.1.89'
set nat destination rule 13 destination port '443'
set nat destination rule 13 inbound-interface 'bond0.200'
set nat destination rule 13 protocol 'tcp_udp'
set nat destination rule 13 translation address '10.0.1.89'
set nat destination rule 14 description 'port forward: 6672 to 10.0.1.89'
set nat destination rule 14 destination port '6672'
set nat destination rule 14 inbound-interface 'bond0.200'
set nat destination rule 14 protocol 'tcp_udp'
set nat destination rule 14 translation address '10.0.1.89'
set nat destination rule 15 description 'port forward: 61455 to 10.0.1.89'
set nat destination rule 15 destination port '61455'
set nat destination rule 15 inbound-interface 'bond0.200'
set nat destination rule 15 protocol 'tcp_udp'
set nat destination rule 15 translation address '10.0.1.89'
set nat destination rule 16 description 'port forward: 61456 to 10.0.1.89'
set nat destination rule 16 destination port '61456'
set nat destination rule 16 inbound-interface 'bond0.200'
set nat destination rule 16 protocol 'tcp_udp'
set nat destination rule 16 translation address '10.0.1.89'
set nat destination rule 17 description 'port forward: 61457 to 10.0.1.89'
set nat destination rule 17 destination port '61457'
set nat destination rule 17 inbound-interface 'bond0.200'
set nat destination rule 17 protocol 'tcp_udp'
set nat destination rule 17 translation address '10.0.1.89'
set nat destination rule 18 description 'port forward: 61458 to 10.0.1.89'
set nat destination rule 18 destination port '61458'
set nat destination rule 18 inbound-interface 'bond0.200'
set nat destination rule 18 protocol 'tcp_udp'
set nat destination rule 18 translation address '10.0.1.89'
set nat source rule 100 outbound-interface 'bond0.200'
set nat source rule 100 source address '10.0.1.0/24'
set nat source rule 100 translation address 'masquerade'
set protocols static interface-route 10.0.0.0/8 next-hop-interface wg0
set protocols static route 0.0.0.0/0 next-hop 85.X.X.X
set protocols static route6 ::/0 next-hop X:X:0:b::1 interface 'bond0.200'
set service dhcp-server shared-network-name LAN subnet 10.0.1.0/24 default-router '10.0.1.1'
set service dhcp-server shared-network-name LAN subnet 10.0.1.0/24 dns-server '10.0.1.1'
set service dhcp-server shared-network-name LAN subnet 10.0.1.0/24 domain-name 'X.dk'
set service dhcp-server shared-network-name LAN subnet 10.0.1.0/24 lease '86400'
set service dhcp-server shared-network-name LAN subnet 10.0.1.0/24 range 0 start '10.0.1.2'
set service dhcp-server shared-network-name LAN subnet 10.0.1.0/24 range 0 stop '10.0.1.250'
set service dhcpv6-relay listen-interface bond0.101 address 'X:X:71a::'
set service dhcpv6-relay upstream-interface bond0.200 address 'X:X:0:b::1'
set service dns forwarding domain coloserver.X.dk server '10.20.30.1'
set service dns forwarding domain dlbot.X.dk server '10.20.30.1'
set service dns forwarding domain gamecache.X.dk server '10.0.1.102'
set service dns forwarding domain librenms.X.dk server '10.20.30.1'
set service dns forwarding domain sickrage.X.dk server '10.20.30.1'
set service dns forwarding listen-address '10.0.1.1'
set service dns forwarding name-server '1.1.1.1'
set service lldp snmp enable
set service snmp community Xdk authorization 'ro'
set service snmp community Xdk network '10.0.0.0/8'
set service snmp community Xdk network '83.X.X.X/27'
set service snmp location 'DK, Glostrup'
set service ssh listen-address '0.0.0.0'
set service ssh port '22'
set system config-management commit-revisions '20'
set system console device ttyS0 speed '9600'
set system host-name 'glos1ce1dk'
set system login user fma authentication encrypted-password 
set system login user fma authentication plaintext-password ''
set system login user fma level 'admin'
set system name-server '1.1.1.1'
set system ntp server 0.pool.ntp.org
set system ntp server 1.pool.ntp.org
set system ntp server 2.pool.ntp.org
set system static-host-mapping host-name coloserver.X.dk inet '10.20.30.2'
set system static-host-mapping host-name dlbot.X.dk inet '10.20.30.8'
set system static-host-mapping host-name freenas.X.dk inet '10.20.30.4'
set system static-host-mapping host-name sickrage.X.dk inet '10.20.30.7'
set system static-host-mapping host-name unifi.X.dk inet '10.20.30.25'
set system syslog global facility all level 'notice'
set system syslog global facility protocols level 'debug'
set system time-zone 'Europe/Copenhagen'
fma@glos1ce1dk:~$
hagbard changed the task status from Open to Confirmed.Jan 30 2019, 10:48 PM
hagbard triaged this task as Normal priority.

Bug confirmed.

hagbard changed the task status from Confirmed to In progress.Jan 30 2019, 10:54 PM
hagbard edited a custom field.
hagbard edited a custom field.