From owner-freebsd-pkg@FreeBSD.ORG Wed May 7 21:07:10 2014 Return-Path: Delivered-To: pkg@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id C4F7C58B for ; Wed, 7 May 2014 21:07:10 +0000 (UTC) Received: from mail-lb0-x22f.google.com (mail-lb0-x22f.google.com [IPv6:2a00:1450:4010:c04::22f]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4EE2CE55 for ; Wed, 7 May 2014 21:07:10 +0000 (UTC) Received: by mail-lb0-f175.google.com with SMTP id l4so2220694lbv.6 for ; Wed, 07 May 2014 14:07:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=6nyM/BnxCvrQnaxTO3SeyuFklZxtwpWpRyCyXYXJSFY=; b=tk2O2u84Drk20W8LAvDAA7RqVuDfXA5bcZtSSS4tfw0a3g/KEDXBMUvcO6jsv78rEH omuWddTuj8ZZDeYA3XKRZ0pTwZZ2sMQTA9gmGvXU1z3md6G/haqLn5FwUsNrOT+v8oBH Zynah969FG2ZDz2lhwkdwWAAOpIWDbZXsVKBfSkWdiYgdHU5cSEyMDQnCylmPu/4YD+4 5I6Eml40bZNk3tfcw6XNFj7E5xAG45J4hmdIQNN1PFsT+5qDy62tB5hy71hyQP637iGi RYlE5f7L++OdjDKozuamjppVMsyhEUTPIXOZoAMz1N/YhS/FH3Dy3FV+feMNzk555I6b SdvA== MIME-Version: 1.0 X-Received: by 10.112.141.130 with SMTP id ro2mr6984809lbb.42.1399496827875; Wed, 07 May 2014 14:07:07 -0700 (PDT) Sender: crodr001@gmail.com Received: by 10.112.67.73 with HTTP; Wed, 7 May 2014 14:07:07 -0700 (PDT) In-Reply-To: <536A9BB5.9080905@a1poweruser.com> References: <5369407E.9060008@a1poweruser.com> <53694241.6050207@my.hennepintech.edu> <536A3E10.4030902@a1poweruser.com> <536A9BB5.9080905@a1poweruser.com> Date: Wed, 7 May 2014 14:07:07 -0700 X-Google-Sender-Auth: 9umQWHeluligLMc0ZbbYcCRsskk Message-ID: Subject: Re: bootstrapping /usr/sbin/pkg inside a jail From: Craig Rodrigues To: Fbsd8 Content-Type: text/plain; charset=ISO-8859-1 Cc: pkg X-BeenThere: freebsd-pkg@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Binary package management and package tools discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 May 2014 21:07:10 -0000 On Wed, May 7, 2014 at 1:46 PM, Fbsd8 wrote: > Craig Rodrigues wrote: > Thank you Craig for your work around. But the fact is the bootstrap pkg > program should work from within a jail. This looks like a bug that needs a > PR. /usr/sbin/pkg behaves differently on FreeBSD 9 vs. FreeBSD 10. You can see the source code in /usr/src/usr.bin/pkg/ to see how it works. Before you run /usr/sbin/pkg for the first time, you need to check if any of the following are true in your jail: (1) Is something setting PACKAGESITE in your environment? (2) Do you have any files: /usr/local/etc/pkg.conf /usr/local/etc/pkg/repos/* If any of those things are true, they will affect the behavior of /usr/sbin/pkg. You will need to delete those files and unset the variable, and then apply the workaround at: https://github.com/freenas/freenas/blob/master/build/ports/install-ports.sh#L29 You can try filing a bug against pkg, but the pkg developers might tell you that this is a bootstrapping problem which is fixed in newer versions of FreeBSD. -- Craig