]> code.ossystems Code Review - openembedded-core.git/commit
base-passwd: install passwd and group atomically
authorRobert Yang <liezhi.yang@windriver.com>
Mon, 7 Jul 2014 04:40:37 +0000 (21:40 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 10 Jul 2014 16:37:38 +0000 (17:37 +0100)
commitcdbe55215e3dd1b82a6c147a31c7c40186a8bf80
tree16ccaba69b65f6e975d607ea8300c95a0a8ff46c
parent7384d2831c713ac5999aca83c312154dc15cec56
base-passwd: install passwd and group atomically

Fixed the race issue:
util-macros.do_package failed: 'getpwnam(): name not found: root'

The error happens when there is a half etc/passwd, fixed by:
$ install usr/share/base-passwd/passwd.master etc/passwd.master
$ mv etc/passwd.master etc/passwd

The "mv" is atomic which will fix this problem.

[YOCTO #6124]

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
meta/recipes-core/base-passwd/base-passwd_3.5.29.bb