All of lore.kernel.org
 help / color / mirror / Atom feed
* useradd-staticids: problem with --user-group
@ 2019-07-02  5:56 Alexander Stein
  0 siblings, 0 replies; only message in thread
From: Alexander Stein @ 2019-07-02  5:56 UTC (permalink / raw)
  To: yocto

Hi,

I need to use useradd-staticids to have fixed UID/GID during update. For that I've set the following in my conf/local.conf:
> USERADD_ERROR_DYNAMIC = "1"
> USERADDEXTENSION = "useradd-staticids"
> USERADD_GID_TABLES = "files/group"
> USERADD_UID_TABLES = "files/passwd"

After deleting TMPDIR and rebuilding I get a build error in dbus package. In the log.do_prepare_recipe_sysroot logfile I have the following lines:
> [...]
> Running groupadd commands...
> NOTE: dbus: Performing groupadd with [--root $TMPDIR/work/cortexa7hf-neon-poky-linux-gnueabi/dbus/1.12.2-r0/recipe-sysroot --force --gid 999 --system netdev]
> NOTE: dbus: group netdev already exists, not re-creating it
> NOTE: dbus: Performing groupadd with [--root $TMPDIR/work/cortexa7hf-neon-poky-linux-gnueabi/dbus/1.12.2-r0/recipe-sysroot  --gid 998 messagebus]
> groupadd: GID '998' already exists

In $TMPDIR/work/cortexa7hf-neon-poky-linux-gnueabi/dbus/1.12.2-r0/recipe-sysroot/etc/group there the following entries:
> [...]
> nogroup:*:65534:
> systemd-journal:x:999:
> systemd-timesync:!:998:
> systemd-network:!:997:
> systemd-resolve:!:996:
> polkitd:!:995:
> systemd-bus-proxy:!:994:
> netdev:x:993:

So, ok. netdev is already there, but due to the --force parameter this is no error. But for adding the user-group using a fixed GID without --force fails as GID 998 is already used for systemd-timesync at this stage.

$ grep systemd-timesync files/group 
systemd-timesync:x:990:

So I wonder how to solve that. Should --force be added to the user-group step too? Or should the wanted GIDs for groups like systemd-timesync also be fixed before adding dbus specific users/groups?

I'm currently using sumo and without using useradd-staticids the build is fine, but the mapping user<->UID/GID might alter.

Best regards,
Alexander





^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-07-02  6:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-02  5:56 useradd-staticids: problem with --user-group Alexander Stein

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.