From owner-freebsd-pkg@freebsd.org Wed Apr 26 07:32:30 2017 Return-Path: Delivered-To: freebsd-pkg@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 B77E3D51B7B for ; Wed, 26 Apr 2017 07:32:30 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from smtp.infracaninophile.co.uk (smtp.infracaninophile.co.uk [IPv6:2001:8b0:151:1:c4ea:bd49:619b:6cb3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.infracaninophile.co.uk", Issuer "infracaninophile.co.uk" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 5F539D8E for ; Wed, 26 Apr 2017 07:32:30 +0000 (UTC) (envelope-from matthew@FreeBSD.org) Received: from liminal.local (unknown [IPv6:2001:8b0:151:1:1c1d:86a1:a200:b700]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: m.seaman@infracaninophile.co.uk) by smtp.infracaninophile.co.uk (Postfix) with ESMTPSA id B030BC932 for ; Wed, 26 Apr 2017 07:32:21 +0000 (UTC) Authentication-Results: smtp.infracaninophile.co.uk; dmarc=none header.from=FreeBSD.org Authentication-Results: smtp.infracaninophile.co.uk/B030BC932; dkim=none; dkim-atps=neutral Subject: Re: Help please... Upgrade to pkg no workie To: freebsd-pkg@freebsd.org References: <83939.1493156094@segfault.tristatelogic.com> From: Matthew Seaman Message-ID: <89617edf-9411-2d3e-2f3c-4cab1e530bfd@FreeBSD.org> Date: Wed, 26 Apr 2017 08:32:15 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <83939.1493156094@segfault.tristatelogic.com> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="GgXFVnlHoSSaDcNN1u2K2rnUMvp6Lk6gA" X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00,RDNS_NONE, SPF_SOFTFAIL autolearn=no autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on smtp.infracaninophile.co.uk X-BeenThere: freebsd-pkg@freebsd.org X-Mailman-Version: 2.1.23 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, 26 Apr 2017 07:32:30 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --GgXFVnlHoSSaDcNN1u2K2rnUMvp6Lk6gA Content-Type: multipart/mixed; boundary="4xnSkGfFIhISEtfT9qxhNP2uMlrLoqIq9"; protected-headers="v1" From: Matthew Seaman To: freebsd-pkg@freebsd.org Message-ID: <89617edf-9411-2d3e-2f3c-4cab1e530bfd@FreeBSD.org> Subject: Re: Help please... Upgrade to pkg no workie References: <83939.1493156094@segfault.tristatelogic.com> In-Reply-To: <83939.1493156094@segfault.tristatelogic.com> --4xnSkGfFIhISEtfT9qxhNP2uMlrLoqIq9 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 25/04/2017 22:34, Ronald F. Guilmette wrote: >=20 > This is rather embarassing, but OK, I confess... One of my > systems here is running the ancient FreeBSD 9.1 and it hasn't > been upgraded in a long long time. Like not at all. No package > updates, nothing. Today however I desperately need to upgrade > the installed Perl. (Apparently, the Perl that I have installed > on this system, v5.16, has an old and not at all up-to-date Unicode > implementation.) Given how many packages you tend to have that depend on perl, in this situation my advice would be to punt on this system entirely, and build a new 11.0 setup to fulfil the same functions. Even if you have to buy a new hard drive to install the 11.0 system on within the same chassis. > As you all know, fBSD 9.1 used the older package system. I am well and= > truly aware of the fact that, in order to move forward, I will need > to upgrade to the new package system (pkg). So I've been reading this > page that purports to give directions on exactly how to do that: It's not just pkg that you're going to have problems with when running such an old system. The ports tree hasn't supported FreeBSD 9.x since 9.3-RELEASE went out of support at the end of December, and lots of compatibility hacks have since been dyked out. > https://www.freebsd.org/doc/handbook/pkgng-intro.html >=20 > Unfortunately, for me at least, the guidance here raises nearly > as many questions as it answers. For example, it says to do these > two things: >=20 > 1) Run pkg2ng. This converts the existing pkg_tools /var/db/pkg into the package database used by pkg(8) > 2) Put a line like "WITH_PKGNG=3Dyes" into /etc/make.conf This tells the ports to use pkg(8) rather than pkg_tools. I'm not sure if this variable still does anything with a current ports tree -- pkg(8) is assumed nowadays. Even so, both of these steps should be taken before trying to use the ports with pkg(8), but it doesn't really matter what order you do them in= =2E > What it doesn't say is whether the first thing must be done strictly > *before* the second thing, or vise versa, or if the order here even > matters at all. (I don't want to totally screw up my system, so in > the absence of complete clarity, and since I don't really know exactly > what the effects of either of these two steps really are, I am inclined= > to proceed with great caution and thus requast clarification from this > list.) >=20 > Anyway, I decided to look and see if perchance I might already have > the new & improved pkg command on my system. So I did "which pkg" > and lo and behold, an executable with that name is already present > on this system as /usr/sbin/pkg. (I have no clear recollection, one > way or the other, whether or not, in years past, I may have deliberatel= y > installed this /usr/sbin/pkg or not.) /usr/sbin/pkg is pkg(7). It's a small shim that serves to download and install the up-to-date pkg(8). Which isn't going to work, as there isn't a FreeBSD-9.x version of pkg(8) or even a FreeBSD-9.x package repo available today. > Anyway, I decided to throw the dice and run this, with no options or > arguments, just to see if that would give me a list of command line > options or what. I was almost immediately greeted with a message > saying that the new pkg system was *not* in fact actually installed > and asking me ([y/N]) if I wanted to install it. I control-C'd out > of this, before I did any damage, and plotted my next move. >=20 > I realized that to actually install this thing, I'd probably need to be= > root, so I su'd to root and then cd'd to ~root and started "script" so > that I'd have a full log in case anything went wrong... which it > promptly did. Here's the log. It isn't pretty. >=20 > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > root@segfault:/root # pkg > The package management tool is not yet installed on your system. > Do you want to fetch and install it now? [y/N]: y > Bootstrapping pkg please wait > Installing pkg-1.9.4_1... > pkg-static: dup2(rootfd): Invalid argument > Extracting pkg-1.9.4_1: 0% > pkg-static: Fail to create /usr: Bad file descriptor > Extracting pkg-1.9.4_1: 100% >=20 > Failed to install the following 1 package(s): /tmp//pkg.txz.q9abRX > root@segfault:/root # exit > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D >=20 > So? NOW what should I do? What you would need to do is build pkg from source via the ports-mgmt/pkg port > Any & all advice appreciated. >=20 > (I still desperately need to get Perl upgraded.) Like I said, in the end you'll find it a lot easier and more productive to start from a fresh install on a blank system and recreate the functionality of your server from scratch. Cheers, Matthew --4xnSkGfFIhISEtfT9qxhNP2uMlrLoqIq9-- --GgXFVnlHoSSaDcNN1u2K2rnUMvp6Lk6gA Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQJ8BAEBCgBmBQJZAE0FXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NTNBNjhCOTEzQTRFNkNGM0UxRTEzMjZC QjIzQUY1MThFMUE0MDEzAAoJELsjr1GOGkATRL8P/0OU9YMuJcIwlmNUl5+Fonyr jIim0NiEhHFKyMRcOTDuPPcrgPksZswR6h6E3a83uDhigy9Oe6L4qYYZjm7nT+ys oz/V8pdP9QRz/voNUok0XXBmKEeHmaM5+LFClWPlryDy1OtujyagGcS7no9ktQ3y vXrdD15cFtFL3pBe8AgnGad5SymySS+rR7FJ6yQiHcu5KQRmp0h7Z8VeotM88byD 1qc5PvKKkfs346ML6INsNdQwoJ7TRCLGi2ks+tPjHBv++HSl9BJToD1Jejq+GUxN 3MOaHXAZFQN7+4T7ys7RIhaCLUOKuIBoc2SFM4R4TMDlamc0UH699JtJvCJgswYZ oFgDspoHNpFP1TecvCrZyUL4NCW3p8cxYCbOWoYMcgQcSspFE1tue7eHQTfZve2D 4+2eTgiw3bQZDvBtxNQ/QYYeKiGOGSd99XDVtJwOOlmBurMrJPkS3uY9gBSV43UA VTPo70WbQxupi97eFQIEb9/kGyzpUjtT29OUWlx910RHe86CgEIIY9HXGZHt8H17 k2MUMXLZrRxL/1tjDYJXb64yT6UC7fysYz3DREBq7HGrjHdt1SbflU4zbNT6GyEO JW6VCY44tzZ2skt9wt9sD9kbJ2HnOXGcV9kQ8bzcV9UFRXq1japIQgKW24gsAgNJ Ad8iaDGAupHydY6cC7YQ =g45Y -----END PGP SIGNATURE----- --GgXFVnlHoSSaDcNN1u2K2rnUMvp6Lk6gA--