Discussion:
pkg-static: Insufficient privileges to add packages
(too old to reply)
Dan Langille
2015-04-20 20:02:12 UTC
Permalink
I am running a testport on www/py-django-tastypie

My goal it to add an option for using www/django16 as well as www/django (1.7).

The error I get is:

$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in /usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages

But because I'm running testport interactively, I see I can install the port it mentions:

***@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):

New packages to be INSTALLED:
py27-django16: 1.6.11

The process will require 27 MiB more space.

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%
***@101amd64-testing-testing:~ #


Why does the testport fail?

Full build log here: http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log



—
Dan Langille
http://langille.org/
Ben Woods
2015-04-20 22:57:00 UTC
Permalink
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

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

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

Regards,
Ben
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log

Dan Langille
http://langille.org/
Ben Woods
2015-04-20 23:18:33 UTC
Permalink
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.

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.

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

Thoughts?
Post by Ben Woods
https://github.com/freebsd/pkg/blob/master/src/add.c
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
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
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
% 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
Regards,
Ben
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log

Dan Langille
http://langille.org/
Dan Langille
2015-04-21 13:33:02 UTC
Permalink
This reply has been rearranged..
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in /usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
Full build log here: http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log <http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log>
https://github.com/freebsd/pkg/blob/master/src/add.c <https://github.com/freebsd/pkg/blob/master/src/add.c>
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c <https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c>
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing - looks like we have a bug somewhere.
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.
# 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
Thoughts?
Here's what I have:

Edit /etc/motd to change this login announcement.
***@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
***@101amd64-testing-testing:~ #

—
Dan Langille
http://langille <http://langille/>.org/
Ben Woods
2015-04-21 15:44:01 UTC
Permalink
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
But because I'm running testport interactively, I see I can install the
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log
https://github.com/freebsd/pkg/blob/master/src/add.c
It occurs because it checks the package database for read, write, create
access using the pkgdb_access and pkgdb_check_access functions in
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
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
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.
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.
# 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
Thoughts?
Edit /etc/motd to change this login announcement.
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

Dan Langille
http://langille.org/
For the record, downgrading pkg to 1.4.12 and poudriere to 3.1.2 did
not fix this issue for me.

The port that I am trying to testport on FreeBSD 10.1 is
math/plplot-ada. The testport permission issues do not occur with the
port as it is currently - only after making the changes I have
proposed to math/plplot here:
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=155771&action=diff
Dan Langille
2015-04-21 16:20:38 UTC
Permalink
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
But because I'm running testport interactively, I see I can install the
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log
https://github.com/freebsd/pkg/blob/master/src/add.c
It occurs because it checks the package database for read, write, create
access using the pkgdb_access and pkgdb_check_access functions in
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
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
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.
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.
# 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
Thoughts?
Edit /etc/motd to change this login announcement.
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
—
Dan Langille
http://langille.org/
For the record, downgrading pkg to 1.4.12 and poudriere to 3.1.2 did
not fix this issue for me.
The port that I am trying to testport on FreeBSD 10.1 is
math/plplot-ada. The testport permission issues do not occur with the
port as it is currently - only after making the changes I have
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=155771&action=diff
I am also testing local changes to a port.

The problem occurs on a 10.1 but NOT on a 9.3 jail (both amd64).

Here is the good 9.3 run: http://services.unixathome.org/poudriere/build.html?mastername=93amd64-testing-testing&build=2015-04-21_16h17m45s

Compare that to the failed 10.1 run: Full build log here: http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log

I am using pkg-1.5.1 and poudriere-3.1.4

—
Dan Langille
http://langille.org/
Baptiste Daroussin
2015-04-21 16:34:54 UTC
Permalink
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
But because I'm running testport interactively, I see I can install the
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log
https://github.com/freebsd/pkg/blob/master/src/add.c
It occurs because it checks the package database for read, write, create
access using the pkgdb_access and pkgdb_check_access functions in
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
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
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.
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.
# 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
Thoughts?
Edit /etc/motd to change this login announcement.
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
—
Dan Langille
http://langille.org/
For the record, downgrading pkg to 1.4.12 and poudriere to 3.1.2 did
not fix this issue for me.
The port that I am trying to testport on FreeBSD 10.1 is
math/plplot-ada. The testport permission issues do not occur with the
port as it is currently - only after making the changes I have
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=155771&action=diff
I found the reason for Dan by checking the logs, If I could see your own logs
then I will tell you where you mistake is.

actually you are having poudriere building as a user (internally to the jail)
which is a very good thing as it allows to catch things like this :D)

I mean it is dropping roots priviledges to build, stage and make package.

but still try to install a dependency there, probably because the dependency
line you have in your port is buggy. In dan case he was testing if
py27-django>=1.5 but was refering to the www/py-django16 port which result in a
package named py27-django16 which is not py27-django aka the test will always
fail and the ports tree will try to reinstall again and again even in phases
when it cannot due to lack of priviledges

As a conclusion the bug is in the port you are testing not in pkg, neither in
poudriere.

If you show me the logs of your own build I will tell you what is your mistake.

Best regards,
Bapt
Dan Langille
2015-04-21 16:52:10 UTC
Permalink
Post by Baptiste Daroussin
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as www/django (1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package /packages/All/py27-django16-1.6.11.txz
pkg-static: Insufficient privileges to add packages
But because I'm running testport interactively, I see I can install the
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
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%
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log
https://github.com/freebsd/pkg/blob/master/src/add.c
It occurs because it checks the package database for read, write, create
access using the pkgdb_access and pkgdb_check_access functions in
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
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
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.
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.
# 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
Thoughts?
Edit /etc/motd to change this login announcement.
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
—
Dan Langille
http://langille.org/
For the record, downgrading pkg to 1.4.12 and poudriere to 3.1.2 did
not fix this issue for me.
The port that I am trying to testport on FreeBSD 10.1 is
math/plplot-ada. The testport permission issues do not occur with the
port as it is currently - only after making the changes I have
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=155771&action=diff
I found the reason for Dan by checking the logs, If I could see your own logs
then I will tell you where you mistake is.
actually you are having poudriere building as a user (internally to the jail)
which is a very good thing as it allows to catch things like this :D)
I mean it is dropping roots priviledges to build, stage and make package.
but still try to install a dependency there, probably because the dependency
line you have in your port is buggy. In dan case he was testing if
py27-django>=1.5 but was refering to the www/py-django16 port which result in a
package named py27-django16 which is not py27-django aka the test will always
fail and the ports tree will try to reinstall again and again even in phases
when it cannot due to lack of priviledges
As a conclusion the bug is in the port you are testing not in pkg, neither in
poudriere.
If you show me the logs of your own build I will tell you what is your mistake.
This change fixed it for me:

before:

DJANGO16_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}django>=1.5:${PORTSDIR}/www/py-django16
DJANGO17_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}django>=1.5:${PORTSDIR}/www/py-django

After:

DJANGO16_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}django16>0:${PORTSDIR}/www/py-django16
DJANGO17_RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}django17>0:${PORTSDIR}/www/py-django

—
Dan Langille
http://langille.org/
Ben Woods
2015-04-21 23:46:06 UTC
Permalink
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as
www/django
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
(1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package
/packages/All/py27-django16-1.6.11.txz
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
pkg-static: Insufficient privileges to add packages
But because I'm running testport interactively, I see I can install
the
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
Proceed with this action? [y/N]: y
[101amd64-testing-testing] [1/1] Installing py27-django16-1.6.11...
100%
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
That error is generated in the pkg exec_add function in src/add.c
https://github.com/freebsd/pkg/blob/master/src/add.c
It occurs because it checks the package database for read, write,
create
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
access using the pkgdb_access and pkgdb_check_access functions in
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
I believe this is inside the jail created by poudriere testport. It
would
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
be interesting to add the -i interactive flag to the testport run and
check
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.
I am running pkg 1.5.1 and poudriere 3.1.4. According to freshports,
pkg
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
was updated on 16th April, and poudriere on 10th April.
Inside my poudriere testport jail (using the -i interactive mode
flag), I
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
# 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
Thoughts?
Edit /etc/motd to change this login announcement.
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

Dan Langille
http://langille.org/
For the record, downgrading pkg to 1.4.12 and poudriere to 3.1.2 did
not fix this issue for me.
The port that I am trying to testport on FreeBSD 10.1 is
math/plplot-ada. The testport permission issues do not occur with the
port as it is currently - only after making the changes I have
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=155771&action=diff
I found the reason for Dan by checking the logs, If I could see your own logs
then I will tell you where you mistake is.
actually you are having poudriere building as a user (internally to the jail)
which is a very good thing as it allows to catch things like this :D)
I mean it is dropping roots priviledges to build, stage and make package.
but still try to install a dependency there, probably because the dependency
line you have in your port is buggy. In dan case he was testing if
py27-django>=1.5 but was refering to the www/py-django16 port which result in a
package named py27-django16 which is not py27-django aka the test will always
fail and the ports tree will try to reinstall again and again even in phases
when it cannot due to lack of priviledges
As a conclusion the bug is in the port you are testing not in pkg, neither in
poudriere.
If you show me the logs of your own build I will tell you what is your mistake.
Best regards,
Bapt
Thanks for your help Bapt. You are right, it was an issue with the port
dependency list. In my case the library had changed from plplotd.so to
plplot.so (now without the 'd'). I have fixed that in the LIB_DEPENDS line
and the problem is fixed.

Trying to debug this issue took some time, because the error message was
about permissions and I didn't make the connection was with unsatisfied
dependencies.

Could we perhaps add an additional check somewhere in the process that
informs you the dependencies have not been correctly satisfied? Do you
think this extra check belongs in poudriere or the ports infrastructure?

Regards,
Ben
--
--
From: Benjamin Woods
***@gmail.com
Baptiste Daroussin
2015-04-21 23:51:25 UTC
Permalink
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
I am running a testport on www/py-django-tastypie
My goal it to add an option for using www/django16 as well as
www/django
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
(1.7).
$ sudo poudriere testport -v -j 101amd64 -p testing -z testing -i -o
www/py-django-tastypie
...
===> Verifying install for py27-django>=1.5 in
/usr/ports/www/py-django16
===> Installing existing package
/packages/All/py27-django16-1.6.11.txz
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
pkg-static: Insufficient privileges to add packages
But because I'm running testport interactively, I see I can install
the
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
/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)
py27-django16: 1.6.11
The process will require 27 MiB more space.
Proceed with this action? [y/N]: y
[101amd64-testing-testing] [1/1] Installing py27-django16-1.6.11...
100%
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
Post by Dan Langille
Why does the testport fail?
http://services.unixathome.org/poudriere/data/101amd64-testing-testing/2015-04-20_19h53m23s/logs/errors/py27-django-tastypie-0.12.1.log
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
That error is generated in the pkg exec_add function in src/add.c
https://github.com/freebsd/pkg/blob/master/src/add.c
It occurs because it checks the package database for read, write,
create
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
access using the pkgdb_access and pkgdb_check_access functions in
https://github.com/freebsd/pkg/blob/master/libpkg/pkgdb.c
I believe this is inside the jail created by poudriere testport. It
would
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
be interesting to add the -i interactive flag to the testport run and
check
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
% 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
Regards,
Ben
Hand on a minute.... now my poudriere system is doing the same thing -
looks like we have a bug somewhere.
I am running pkg 1.5.1 and poudriere 3.1.4. According to freshports,
pkg
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
was updated on 16th April, and poudriere on 10th April.
Inside my poudriere testport jail (using the -i interactive mode
flag), I
Post by Ben Woods
Post by Dan Langille
Post by Ben Woods
# 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
Thoughts?
Edit /etc/motd to change this login announcement.
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
—
Dan Langille
http://langille.org/
For the record, downgrading pkg to 1.4.12 and poudriere to 3.1.2 did
not fix this issue for me.
The port that I am trying to testport on FreeBSD 10.1 is
math/plplot-ada. The testport permission issues do not occur with the
port as it is currently - only after making the changes I have
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=155771&action=diff
I found the reason for Dan by checking the logs, If I could see your own logs
then I will tell you where you mistake is.
actually you are having poudriere building as a user (internally to the jail)
which is a very good thing as it allows to catch things like this :D)
I mean it is dropping roots priviledges to build, stage and make package.
but still try to install a dependency there, probably because the dependency
line you have in your port is buggy. In dan case he was testing if
py27-django>=1.5 but was refering to the www/py-django16 port which result in a
package named py27-django16 which is not py27-django aka the test will always
fail and the ports tree will try to reinstall again and again even in phases
when it cannot due to lack of priviledges
As a conclusion the bug is in the port you are testing not in pkg, neither in
poudriere.
If you show me the logs of your own build I will tell you what is your mistake.
Best regards,
Bapt
Thanks for your help Bapt. You are right, it was an issue with the port
dependency list. In my case the library had changed from plplotd.so to
plplot.so (now without the 'd'). I have fixed that in the LIB_DEPENDS line
and the problem is fixed.
Trying to debug this issue took some time, because the error message was
about permissions and I didn't make the connection was with unsatisfied
dependencies.
Could we perhaps add an additional check somewhere in the process that
informs you the dependencies have not been correctly satisfied? Do you
think this extra check belongs in poudriere or the ports infrastructure?
Improvement for that has been added into the ports tree and taken in account by
poudriere in latest poudriere-devel 3.1.99.20150421_1 by Bryan

Best regards,
Bapt
Ben Woods
2015-04-22 00:50:19 UTC
Permalink
Post by Baptiste Daroussin
Post by Ben Woods
Post by Baptiste Daroussin
I found the reason for Dan by checking the logs, If I could see your own logs
then I will tell you where you mistake is.
actually you are having poudriere building as a user (internally to the jail)
which is a very good thing as it allows to catch things like this :D)
I mean it is dropping roots priviledges to build, stage and make package.
but still try to install a dependency there, probably because the dependency
line you have in your port is buggy. In dan case he was testing if
py27-django>=1.5 but was refering to the www/py-django16 port which result in a
package named py27-django16 which is not py27-django aka the test will always
fail and the ports tree will try to reinstall again and again even in phases
when it cannot due to lack of priviledges
As a conclusion the bug is in the port you are testing not in pkg, neither in
poudriere.
If you show me the logs of your own build I will tell you what is your mistake.
Best regards,
Bapt
Thanks for your help Bapt. You are right, it was an issue with the port
dependency list. In my case the library had changed from plplotd.so to
plplot.so (now without the 'd'). I have fixed that in the LIB_DEPENDS line
and the problem is fixed.
Trying to debug this issue took some time, because the error message was
about permissions and I didn't make the connection was with unsatisfied
dependencies.
Could we perhaps add an additional check somewhere in the process that
informs you the dependencies have not been correctly satisfied? Do you
think this extra check belongs in poudriere or the ports infrastructure?
Improvement for that has been added into the ports tree and taken in account by
poudriere in latest poudriere-devel 3.1.99.20150421_1 by Bryan
Best regards,
Bapt
Thanks Bapt and Bryan - looks like a helpful change!
_______________________________________________
freebsd-***@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-***@freebsd.org"

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Loading...