[OE-core] [PATCH] dbus: fix paths in startup script, use useradd.bbclass for user creation

Scott Garman scott.a.garman at intel.com
Thu Sep 8 15:44:47 UTC 2011


On 09/07/2011 11:54 PM, Phil Blundell wrote:
> On Wed, 2011-09-07 at 20:58 -0700, Saul Wold wrote:
>> On 09/07/2011 01:28 PM, Phil Blundell wrote:
>>> Replace various hard-coded references to /usr, /var and /etc with symbolic equivalents.
>>>
>>> Also replace adhoc usage of adduser/addgroup with useradd.bbclass
>>> functionality.  This should, in theory, remove the need for a postinst
>>> to be run at boot time.
>>>
>>> Signed-off-by: Phil Blundell<philb at gnu.org>
>>
>> This one seems to have some problems:
>>
>> ERROR: Function 'useradd_sysroot' failed (see
>> /srv/home/pokybuild/yocto-autobuilder/yocto-slave/nightly-x86-64/build/build/tmp/work/x86_64-poky-linux/dbus-1.4.12-r6/temp/log.do_install.19825
>> for further information)
>> ERROR: Logfile of failure stored in:
>> /srv/home/pokybuild/yocto-autobuilder/yocto-slave/nightly-x86-64/build/build/tmp/work/x86_64-poky-linux/dbus-1.4.12-r6/temp/log.do_install.19825
>> Log data follows:
>> | DEBUG: SITE files ['endian-little', 'common-linux', 'common-glibc',
>> 'bit-64', 'x86_64-linux', 'common']
>> | ERROR: Function 'useradd_sysroot' failed (see
>> /srv/home/pokybuild/yocto-autobuilder/yocto-slave/nightly-x86-64/build/build/tmp/work/x86_64-poky-linux/dbus-1.4.12-r6/temp/log.do_install.19825
>> for further information)
>> | Running groupadd commands...
>> | sent invalidate(passwd) request, exiting
>> | sent invalidate(group) request, exiting
>> | sent invalidate(group) request, exiting
>> | sent invalidate(passwd) request, exiting
>> | sent invalidate(group) request, exiting
>> | sent invalidate(group) request, exiting
>> | Running useradd commands...
>> | useradd: group messagebus exists - if you want to add this user to
>> that group, use -g.
>> NOTE: package dbus-1.4.12-r6: task do_install: Failed
>
> That sounds a bit like the useradd option parsing bug (in shadow-native)
> that I mentioned the other day.  I had meant to send a patch for that
> but I forgot.
>
> Do any other recipes which use useradd.bbclass work for you?

Hi Phil,

So sorry for not jumping into these threads for so long. I've been way 
behind in my email and working on some non-development projects.

It appears you have found a bug in the way the shadow utils were patched 
to support a custom sysroot option. I have been testing the useradd 
class using the useradd_example recipe in Poky's meta-skeleton:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta-skeleton/recipes-skeleton/useradd/useradd-example.bb

This example does provide several command line options to the useradd 
binary, so I'm not sure how I missed this.

In any case, please submit your patch and I will advocate for its 
inclusion in our 1.1 release.

I hate to jump in and then out like this, but I am slammed preparing for 
a conference next week, and the week after that I will be on vacation. 
Mark Hatle should be familiar enough with the code to answer questions 
and do code review.

Scott

-- 
Scott Garman
Embedded Linux Engineer - Yocto Project
Intel Open Source Technology Center




More information about the Openembedded-core mailing list