From owner-freebsd-questions@FreeBSD.ORG Sun Jun 28 06:09:32 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EAF43106564A for ; Sun, 28 Jun 2009 06:09:32 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from dd12710.kasserver.com (dd12710.kasserver.com [85.13.134.233]) by mx1.freebsd.org (Postfix) with ESMTP id A68A38FC16 for ; Sun, 28 Jun 2009 06:09:32 +0000 (UTC) (envelope-from guru@unixarea.de) Received: from localhost.my.domain (ppp-93-104-38-65.dynamic.mnet-online.de [93.104.38.65]) by dd12710.kasserver.com (Postfix) with ESMTP id 3856A184EAA35; Sun, 28 Jun 2009 08:09:32 +0200 (CEST) Received: (from guru@localhost) by localhost.my.domain (8.14.3/8.14.3/Submit) id n5S69YIV002393; Sun, 28 Jun 2009 08:09:34 +0200 (CEST) (envelope-from guru@unixarea.de) X-Authentication-Warning: localhost.my.domain: guru set sender to guru@unixarea.de using -f Date: Sun, 28 Jun 2009 08:09:33 +0200 From: Matthias Apitz To: Jim Message-ID: <20090628060933.GA2336@current.Sisis.de> References: <80f4f2b20906260737u7768f5a4j9955f78e64789579@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <80f4f2b20906260737u7768f5a4j9955f78e64789579@mail.gmail.com> User-Agent: Mutt/1.4.2.3i X-Operating-System: FreeBSD 8.0-CURRENT (i386) Cc: freebsd-questions@freebsd.org Subject: Re: QEMU + FreeBSD X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Matthias Apitz List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 28 Jun 2009 06:09:33 -0000 El día Friday, June 26, 2009 a las 10:37:14AM -0400, Jim escribió: > I have installed FreeBSD 7.2 on my notebook in the last week, and > installed QEmu as well. > > I cannot seem to get the network interface working. It works on my > desktop machine, but that is running 7.0 > > looking around, I tried to find some other options, and went here: > http://wiki.freebsd.org/qemu > > and got stuck at this step: > # sysctl net.link.ether.bridge_cfg=fxp0,tap0 > # sysctl net.link.ether.bridge.enable=1 > > because nothing matching "net.link.ether.bridge*" exists. > > Does anyone know of a current good setup document? > > thanks, > -Jim Stapleton Jim, You should have the following kernel modules loaded: # kldload kqemu # kldload if_tap # kldload aio Then you may either used a devd hook to ifconfig the interface or (as I do) start 'qemu' as root. It will execute a shell script when it brings up the interface as: $ cat /usr/local/etc/qemu-ifup #!/bin/sh /sbin/ifconfig $1 172.20.0.1 (for the 'ifconfig' you must be root, or use devd hook, or 'sudo' in the script). That's all. Set the other end of the NIC in the guest system to IP 172.20.0.2 end the communication with the host OS (your FreeBSD 7.2) should be fine. To reach the outerworld from the guest, I'm using NAT in the host OS. Check the FreeBSD handbook how to enable this. HIH matthias -- Matthias Apitz t +49-89-61308 351 - f +49-89-61308 399 - m +49-170-4527211 e - w http://www.unixarea.de/ People who hate Microsoft Windows use Linux but people who love UNIX use FreeBSD.