From owner-freebsd-cloud@freebsd.org Wed Apr 12 06:09:54 2017 Return-Path: Delivered-To: freebsd-cloud@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DCBFBD3ACF9; Wed, 12 Apr 2017 06:09:54 +0000 (UTC) (envelope-from tsoome@me.com) Received: from st13p35im-asmtp001.me.com (st13p35im-asmtp001.me.com [17.164.199.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AF270380; Wed, 12 Apr 2017 06:09:54 +0000 (UTC) (envelope-from tsoome@me.com) Received: from process-dkim-sign-daemon.st13p35im-asmtp001.me.com by st13p35im-asmtp001.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OOA00A008R0VS00@st13p35im-asmtp001.me.com>; Wed, 12 Apr 2017 06:09:48 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=me.com; s=4d515a; t=1491977388; bh=0p115GMQaBruqRZfKdORHMJd3AuPBaWwao2zEnj4OQU=; h=Content-type:MIME-version:Subject:From:Date:Message-id:To; b=d/Nu4oMh67OhNPYE7Jwclm9UffNVXnHpxop6ZpfHWOgn/YrLtmKV4x9gB+P/qayJg BYFPLWz5QykwjE0IGGfW50Zi9u2eLvXG8aLjtdQQMdO7PyIu6cPD72+VlxPwfuvDN3 AfeB3mW1cOX6GuNu6tS5kwgUU8ZP9yVGbxBG1YiTFoPpKTX9qWtseK9OaXxChXuFOM cYkuz8b2kMSkxmD/G/MUG/QNIf2YMEj+/zO7xxWkNszHYyQ/PJKWvMb/zSluMEKifH 269Y341DIJwvv7PV3UMw3i3O0zCAGWKwAzK53EuDvXsU4n9QYPj5SGumiHYcybK1j3 u3+bVi9qh2Uvg== Received: from icloud.com ([127.0.0.1]) by st13p35im-asmtp001.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OOA00BF39496U00@st13p35im-asmtp001.me.com>; Wed, 12 Apr 2017 06:09:48 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-04-12_05:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=2 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1701120000 definitions=main-1704120053 Content-type: text/plain; charset=utf-8 MIME-version: 1.0 (Mac OS X Mail 10.3 \(3273\)) Subject: Re: amazon/xen... any way at all to pass a message/signal/semaphoere/morse-code to the boot loader? From: Toomas Soome In-reply-to: <6f1c694d-1bb7-cdcc-daed-fd2e25dc2a28@freebsd.org> Date: Wed, 12 Apr 2017 09:09:45 +0300 Cc: freebsd-cloud@freebsd.org, FreeBSD Lists Content-transfer-encoding: quoted-printable Message-id: <3A0FDF0B-B3CC-4CB7-AF9F-DC7CB60A6B5A@me.com> References: <0100015b6070d24d-a23d7d90-11c0-4065-9bd0-0fc71b5874d6-000000@email.amazonses.com> <6f1c694d-1bb7-cdcc-daed-fd2e25dc2a28@freebsd.org> To: Julian Elischer X-Mailer: Apple Mail (2.3273) X-BeenThere: freebsd-cloud@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "FreeBSD on cloud platforms \(EC2, GCE, Azure, etc.\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Apr 2017 06:09:55 -0000 > On 12. apr 2017, at 9:04, Julian Elischer wrote: >=20 > On 12/4/17 12:34 pm, Colin Percival wrote: >> [CCing freebsd-cloud, which is the right place for discussions of = FreeBSD/EC2] >>=20 >> On 04/11/17 21:03, Julian Elischer wrote: >>> In Amazon ec2 they have no console access (though I heard rumors = that it was >>> available I have not seen any sign of it) so I'd like to put a = "recovery >>> partition" into an AMI. >>> The trick is how to convince it to boot to that instead of the = regular action. >> Can you get what you want via gptboot's support for selecting the = partition >> to boot via "bootonce" and "bootme" flags? > not if you can't get onto to the machine. > When I talk about a recovery partition I mean it in the same way that = apple means it.. > "system won't boot? press the power button and hold down the 'option' = key. > it will give you the option to boot to a recovery mode" > (* actually I can't remember the keys but you get the idea..) >=20 > in our case we would like to be able to recover a customer's AMI by = giving a simple set of instructions over the phone. > We can assume they know how to get into the amazon menus, but we would = like to not have to assume much more. >=20 >>=20 >>> The ideal thing would be if there was way to 'influence' one of the = smbios >>> values in some way, and have the boot code see it, but I'm open to = any >>> suggestions. >>> I really need only 1 bit of information to get through. >>>=20 >>> Possibilties include "changing the VM to have only 2G of ram" (we'd = never do >>> that in a real machine). >>> or maybe temporarily removing all the disks other than the root = drive? Almost >>> anything I could do to signal the boot code to behave differently. >> I don't think adding/removing disks will be useful, since the extra = disks will >> be Xen blkfront devices; AFAIK the boot loader doesn't know anything = about >> these. (The boot device is also a blkfront device but gets ATA = emulation for >> the benefit of boot loaders.) >>=20 >> Maybe you can repurpose some of the logic used for booting over NFS? = I've >> never heard of people booting over NFS when the initial bootstrap = comes from >> disk rather than PXE, but I assume it's possible...? >=20 > Oh I've done it, in the past but you still have the same issue.. > how do you signal the boot code to do this? >=20 > (does an AMI have a bios capable of doing network operations?) I was = thinking > about whether we could add a really simple xn driver into the bootcode = to allow > us to have an console of sorts (accessible from an adjacent machine = only??) >=20 >=20 >=20 basically you want what zfsbootcfg does but in reverse =E2=80=94 with = fallback to recovery=E2=80=A6 rgds, toomas