[yocto] How to add user with nologin shell

Bipnesh, Abhinav (Abhinav) abhinavbipnesh at avaya.com
Thu Nov 24 02:05:59 PST 2016


I am trying to add an user to image with /sbin/nologin but it fails with below error

WARNING: avaya-image: useradd command did not succeed. Retrying...
ERROR: test-image: Tried running useradd command 1 times without success, giving up
ERROR: Function failed: set_user_group (log file is located at /home/abhinav/bitbake/.../test-image/1.0-r0/temp/log.do_rootfs.54725)
ERROR: Logfile of failure stored in: /home/abhinav/bitbake/../test-image/1.0-r0/temp/log.do_rootfs.54725
ERROR: Task 7 (/home/abhinav/bitbake/../images/test-image.bb, do_rootfs) failed with exit code '1'

I am using below section in my recipe to achieve it
EXTRA_USERS_PARAMS = "useradd -M -g user1 user1 -r -s /sbin/nologin;"

Any thoughts how to fix it.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20161124/7402241b/attachment.html>

More information about the yocto mailing list