<div dir="ltr"><div>Hey list,</div><div><br></div><div>I'm in the process of experimenting with a systemd-based initrd.</div><div>However I have two questions concerning the boot process that came up whilst reading the documentation.<br></div><div><br></div><div>If I understand "man 7 bootup" correctly so far  the initrd mounts /sysroot based on either the root= kernel parameter or through gpt-auto-generator.   At this point /sysroot is mounted. However /sysroot/etc/fstab might have additional entries that need to be mounted in the initrd (marked with "x-initrd"). <br></div><div>Next "initrd-parse-etc.service" gets triggered which runs fstab-generator  which then mounts all the entries marked with "x-initrd". <br></div><div>If "/usr" is in a separate partition; I would expect it to _need_ to be marked "x-initrd" as you want /usr to be present as soon as you boot up the system. And this causes the "sysroot-usr.mount" unit to be generated and gets pulled in by "initrd-fs.target".</div><div><br></div><div>We're now ready to switch-root to the root-filesystem and move to stage-2.<br></div><div><br></div><div>In stage-2, in early boot.  "systemd-remount-fs.service" runs;  which remounts / and /usr with the actual options in /etc/fstab.</div><div><br></div><div>Two questions about this:</div><div><br></div><div>1.  if sysroot-usr.mount already gets pulled in in the initrd by parsing /sysroot/etc/fstab why do we need to remount /usr   in stage-2 with "systemd-remount-fs.service"? Didn't we already parse the correct values from fstab, and hence /usr is already guaranteed to be correctly mounted?</div><div><br></div><div>2. relatedly;  why cant after "initrd-parse-etc.service" is run  sysroot.mount  be retriggered with the new options parsed from /sysroot/etc/fstab as well?  Then to me it sounds like "systemd-remount-fs.service" is not needed at all for / and /usr. (though maybe still for /sys and /proc)</div><div><br></div><div>My gut feeling the answer to this question is "not all initrd's use systemd; so they might not parse /sysroot/etc/fstab so early we need to account for that". Is that the case?<br></div><div><br></div><div>Kind regards,</div><div><br></div><div>Arian<br></div><div><div><br></div><div><br></div><div><br>-- <br><div dir="ltr" data-smartmail="gmail_signature"><div dir="ltr"><span><p class="MsoNormal"><span style="font-size:9.5pt"> </span></p><p class="MsoNormal"><b><span style="font-size:9.5pt;color:rgb(204,204,204)">Zeta Project Germany GmbH  </span></b><span style="font-size:9.5pt;color:rgb(204,204,204)">l  <a href="https://maps.google.com/?q=Rosenthaler+Stra%C3%9Fe+40,%C2%A0+10178+Berlin,%C2%A0+Germany&entry=gmail&source=g" target="_blank"><span style="color:rgb(17,85,204)">Rosenthaler Straße 40, </span></a><a href="https://maps.google.com/?q=Rosenthaler+Stra%C3%9Fe+40,%C2%A0+10178+Berlin,%C2%A0+Germany&entry=gmail&source=g" target="_blank"><span style="color:rgb(17,85,204)">10178 Berlin, </span></a><a href="https://maps.google.com/?q=Rosenthaler+Stra%C3%9Fe+40,%C2%A0+10178+Berlin,%C2%A0+Germany&entry=gmail&source=g" target="_blank"><span style="color:rgb(17,85,204)">Germany</span></a></span><span style="font-size:9.5pt"></span></p><p class="MsoNormal"><span style="font-size:9.5pt"> </span></p><p class="MsoNormal"><span style="font-size:9.5pt;color:rgb(204,204,204)">Geschäftsführer/Managing Director: Morten J. Broegger, Dylan Riley</span><span style="font-size:9.5pt"></span></p><p class="MsoNormal"><span style="font-size:9.5pt;color:rgb(204,204,204)">HRB 149847 beim Handelsregister Charlottenburg, Berlin</span><span style="font-size:9.5pt"></span></p><p class="MsoNormal"><span style="font-size:9.5pt;color:rgb(204,204,204)">VAT-ID DE288748675</span></p></span></div></div></div></div></div>