Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 230537 - app-misc/beagle-0.3.7-r1 (eutils.eclass) fails recreating group beagleindex
Summary: app-misc/beagle-0.3.7-r1 (eutils.eclass) fails recreating group beagleindex
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Cédric Krier
URL: N/A
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-07-02 15:18 UTC by Robert Bradbury
Modified: 2008-11-22 23:06 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Bradbury 2008-07-02 15:18:32 UTC
emerge of beagle-0.3.7-r1 fails if a previous version of beagle was installed.

Reproducible: Always

Steps to Reproduce:
1.Install an older version of beagle (which creates the user and groups "beagleindex".
2.Install beagle-0.3.7-r1


Actual Results:  
Two errors occur in the output of the emerge indicating that:
   groupadd ${opts} ${egroup} || die "enewgroup failed"
with the error message:
   enewgroup failed

This is due to the fact that the "beagleindex" user & group already exist.

Expected Results:  
groupadd (or useradd) for existing groups/users should not fail.

Perhaps check to see if the group or user exist before calling groupadd or useradd.  Or else have the emerge programs catch and ignore errors for existing groups & users.

If one removes the user & group "beagleindex" and then re-emerges the emerge appears to work.  Of course this may cause problems if one has been indexing ones system and different user/group id's get assigned to the new "beagleindex" user & group because beagle may no longer have permission to modify the index files.
Comment 1 Cédric Krier gentoo-dev 2008-07-07 20:18:39 UTC
I don't understand because enewgroup must not failed if the group already exists.
Comment 2 Robert Bradbury 2008-07-07 21:11:18 UTC
I understand that you think it should work.  I think it is the way the ebuild is written to use "groupadd".  Here is what the log file said:

 * beagle-0.3.7.tar.bz2 RMD160 SHA1 SHA256 size ;-) ...                   [ ok ]
 * checking ebuild checksums ;-) ...                                      [ ok ]
 * checking auxfile checksums ;-) ...                                     [ ok ]
 * checking miscfile checksums ;-) ...                                    [ ok ]
 * checking beagle-0.3.7.tar.bz2 ;-) ...                                  [ ok ]
nscd: relocation error: nscd: symbol __nss_services_lookup, version GLIBC_PRIVATE not defined in file libc.so.6 with link time reference
 * Adding group 'beagleindex' to your system ...
 *  - Groupid: next available
groupadd: group beagleindex exists
 * 
 * ERROR: app-misc/beagle-0.3.7-r1 failed.
 * Call stack:
 *                ebuild.sh, line   49:  Called pkg_setup
 *   beagle-0.3.7-r1.ebuild, line   85:  Called enewgroup 'beagleindex'
 *            eutils.eclass, line  728:  Called die
 * The specific snippet of code:
 *   		groupadd ${opts} ${egroup} || die "enewgroup failed"
 *  The die message:
 *   enewgroup failed
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/root2/var/tmp/portage/app-misc/beagle-0.3.7-r1/temp/build.log'.
 * The ebuild environment file is located at '/root2/var/tmp/portage/app-misc/beagle-0.3.7-r1/temp/die.env'.
 * 

 * Messages for package app-misc/beagle-0.3.7-r1:

 * 
 * ERROR: app-misc/beagle-0.3.7-r1 failed.
 * Call stack:
 *                ebuild.sh, line   49:  Called pkg_setup
 *   beagle-0.3.7-r1.ebuild, line   85:  Called enewgroup 'beagleindex'
 *            eutils.eclass, line  728:  Called die
 * The specific snippet of code:
 *   		groupadd ${opts} ${egroup} || die "enewgroup failed"
 *  The die message:
 *   enewgroup failed
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/root2/var/tmp/portage/app-misc/beagle-0.3.7-r1/temp/build.log'.
 * The ebuild environment file is located at '/root2/var/tmp/portage/app-misc/beagle-0.3.7-r1/temp/die.env'.
 * 

Deleting beagleindex as a group and re-running I believe worked ok.  So the problem is that it shouldn't even attempt the "groupadd" if the group is already in /etc/group.  Likewise with /etc/passwd.
Comment 3 Pacho Ramos gentoo-dev 2008-07-20 16:40:24 UTC
These errors:
nscd: relocation error: nscd: symbol __nss_services_lookup, version
GLIBC_PRIVATE not defined in file libc.so.6 with link time reference

Are usually related with glibc and its updates, Did you upgraded it recently? Have you tried after re-emerging it? (please don't downgrade as it could cause problems)