<?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>9424</bug_id>
          
          <creation_ts>2016-04-08 08:24:07 +0000</creation_ts>
          <short_desc>systemd tmpfiles.d warnings (volatile, resolv.conf)</short_desc>
          <delta_ts>2022-06-09 11:25:34 +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>2.1</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>OBSOLETE</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>minor</bug_severity>
          <target_milestone>4.1</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Patrick Ohly">patrick.ohly</reporter>
          <assigned_to name="Pavel Zhukov">pavel</assigned_to>
          <cc>bill.randle</cc>
    
    <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>sgw</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>60965</commentid>
    <comment_count>0</comment_count>
    <who name="Patrick Ohly">patrick.ohly</who>
    <bug_when>2016-04-08 08:24:07 +0000</bug_when>
    <thetext>The systemd configuration in OE-core follows OE-core conventions where /var/tmp and /var/log are symlinks into /var/volatile, which gets mounted via 00-create-volatile.conf.

That works, but there are log messages about the setup in the systemd journal:

# journalctl | grep tmp
Apr 08 08:12:10 192.168.7.2 kernel: devtmpfs: initialized
Apr 08 08:12:10 192.168.7.2 systemd-tmpfiles[696]: [/usr/lib/tmpfiles.d/etc.conf:16] Duplicate line for path &quot;/etc/resolv.conf&quot;, ignoring.
Apr 08 08:12:10 192.168.7.2 systemd-tmpfiles[696]: &quot;/var/tmp&quot; already exists and is not a directory.
Apr 08 08:12:10 192.168.7.2 systemd-tmpfiles[696]: &quot;/var/log&quot; already exists and is not a directory.

These messages can be confusing when investigating boot issues: they are harmless, but not everyone knows that.

It would be better to change the systemd configuration files so that these messages are avoided.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61292</commentid>
    <comment_count>1</comment_count>
    <who name="Bill Randle">bill.randle</who>
    <bug_when>2016-04-15 16:09:45 +0000</bug_when>
    <thetext>Patrick, can you include a copy of your /usr/lib/tmpfiles.d/etc.conf file? The version in master has only 14 lines in it, while yours appears to have 16 lines (at least).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61304</commentid>
    <comment_count>2</comment_count>
    <who name="Patrick Ohly">patrick.ohly</who>
    <bug_when>2016-04-15 19:10:25 +0000</bug_when>
    <thetext>Here&apos;s what I have:

#  This file is part of systemd.
#
#  systemd is free software; you can redistribute it and/or modify it
#  under the terms of the GNU Lesser General Public License as published by
#  the Free Software Foundation; either version 2.1 of the License, or
#  (at your option) any later version.

# See tmpfiles.d(5) for details

L /etc/os-release - - - - ../usr/lib/os-release
L /etc/localtime - - - - ../usr/share/zoneinfo/UTC
L+ /etc/mtab - - - - ../proc/self/mounts
t /etc/mtab - - - - security.SMACK64=_
C /etc/nsswitch.conf - - - -
C /etc/pam.d - - - -
L! /etc/resolv.conf - - - - ../run/resolv.conf

Note that we enable pam in Ostro OS. That perhaps explains at least one additional line (/etc/pam.d).

resolv.conf is also conditional, checking PACKAGECONFIG resolved (seen in meta/recipes-core/systemd/systemd_229.bb).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61307</commentid>
    <comment_count>3</comment_count>
    <who name="Bill Randle">bill.randle</who>
    <bug_when>2016-04-15 20:31:23 +0000</bug_when>
    <thetext>Thanks. I have a fix for the /var/tmp and /var/log directory exists warnings. The duplicate entry for resolv.conf is there because (at least in my config) the connman package installs a systemd config file in /etc/tmpfiles.d which also has a rule for /etc/resolv.conf. There&apos;s really no easy way around that particular warning short of adding a conditional in /usr/lib/tmpfiles.d/etc.conf to check if connman is installed. I&apos;m not sure we want to go to that effort.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61313</commentid>
    <comment_count>4</comment_count>
    <who name="Bill Randle">bill.randle</who>
    <bug_when>2016-04-15 22:34:56 +0000</bug_when>
    <thetext>Patch send to oe-core mailing list to fix the &quot;directory exits&quot; warning messages. As previously mentioned, you will still see the warning for duplicate /etc/resolv.conf entries, but I think this is reasonable.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66231</commentid>
    <comment_count>5</comment_count>
    <who name="Joshua Lock">joshuagloe</who>
    <bug_when>2016-09-15 21:31:02 +0000</bug_when>
    <thetext>Patch was submitted but not merged http://lists.openembedded.org/pipermail/openembedded-core/2016-April/120308.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>66277</commentid>
    <comment_count>6</comment_count>
    <who name="Bill Randle">bill.randle</who>
    <bug_when>2016-09-17 03:10:15 +0000</bug_when>
    <thetext>Ross rejected the patch with a comment: http://lists.openembedded.org/pipermail/openembedded-core/2016-July/124013.html .

I believe the patch solves this specific bug, but multiple systemd patches have come in since April and perhaps it&apos;s not exactly right anymore. The OE files file does specify some specific rules for using /volatile instead of /var and I was trying to work within that framework. There was an ordering problem, for sure, where a subdir creation was attempted before the /volatile directory was created (as I recall) which caused the error messages the bug submitter saw.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93432</commentid>
    <comment_count>7</comment_count>
    <who name="Pavel Zhukov">pavel</who>
    <bug_when>2022-06-09 11:25:34 +0000</bug_when>
    <thetext>This issue has been solved in system already. Not reproducible with kiskstone.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>