<p><br>
On Mar 16, 2013 10:57 AM, "Zbigniew Jędrzejewski-Szmek" <<a href="mailto:zbyszek@in.waw.pl">zbyszek@in.waw.pl</a>> wrote:<br>
><br>
> On Wed, Mar 13, 2013 at 05:06:01PM +0900, Tom Gundersen wrote:<br>
> > On Wed, Mar 13, 2013 at 3:41 AM, <<a href="mailto:harald@redhat.com">harald@redhat.com</a>> wrote:<br>
> > > From: Harald Hoyer <<a href="mailto:harald@redhat.com">harald@redhat.com</a>><br>
> > ><br>
> > > Instead of using local-fs*.target in the initrd, use root-fs.target for<br>
> > > sysroot.mount and initrd-fs.target for /sysroot/usr and friends.<br>
> > ><br>
> > > Using local-fs.target would mean to carry over the activated<br>
> > > local-fs.target to the isolated initrd-switch-root.target and thus in<br>
> > > the real root. Having local-fs.target already active after<br>
> > > deserialization causes ordering problems with the real root services and<br>
> > > targets.<br>
> > ><br>
> > > We better isolate to targets for initrd-switch-root.target, which are<br>
> > > only available in the initrd.<br>
> ><br>
> > Looks good.<br>
> ><br>
> > This means that we should probably stop reusing units at all in the<br>
> > initramfs. In some cases I guess it works (udev/journal), but perhaps<br>
> > we should avoid it also there for consistency?<br>
> ><br>
> > In particular any storage daemons will need initrd-specific versions<br>
> > which are ordered against these new targets rather than<br>
> > local-fs.target. I don't see a problem with this, just something we<br>
> > need to be aware of.<br>
> Sorry fot the belated comment, but isn't it possible to exploit the<br>
> fact that dependencies on non-existent unints are ignored and use<br>
> something like:<br>
><br>
> WantedBy=local-fs.target initrd-fs.target<br>
> Before=local-fs.target initrd-fs.target<br>
><br>
> which should work both in the initrd and on the real system?<br>
><br>
> Zbyszek</p>
<p>Yes, that would work. As long as we don't mind the same unit being possibly activated twice: once in the real root and once in the init rd. I guess in general it would cause similar problems as what this was meant to solve?</p>
<p>T</p>