From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by nuthatch.gentoo.org with esmtp (Exim 4.43) id 1ECutZ-00058K-CY for garchives@archives.gentoo.org; Wed, 07 Sep 2005 08:03:01 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.13.4/8.13.4) with SMTP id j877vFYg021687; Wed, 7 Sep 2005 07:57:15 GMT Received: from gaia.prhnet (84-12-164-225.dyn.gotadsl.co.uk [84.12.164.225] (may be forged)) by robin.gentoo.org (8.13.4/8.13.4) with ESMTP id j877vEJN032098 for ; Wed, 7 Sep 2005 07:57:14 GMT Received: (qmail 20696 invoked from network); 7 Sep 2005 08:00:42 +0000 Received: from wstn.home (HELO ?192.168.129.25?) (192.168.129.25) by gaia.prhnet with SMTP; 7 Sep 2005 08:00:42 +0000 Message-ID: <431E9E29.70308@gotadsl.co.uk> Date: Wed, 07 Sep 2005 09:00:41 +0100 From: Peter Humphrey User-Agent: Mozilla Thunderbird 1.0.6 (X11/20050803) X-Accept-Language: en-us, en Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-amd64@gentoo.org Reply-to: gentoo-amd64@lists.gentoo.org MIME-Version: 1.0 To: gentoo-amd64@lists.gentoo.org Subject: Re: [gentoo-amd64] Re: Installing into a 32-bit chroot? References: <200509041702.07690.prh@gotadsl.co.uk> <1126037681.10070.47.camel@thor.tres.org> In-Reply-To: <1126037681.10070.47.camel@thor.tres.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Archives-Salt: 133a1198-fa69-49b9-8f70-dc55a9866ac1 X-Archives-Hash: 04891de113c6d33bc3a73d97c36996f8 Tres Melton wrote: > Somewhere in this thread is the mention of ssh to run a 32 bit program. > That is a poor solution in my opinion. The suggestion was made to mount > the /tmp dirs and other things and I do this at boot. Further I have > written a program that will allow any user (approved by the sudoers file > in the chroot and the regular root) to run any program from wherever > they are without the headache of becoming root, etc.. Here ya go: > > #!/bin/bash > # > # Written and Copyright by Tres Melton (2005) > # > # Run a 32 bit program from 64 bit space > # > # If parameters given then execute the command instead of /bin/bash > # If no parameters then create a new 32 bit chroot jail shell > # > > JAIL_DIR="/mnt/sdb3/Gentoo-32" > > if [ $# -eq 0 ] ; then > echo "Starting 32 bit shell..." > /bin/linux32 sudo chroot ${JAIL_DIR} /usr/bin/sudo -u "#${UID}" bash -c "( cd ~ ; /bin/bash )" > else > echo "Starting a 32 bit shell to run \"$*\"" > /bin/linux32 sudo chroot ${JAIL_DIR} /usr/bin/sudo -u "#${UID}" bash -c "( cd ~ ; $* )" > fi > > Hope that helps some. Regards, Certainly does - thanks Tres. -- Rgds Peter Humphrey Linux Counter 5290, Aug 93. -- gentoo-amd64@gentoo.org mailing list