<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>11766</bug_id>
          
          <creation_ts>2017-07-06 15:48:06 +0000</creation_ts>
          <short_desc>&quot;nobody&quot; group added by systemd sysusers.d</short_desc>
          <delta_ts>2023-03-31 12:08:54 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>core</component>
          <version>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium+</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>4.2 M4</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Patrick Ohly">patrick.ohly</reporter>
          <assigned_to name="Piotr Łobacz">p.lobacz</assigned_to>
          <cc>cinly.ooi</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>p.lobacz</cc>
    
    <cc>Qi.Chen</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>rebecca.swee.fun.chang</cc>
    
    <cc>richard.purdie</cc>
    
    <cc>sgw</cc>
    
    <cc>yi.zhao</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>74833</commentid>
    <comment_count>0</comment_count>
    <who name="Patrick Ohly">patrick.ohly</who>
    <bug_when>2017-07-06 15:48:06 +0000</bug_when>
    <thetext>systemd has:

# grep nobody /usr/lib/sysusers.d/basic.conf 
# The nobody user for NFS file systems
u nobody  65534 &quot;Nobody&quot;     -

At runtime, that creates a group &quot;nobody&quot; because there is no such group in the base configuration. Adding that group causes /etc/group to differ from what was in the original image, which causes OSTree to stop updating the file because it looks like it was modified by a local admin.

systemd_create_users() from rootfs-postcommands.bbclass looks at these systemd configuration files, but it doesn&apos;t create the group, probably because there is already a &quot;nobody&quot; user in /etc/passwd.

I think the right solution would be to have both a &quot;nobody&quot; user and group.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78565</commentid>
    <comment_count>1</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2017-12-07 08:12:56 +0000</bug_when>
    <thetext>I&apos;m not sure if it is a good idea to add nobody group.

For sysVinit, we follow the Debian rule which doesn&apos;t have nobody group and the nobody user&apos;s group is &quot;nogroup&quot; group. Should we have to break this rule to add nobody group for systemd ? And for systemd, although it create nobody group with systemd-sysusers, the nobody user&apos;s group is not changed, still nogroup. That means no one belongs to this group.

My preferred solution is to pass &quot;--with-nobody-group=nogroup&quot; to systemd configure to ensure the systemd doesn&apos;t create nobody group and also follow the Debian rule.

Another similar situation is wheel group, there is no such group in debian rule but systemd create it.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78567</commentid>
    <comment_count>2</comment_count>
    <who name="Patrick Ohly">patrick.ohly</who>
    <bug_when>2017-12-07 09:23:09 +0000</bug_when>
    <thetext>If systemd already supports running without a nobody group, then I agree that this is the right solution. Same for wheel.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78678</commentid>
    <comment_count>3</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2017-12-12 03:29:53 +0000</bug_when>
    <thetext>I had built core-image-sato-sdk image and found there are 3 groups adding by systemd-sysusers: nobody, wheel, kvm.

Someone sent a patch for adding wheel group in systemd to oe-core but it is still pending.

For Debian, in order to avoid creating groups, it doesn&apos;t ship /usr/lib/sysusers.d/basic.conf to the system. I don&apos;t think this is a good solution for Yocto.

For the end users, if you want to avoid creating these groups, I suggest to remove PACKAGECONFIG for sysusers when building. It should be safe.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>87044</commentid>
    <comment_count>4</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2020-04-16 08:27:06 +0000</bug_when>
    <thetext>Yi please re-submit.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>89923</commentid>
    <comment_count>5</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2021-04-13 02:35:53 +0000</bug_when>
    <thetext>Set a specific milestone target. Yi please get this one under discussion to see if we are going to reject it or not.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91023</commentid>
    <comment_count>6</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2021-07-27 04:28:47 +0000</bug_when>
    <thetext>On current Yocto 3.4, there are 4 extra groups added by systemd: wheel,render,sgx,nobody. For the end users, if you want to avoid creating these groups, I suggest to remove PACKAGECONFIG for sysusers when building.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95045</commentid>
    <comment_count>7</comment_count>
    <who name="Piotr Łobacz">p.lobacz</who>
    <bug_when>2023-03-02 15:19:54 +0000</bug_when>
    <thetext>I think I have found why it is caused in issue https://bugzilla.yoctoproject.org/show_bug.cgi?id=15046</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95053</commentid>
    <comment_count>8</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-03-02 16:17:12 +0000</bug_when>
    <thetext>Do we need this bug and https://bugzilla.yoctoproject.org/show_bug.cgi?id=15046
or can one be closed?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95055</commentid>
    <comment_count>9</comment_count>
    <who name="Piotr Łobacz">p.lobacz</who>
    <bug_when>2023-03-02 19:16:21 +0000</bug_when>
    <thetext>(In reply to comment #8)
&gt; Do we need this bug and
&gt; https://bugzilla.yoctoproject.org/show_bug.cgi?id=15046
&gt; or can one be closed?

I think we can close it and I can commit a patch with the fix to the list</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95056</commentid>
    <comment_count>10</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-03-02 20:22:15 +0000</bug_when>
    <thetext>Piotr,
We like to have a link to the oe-core commit in the comments here so I&apos;ve left this open for a bit longer. Once the change is merged add a link and set the Status to Resolved / Fixed please.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95129</commentid>
    <comment_count>11</comment_count>
    <who name="Piotr Łobacz">p.lobacz</who>
    <bug_when>2023-03-14 11:14:05 +0000</bug_when>
    <thetext>(In reply to comment #10)
&gt; Piotr,
&gt; We like to have a link to the oe-core commit in the comments here so I&apos;ve
&gt; left this open for a bit longer. Once the change is merged add a link and
&gt; set the Status to Resolved / Fixed please.

Randy I have sent a patch to the mailing list. Please verify it(In reply to Randy MacLeod from comment #10)
&gt; Piotr,
&gt; We like to have a link to the oe-core commit in the comments here so I&apos;ve
&gt; left this open for a bit longer. Once the change is merged add a link and
&gt; set the Status to Resolved / Fixed please.

Randy I have sent a patch with git send-email but it is not yet visible on the list</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95131</commentid>
    <comment_count>12</comment_count>
    <who name="Piotr Łobacz">p.lobacz</who>
    <bug_when>2023-03-14 14:21:27 +0000</bug_when>
    <thetext>OK Randy I have finally succeeded. Haven&apos;t noticed that I need to be subscribed to the mailing list...

This is the link with the patch fix https://lists.openembedded.org/g/openembedded-core/message/178491</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95246</commentid>
    <comment_count>13</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-03-30 20:08:13 +0000</bug_when>
    <thetext>Piotr,

  I should remember to mention that you need to be subscribed to the list. Oops.

Your commit is on master:
https://git.openembedded.org/openembedded-core/commit/?id=d69fccf2e5d108dd7c6059310924588d36a45865

❯ git branch -a --contains d69fccf2e5d108dd7c6059310924588d36a45865
* master
  remotes/origin/HEAD -&gt; origin/master
  remotes/origin/master
  remotes/origin/master-next

and is making it&apos;s way back to the langdale and kirkstone branches. 

So I&apos;m marking it as resolved.

Thanks!</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>95255</commentid>
    <comment_count>14</comment_count>
    <who name="Piotr Łobacz">p.lobacz</who>
    <bug_when>2023-03-31 12:08:54 +0000</bug_when>
    <thetext>Your welcome Randy :)</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>