Subject: cloning tap device (was : qemu networking under -current)
To: None <netbsd-help@netbsd.org>
From: Thierry Lacoste <th.lacoste@wanadoo.fr>
List: netbsd-help
Date: 03/18/2005 16:36:44
I have the following line in my kernel config file:
   pseudo-device   tap                     # virtual Ethernet

man 4 tap says concerning the cloning device:
     A new interface is created at the
     opening of /dev/tap, and is later destroyed when the last process using
     the file descriptor closes it.

When I run the following program below as root,
I have a "Device not configured" error.

#include <fcntl.h>
int main()
{
    int fd = open("/dev/tap", O_RDWR);
    perror(NULL);
}

How do I configure this device?

Regards,
Thierry.