From: Ian Jackson Subject: Re: [PATCH RFC 2/4] osstest: add support for installing bare metal FreeBSD Date: Tue, 12 Aug 2014 17:42:32 +0100 Message-ID: <21482.17400.370008.962884@mariner.uk.xensource.com> References: <1407858572-32140-1-git-send-email-roger.pau@citrix.com> <1407858572-32140-3-git-send-email-roger.pau@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XHF9j-0005O7-D7 for xen-devel@lists.xenproject.org; Tue, 12 Aug 2014 16:42:39 +0000 In-Reply-To: <1407858572-32140-3-git-send-email-roger.pau@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Roger Pau Monne Cc: xen-devel@lists.xenproject.org List-Id: xen-devel@lists.xenproject.org Roger Pau Monne writes ("[PATCH RFC 2/4] osstest: add support for installing bare metal FreeBSD"): > This is done using mfsBSD, which can be booted from pxelinux and > contains a script to automatically install FreeBSD using ZFS on root. > After the install the host is set to boot from the local disk. ... > +# TODO: all this should be runvars > +our $version = '10.0-RELEASE'; > +our $ftp = 'ftp.freebsd.org'; Does this mean that this script will fail if ftp.freebsd.org is down ? Is there a way of avoiding that ? We try to keep to a minimum the number of different servers that osstest's production instance depends on. > +# TODO: this has to be set on a per-host basis. > +# It should probably come from $ho? > +our $disk = 'da0'; > +our $nic = 'bce0'; Does this mean that this has to be manually configured, rather than detected ? It could be a host property but really it would be better not to have to set these kind of freebsd-specific host properties. > + target_cmd_root_with_password($ho, < + mkdir -p ~/.ssh Missing `set -e'. (Throughout.) > + logm('Setting up serial console'); > + target_cmd_root($ho, < + echo "-Dh" >> /mnt/boot.config Does FreeBSD's echo really simploy print things that look like options ? I would use printf(1). > + # Remove the known hosts file, since the keys will be regenerated after > + # rebooting into the installed system > + unlink "tmp/t.known_hosts_$flight.$job"; Can you instead arrange for the fixed keys to be installed on the host ? Otherwise manually sshing into these test boxes is very annoying because the ssh keys keep changing. Thanks, Ian.