From owner-freebsd-virtualization@FreeBSD.ORG Thu Oct 10 23:36:31 2013 Return-Path: Delivered-To: freebsd-virtualization@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 2B7CA99F for ; Thu, 10 Oct 2013 23:36:31 +0000 (UTC) (envelope-from crodr001@gmail.com) Received: from mail-la0-x230.google.com (mail-la0-x230.google.com [IPv6:2a00:1450:4010:c03::230]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id AD06C277A for ; Thu, 10 Oct 2013 23:36:30 +0000 (UTC) Received: by mail-la0-f48.google.com with SMTP id er20so2661019lab.7 for ; Thu, 10 Oct 2013 16:36:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:date:message-id:subject:from:to:content-type; bh=QXJ1TSFPMF9y24ozbiCbUV4IiJxU735EYJrrSloIlEk=; b=Co24dYh1yjkqnIgk8OGmt+R0/gFzfLSRMVeyhLu3LbE+GOLyq281WjTE00zXacgmqw v5IGWCdX0tPCcL2Ln/kXi1q4kJJ6oq5VRiYVsQSP6lj3rHZdjQV5m5iYHoQjetnVD8aN 2WSdrqAHdh60huY66Rj+vIjgLaRpVD/ZjcDCTAQrWkLye6NxsM7aQVdGhXiJvqhaY/3K +hCw5N/I9HG1BeVUkMLBHIo+zdDyG+BvGMmDW00TnE+w7VRIRKEkfsLb853K6WMw14hN 3s5PHVLb/pfBFqZ6ZxMkYNhpvTTWlsZswHc79aIzMywkcishOYUcdNLMN8oXP/8wKMsy wb8g== MIME-Version: 1.0 X-Received: by 10.112.143.3 with SMTP id sa3mr14015614lbb.12.1381448188720; Thu, 10 Oct 2013 16:36:28 -0700 (PDT) Sender: crodr001@gmail.com Received: by 10.112.139.132 with HTTP; Thu, 10 Oct 2013 16:36:28 -0700 (PDT) Date: Thu, 10 Oct 2013 16:36:28 -0700 X-Google-Sender-Auth: oNbl9-Ssdv2T_Bt9JdDuGPEg_Ec Message-ID: Subject: Running FreeNAS under BHyve From: Craig Rodrigues To: "freebsd-virtualization@freebsd.org" Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 10 Oct 2013 23:36:31 -0000 Hi, Here is what I have been doing to run FreeNAS under BHyve. (1) Download latest FreeNAS-9.2.0-ALPHA ISO from: http://sourceforge.net/projects/freenas/files/FreeNAS-nightlies/2013-10-09/x64/ (2) Run this script to set up tap device: ================================================================= #!/bin/sh # Change following to your network interface iface=em0 ifconfig bridge0 create ifconfig tap0 create ifconfig bridge0 addm $iface addm tap0 up sysctl net.link.tap.user_open=1 sysctl net.link.tap.up_on_open=1 ================================================================= (3) Create a 4G disk image: truncate -s 4G /tmp/disk.img (4) Run the FreeNAS installer under BHyve and install it to the disk created in step (3): sh /usr/share/examples/bhyve/vmrun.sh -I FreeNAS-9.2.0-ALPHA-a2fb413-x64.iso -d /tmp/disk.img -m 4096 -t tap0 freenas_vm (5) Once the installer has completed, select Shutdown. (6) In a separate window, kill the vm bhyvectl --destroy --vm=freenas_vm (7) Restart BHyve, but this time, do not boot off the ISO image: sh /usr/share/examples/bhyve/vmrun.sh -d /tmp/disk.img -m 4G -t tap0 freenas_vm If DHCP works, you should be able to access the FreeNAS web GUI using a web browser, via the IP address that the BHyve VM got from DHCP. -- Craig