New issue
Advanced search Search tips

Issue 753150 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Aug 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Fuchsia
Pri: 2
Type: Bug



Sign in to add a comment

Configure TAP network interface for qemu on Fuchsia bots

Project Member Reported by sergeyu@chromium.org, Aug 7 2017

Issue description

net_unittests depend on testserver written in python (see net/tools/testserver). On desktop platforms the testserver runs on the same machine as the test. For Android the testserver runs on the host with connection forwarding provided by ADB. Neither of these two approaches is currently feasible for Fuchsia: python is not supported and there is no port-forwarding solution like ADP. The following approach could work:
 1. Setup TAP network on the host for qemu
 2. Run dnsmasq to provide DNS + DHCP on that TAP interface.
 3. Run testserver on the host

Setting up (1) and (2) is simple, but requires root:

INTERFACE=qemu
sudo tunctl -u $USER -t qemu
sudo dnsmasq \
  --interface=$INTERFACE \
  --dhcp-range=$INTERFACE,192.168.3.53,192.168.3.255,24h \
  --dhcp-leasefile=/tmp/dnsmasq.leases \
  --listen-address=192.168.3.1

$USER here is the user account that runs the tests. $INTERFACE is the name of the TUN interface that just needs to match the name passed to qemu from test_runner.py .

These commands will need to be executed only once per bot (after each reboot).

 
Status: WontFix (was: Untriaged)
It looks like it should be possible to use qemu's netdev with type=user, which will allow to forward network connections from qemu guest to the host.
I like that solution much better :).

Sign in to add a comment