Date: Tue, 21 Apr 2015 09:33:02 -0400 From: Dan Langille <dan@langille.org> To: Ben Woods <woodsb02@gmail.com> Cc: ports <freebsd-ports@freebsd.org> Subject: Re: pkg-static: Insufficient privileges to add packages Message-ID: <7A1D4136-BBEF-4726-B1E2-51CF3DD285C2@langille.org> In-Reply-To: <CAOc73CD0XREAW0O_pMp7nB2vqE-MoHAAbKsYcLQcT0PC6jT%2BVA@mail.gmail.com> References: <31714E44-6041-4B5F-BDB0-FA7131ED7EB4@langille.org> <CAOc73CCDGjyzio6z7F1PQ0ttwrmFtbvHz1s7w-TWi5aKLoyb1A@mail.gmail.com> <CAOc73CD0XREAW0O_pMp7nB2vqE-MoHAAbKsYcLQcT0PC6jT%2BVA@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--Apple-Mail=_BDEB6E0A-A6F5-4C18-870F-84386D5F578C Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 This reply has been rearranged.. On Tue, Apr 21, 2015 at 6:56 AM Ben Woods <woodsb02@gmail.com = <mailto:woodsb02@gmail.com>> wrote: > On Apr 20, 2015, at 7:18 PM, Ben Woods <woodsb02@gmail.com> wrote: > On Tue, Apr 21, 2015 at 4:02 AM Dan Langille <dan@langille.org = <mailto:dan@langille.org>> wrote: > I am running a testport on www/py-django-tastypie >=20 > My goal it to add an option for using www/django16 as well as = www/django (1.7). >=20 > The error I get is: >=20 > $ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o = www/py-django-tastypie > ... > =3D=3D=3D> Verifying install for py27-django>=3D1.5 in = /usr/ports/www/py-django16 > =3D=3D=3D> Installing existing package = /packages/All/py27-django16-1.6.11.txz > pkg-static: Insufficient privileges to add packages >=20 > But because I'm running testport interactively, I see I can install = the port it mentions: >=20 > root@101amd64-testing-testing:~ # pkg install = /packages/All/py27-django16-1.6.11.txz > Updating local repository catalogue... > [101amd64-testing-testing] Fetching meta.txz: 100% 816 B 0.8kB/s = 00:01 > [101amd64-testing-testing] Fetching packagesite.txz: 100% 50 KiB = 51.4kB/s 00:01 > Processing entries: 100% > local repository update completed. 205 packages processed. > Updating database digests format: 100% > Checking integrity... done (0 conflicting) > The following 1 package(s) will be affected (of 0 checked): >=20 > New packages to be INSTALLED: > py27-django16: 1.6.11 >=20 > The process will require 27 MiB more space. >=20 > Proceed with this action? [y/N]: y > [101amd64-testing-testing] [1/1] Installing py27-django16-1.6.11... > [101amd64-testing-testing] [1/1] Extracting py27-django16-1.6.11: 100% > root@101amd64-testing-testing:~ # >=20 >=20 > Why does the testport fail? >=20 > Full build log here: = http://services.unixathome.org/poudriere/data/101amd64-testing-testing/201= 5-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log = <http://services.unixathome.org/poudriere/data/101amd64-testing-testing/20= 15-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log> > That error is generated in the pkg exec_add function in src/add.c = here: > https://github.com/freebsd/pkg/blob/master/src/add.c = <https://github.com/freebsd/pkg/blob/master/src/add.c> >=20 > It occurs because it checks the package database for read, write, = create access using the pkgdb_access and pkgdb_check_access functions in = libpkg/pkgdb.c here: > https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c = <https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c> >=20 > I believe this is inside the jail created by poudriere testport. It = would be interesting to add the -i interactive flag to the testport run = and check the permissions on/in the pkg database. Mine are here for = reference: > % ls -lah /var/db/pkg/ > total 37484 > drwxr-xr-x 2 root wheel 8B 21 Apr 06:00 . > drwxr-xr-x 13 root wheel 19B 21 Apr 06:13 .. > -rw-r--r-- 1 root wheel 246B 4 Dec 06:22 FreeBSD.meta > -rw-r--r-- 1 root wheel 11M 21 Apr 06:00 local.sqlite > -rw-r--r-- 1 root wheel 246B 21 Apr 03:05 poudriere.meta > -rw-r--r-- 1 root wheel 49M 4 Dec 06:22 repo-FreeBSD.sqlite > -rw-r--r-- 1 root wheel 1.6M 21 Apr 03:05 repo-poudriere.sqlite > -r--r--r-- 1 root wheel 3.3M 21 Apr 03:17 vuln.xml >=20 > Regards, > Ben >=20 >=20 > Hand on a minute.... now my poudriere system is doing the same thing - = looks like we have a bug somewhere. >=20 > I am running pkg 1.5.1 and poudriere 3.1.4. According to freshports, = pkg was updated on 16th April, and poudriere on 10th April. >=20 > Inside my poudriere testport jail (using the -i interactive mode = flag), I have: > # ls -lah /var/db/pkg/ > total 7953 > drwxr-xr-x 2 root wheel 3B Apr 20 23:17 . > drwxr-xr-x 12 root wheel 14B Apr 20 23:17 .. > -rw-r--r-- 1 root wheel 7.7M Apr 20 23:17 local.sqlite >=20 > Thoughts? >=20 Here's what I have: Edit /etc/motd to change this login announcement. root@101amd64-testing-testing:~ # ls -lah /var/db/pkg/ total 2991 drwxr-xr-x 2 root wheel 3B Apr 21 13:28 . drwxr-xr-x 10 root wheel 12B Mar 14 19:18 .. -rw-r--r-- 1 root wheel 2.8M Apr 21 13:28 local.sqlite root@101amd64-testing-testing:~ # =E2=80=94 Dan Langille http://langille <http://langille/>.org/ --Apple-Mail=_BDEB6E0A-A6F5-4C18-870F-84386D5F578C Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=signature.asc Content-Type: application/pgp-signature; name=signature.asc Content-Description: Message signed with OpenPGP using GPGMail -----BEGIN PGP SIGNATURE----- Comment: GPGTools - http://gpgtools.org iQJ8BAEBCgBmBQJVNlGYXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ1MTE2RjM0ODIzRDdERDM4OTY0OUJBNzdF QjIxNTlERUU5NzI3MzlGAAoJEOshWd7pcnOfMAIQAMRAEqagV6qpBUcC4P11Ekjx Qzqe+H2Ft9r7GD6wzOyYlsQTt6y7DPzCQ7GOJpgnpDv1XudoL9n54LUFgYzrE4k9 r+VcSVVkyqutPf0SKEg3Py9HM0uy+HAnD9Qi3+AYzv1+0Pmtm1QD05/8cKIxUKW5 jdMWXvUG45bfm24U1udm1hL39HZAVvRKvSvu6Y9mzLysFrKWomDxJkEYKbh7ktsT VTGjVy4CSslTCGOeETOitAvY22B9EPEj2B6FPEy6B7jSCHRILmCJh+hWWDgKMyaF IdEY8UXlQ5TKvrHgEdQ+T/4TLmsVTKisYN/yMagXtO/OFUBDl4R3oJicCtTm5qKU VB/sODc8KodC1AkrCj4qHBNeyY+OaRUK/Jp9THIzRWzWX63hcHGg2DnvXsIqQeC9 dYO9QlkX8EF9paXM8e+F0kOTK0OoayZCXk6tzRaLS9Shg/yc/vFp/pyi5Baw66ky I+P0Yu8Ttl99rqq/dyAitAQ15/oupXIHL1zXoIiiPv16nYt4e8blGTZF2N9hbD0w 9gU/SIjCLfKPJNwE7iMqdq2S7b9W04wDvmaz8vOw0uf1nck4BkKFnbZdqgNcMV7/ 7b1Ui0m9WBxC6HYUhD1edibqDIgTorhnWhCZlhZpwsa/ueqzKSkXxhY6CkRNr/RQ n18Ukta8RnUO+fRs0OH7 =IPzm -----END PGP SIGNATURE----- --Apple-Mail=_BDEB6E0A-A6F5-4C18-870F-84386D5F578C--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?7A1D4136-BBEF-4726-B1E2-51CF3DD285C2>