From owner-freebsd-virtualization@freebsd.org Fri Feb 16 01:00:23 2018 Return-Path: Delivered-To: freebsd-virtualization@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1ECFEF047F3; Fri, 16 Feb 2018 01:00:23 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DE8CD796D6; Fri, 16 Feb 2018 01:00:19 +0000 (UTC) (envelope-from tech-lists@zyxst.net) Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id F1E9420D7D; Thu, 15 Feb 2018 20:00:18 -0500 (EST) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Thu, 15 Feb 2018 20:00:18 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zyxst.net; h=cc :content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm1; bh=Lf/pY97HnoU5QTlCncOgVnA729ais0izgQ78X2Hd+jA=; b=gvBifQfS oLPAZuOVTo/bjBG5/GZ1T+zadvv4HOb3GRDbM7vIGpntNlLH5a3jK7dXFO1HiTjf g+YhcvVTkTTuz+NS5FXffFyA3OgBfidhcoz7oqjlIa20GyV6fUMO5x8iSAAsrjL9 3WsffI/MQYNEWpMTuti5Fp2g9tCGR4forLyHiTtyhLFJ4wDTp487B3x3zSNEbQJc SvuJm3274LDSYHP41etWgp+awDoRqxurPSl43YCVDP5JxzTsuStvfnAgxIkyy1VP iUCzuLdzxEXNw5hjz6LiO94iG3fmHLei7ybQa+dt5j0/zLRPSGP49DLmTkwtjnxq qJZ2cPoQWvM+Pw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:message-id:mime-version:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm2; bh=Lf/pY97HnoU5QTlCncOgVnA729ais 0izgQ78X2Hd+jA=; b=BvCrdwc0vSbiYd7bbur/N6V8x0qwcaqj3prhUJAfybteS VDHvG5bIwvP2dANcElRipGk+7QrER+mfnbgCPIU2AfUAGXCFyKtk0WdFYHhBZwtN 9aRzzN9jv4roHcpU2Lei96lWA5C4XaYKlrGcMGSwfXRXtjabMatFvHWap4XnUkXy hTZ6l45fxXZEwFTaVz1STLWFcPqnu3RG8q94a0jolsbjYsjzDykQ5eKsvdo7IyGF s1e4oJBThkh/BevsClIbfjKgKMi82MaRBgBBrvfxpim41DqfKNihFKiW7ZtcuTYW 1T2f9VdCfjiCxlrkRtd3DQfVzufdmXpwnXzCak1AQ== X-ME-Sender: Received: from desktop.parsley.growveg.org (parsley.growveg.org [82.70.91.97]) by mail.messagingengine.com (Postfix) with ESMTPA id 7DE80246D0; Thu, 15 Feb 2018 20:00:18 -0500 (EST) From: tech-lists Subject: is it possible to chroot into arm64 from amd64? To: freebsd-virtualization@freebsd.org Cc: freebsd-stable@freebsd.org Message-ID: <30cfa8a3-76e4-73ac-3b2a-2d64ed24aef8@zyxst.net> Date: Fri, 16 Feb 2018 01:00:16 +0000 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Language: en-US Content-Transfer-Encoding: 8bit X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.25 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: Fri, 16 Feb 2018 01:00:23 -0000 Hi, Is it possible to have on an amd64 system, a chrooted or jailed arm64 environment? It's possible to cross-compile an arm6 environment on amd64 and then chroot into the arm6 environment - is the same possible for arm64? I can cross-compile arm64 like this: # SYSROOT=/crossbuild/arm64 # cd /usr/src # make -j32 TARGET=arm64 TARGET_ARCH=aarch64 buildworld # make DESTDIR=$SYSROOT TARGET=arm64 TARGET_ARCH=aarch64 installworld # make DESTDIR=$SYSROOT TARGET=arm TARGET_ARCH=armv6 distribution # cp /usr/local/bin/qemu-aarch64-static $SYSROOT/sbin # /usr/sbin/binmiscctl add arm64 --interpreter "/usr/local/bin/qemu-aarch64" \ --magic "\x7f\x45\x4c\x46\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00" \ --mask "\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff" \ --size 20 --set-enabled # mount -t devfs devfs ${DESTDIR}/dev then: # chroot -u root $SYSROOT then I get the following error: chroot: /bin/csh: No such file or directory # so looked at the chroot, and bin/csh is there! # ls -lah $SYSROOT/bin |less total 9144 drwxr-xr-x 2 root wheel 1.0K Feb 16 00:43 . drwxr-xr-x 18 root wheel 512B Feb 16 00:44 .. -r-xr-xr-x 2 root wheel 195K Feb 16 00:43 [ -r-xr-xr-x 1 root wheel 195K Feb 16 00:43 cat -r-xr-xr-x 1 root wheel 195K Feb 16 00:43 chflags -r-xr-xr-x 1 root wheel 195K Feb 16 00:43 chio -r-xr-xr-x 1 root wheel 195K Feb 16 00:43 chmod -r-xr-xr-x 1 root wheel 195K Feb 16 00:43 cp -r-xr-xr-x 2 root wheel 451K Feb 16 00:43 csh what am I doing wrong? -- J.