From owner-freebsd-bugs@FreeBSD.ORG Tue Feb 20 15:40:16 2007 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CDDA316A5ED for ; Tue, 20 Feb 2007 15:40:15 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.freebsd.org (Postfix) with ESMTP id C034B13C478 for ; Tue, 20 Feb 2007 15:40:15 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id l1KFeFws057873 for ; Tue, 20 Feb 2007 15:40:15 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id l1KFeFol057869; Tue, 20 Feb 2007 15:40:15 GMT (envelope-from gnats) Date: Tue, 20 Feb 2007 15:40:15 GMT Message-Id: <200702201540.l1KFeFol057869@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Nick Hibma Cc: Subject: Re: bin/109334: pkg_add using chroot exits with error if wrong directory X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Nick Hibma List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Feb 2007 15:40:16 -0000 The following reply was made to PR bin/109334; it has been noted by GNATS. From: Nick Hibma To: Remko Lodder Cc: FreeBSD-gnats-submit@FreeBSD.org Subject: Re: bin/109334: pkg_add using chroot exits with error if wrong directory Date: Tue, 20 Feb 2007 16:34:17 +0100 (CET) Remko, nick@hind:/usr/obj/nanobsd.koole.ship-2.4 % cd /tmp/ nick@hind:/tmp % mkdir somedir nick@hind:/tmp % cd somedir/ nick@hind:/tmp/somedir % export PKG_DBDIR=/pkgdb nick@hind:/tmp/somedir % export PKG_PATH=/packages nick@hind:/tmp/somedir % sudo pkg_add -C /usr/obj/nanobsd.koole.ship-2.4/_.w /packages/mpd-3.18_5.tbz pkg_add: leave_playpen: can't chdir back to '/tmp/somedir' nick@hind:/tmp/somedir % echo $? 2 nick@hind:/tmp/somedir % ls -l /usr/obj/nanobsd.koole.ship-2.4/_.w/usr/local/sbin/mpd -r-xr-xr-x 1 root wheel 220084 Jan 19 02:35 /usr/obj/nanobsd.koole.ship-2.4/_.w/usr/local/sbin/mpd The error happens at the very end. The package gets installed correctly but the error code is still set. Nick > Hello, > > Can you paste me the error message you get? Since it appears to me that > the chroot option should just change the entire root to > $whatever_was_defined at that moment instead of the pwd at the time of > issueing the command :) > > Thanks&Cheers, > remko >