From owner-freebsd-questions@FreeBSD.ORG Thu May 14 16:31:53 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 17FCD1065675 for ; Thu, 14 May 2009 16:31:53 +0000 (UTC) (envelope-from rsmith@xs4all.nl) Received: from smtp-vbr3.xs4all.nl (smtp-vbr3.xs4all.nl [194.109.24.23]) by mx1.freebsd.org (Postfix) with ESMTP id A0D5D8FC0A for ; Thu, 14 May 2009 16:31:52 +0000 (UTC) (envelope-from rsmith@xs4all.nl) Received: from slackbox.xs4all.nl (slackbox.xs4all.nl [213.84.242.160]) by smtp-vbr3.xs4all.nl (8.13.8/8.13.8) with ESMTP id n4EGVorG038701; Thu, 14 May 2009 18:31:50 +0200 (CEST) (envelope-from rsmith@xs4all.nl) Received: by slackbox.xs4all.nl (Postfix, from userid 1001) id 89309BA8B; Thu, 14 May 2009 18:31:50 +0200 (CEST) Date: Thu, 14 May 2009 18:31:50 +0200 From: Roland Smith To: "marco.borsatino@poste.it" Message-ID: <20090514163150.GA56105@slackbox.xs4all.nl> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="TB36FDmn/VVEgNH/" Content-Disposition: inline In-Reply-To: X-GPG-Fingerprint: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 X-GPG-Key: http://www.xs4all.nl/~rsmith/pubkey.txt X-GPG-Notice: If this message is not signed, don't assume I sent it! User-Agent: Mutt/1.5.19 (2009-01-05) X-Virus-Scanned: by XS4ALL Virus Scanner Cc: freebsd-questions@freebsd.org Subject: Re: virtual network with qemu X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 May 2009 16:31:53 -0000 --TB36FDmn/VVEgNH/ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, May 14, 2009 at 07:53:32AM +0200, marco.borsatino@poste.it wrote: > Hi to all. > I'd like to implement a little virtual network using QEMU 0.10.2, but, un= til now, I have failed. > This is the situation. > Host: AMD 64 running FreeBSD 7.2 > #ifconfig > nfe0: flags=3D8843 metric 0 mtu 1= 500 > options=3D10b > ether 00:15:f2:44:2d:f9 > inet 192.168.0.2 netmask 0xffffff00 broadcast 192.168.0.255 > media: Ethernet autoselect (100baseTX ) > status: active > plip0: flags=3D108810 metric 0 = mtu 1500 > lo0: flags=3D8049 metric 0 mtu 16384 > inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3=20 > inet6 ::1 prefixlen 128=20 > inet 127.0.0.1 netmask 0xff000000=20 > I've create an image using the FreeBSD 7.2 DVD: > #qemu-img create -f qcow2 hda fbsd72.img 10G > The image has been created. > #qemu -L /usr/local/share/qemu/ -cdrom /dev/acd0 -m 512 -boot d fbsd72.img > Alfter a long time, the installation of the guest system has been complet= ed. It would probably be faster to use a FreeBSD ISO image instead of the real CD drive.=20 > When the installation program asked for information about network > configuration, as a first step, I chose DHCP configuration and, as > usualy, the network has been set like this: > IP 10.0.2.15/255.255.255.0 > gateway 10.0.2.2 > nameserver 10.0.2.3 > > When the installation of the guest PC was finished, I've copied the=20 > image to pc01.img, to keep the original untouched. After that I've starte= d qemu like this: > #qemu -L /usr/local/share/qemu -localtime -net nic,macaddr=3D00:15:f2:44:= 2d:01 -net socket,mcast=3D230.0.0.1:1234 -hda pc01.img -cdrom /dev/acd0 & > but the network in the guest system does not work. Try the following command instead: qemu -L /usr/local/share/qemu -localtime -net nic -net user -hda pc01.img Roland --=20 R.F.Smith http://www.xs4all.nl/~rsmith/ [plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated] pgp: 1A2B 477F 9970 BA3C 2914 B7CE 1277 EFB0 C321 A725 (KeyID: C321A725) --TB36FDmn/VVEgNH/ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.11 (FreeBSD) iEYEARECAAYFAkoMR3YACgkQEnfvsMMhpyVdlACgkeI6kpmFCpbxWQGmGU6Qni81 xo4Ani5/pFZndL9cMXA2G9ylSjFkWWqV =hiPH -----END PGP SIGNATURE----- --TB36FDmn/VVEgNH/--