sandia-minimega / minimega

minimega
GNU General Public License v3.0
148 stars 68 forks source link

tests: fix router, router_static, tap_mirror_vm #1365

Closed jcrussell closed 5 years ago

jcrussell commented 5 years ago

Describe your environment

  1. minimega version: master

Various tests need minor tweaks.

router:

Name:   foo.com                                                 Name:   foo.com
Address: 1.1.1.1                                                Address: 1.1.1.1
** server can't find foo.com: REFUSED                         <

Server:         1.2.3.4                                         Server:         1.2.3.4
Address:        1.2.3.4#53                                      Address:        1.2.3.4#53

Name:   bar.com                                                 Name:   bar.com
Address: 2.2.2.2                                                Address: 2.2.2.2
** server can't find bar.com: REFUSED                         <

router_static:

Named Static Routes:                                            Named Static Routes:
defaultroute                                                    defaultroute
        0.0.0.0/0       2.0.0.2                                         0.0.0.0/0       2.0.0.2
foobar                                                          foobar
        11.0.0.0/24                                           <
        10.0.0.0/24                                                     10.0.0.0/24
                                                              >         11.0.0.0/24

distributed/tap_mirror_vm:

## # should work                                                ## # should work
## tap mirror a 0 b 0                                           ## tap mirror a 0 b 0
E: cannot mirror tap to itself                                <

## # clear by destination                                       ## # clear by destination
## clear tap mirror b 0                                         ## clear tap mirror b 0

## # already cleared, should have error                         ## # already cleared, should have error
## clear tap mirror b 0                                         ## clear tap mirror b 0
                                                              > E: not a valid mirror
jcrussell commented 5 years ago

Found part of the issue for distributed/tap_mirror_vm:

2019/08/27 19:10:29 ERROR container.go:967: create tap: set MAC failed: exit status 1: Cannot find device "veth0"
2019/08/27 19:10:29 ERROR vm.go:744: vm 1: create tap: set MAC failed: exit status 1: Cannot find device "veth0"

It's failing to create taps for the containers.

jcrussell commented 5 years ago

Ran tests with stretch instead of buster and these passed.

jcrussell commented 5 years ago

@djfritz: if we don't care about supporting buster this release, we can punt this to v2.7.

jcrussell commented 5 years ago

Buster has dnsmasq v2.80 and stretch has v2.76, maybe the source of the router error.

djfritz commented 5 years ago

Everyone basically uses various stable/LTS things anyways, so punting sounds great to me.

djfritz commented 5 years ago

This is fixed and all tests are again passing since #1378 was merged. Closing.