[elbe-users] replacing /etc/resolv.conf with a symlink
Olivier Dion
dion at linutronix.de
Wed Nov 20 18:05:49 CET 2019
On 2019-11-20T04:08:26-0500, Ralf Schlatterbeck <rsc at runtux.com>
wrote:
> On Tue, Nov 19, 2019 at 02:48:54PM -0500, Olivier Dion wrote:
> > > > - I have a debian package "iptna" that contains >
> > > > /etc/resolv.conf as
> > > a
> > > > symlink
> > > > - I have a finetuning rule (that I find nowhere in the
> > > > log):
> > > > <command>ln -sf /ipCAT.runtime/etc/resolv.conf >
> > > > /etc</command>
> > > > - Both should create the symlink but don't
> > > >
> > > > But resolv.conf ends up as a file containing just the
> > > > line:
> > > >
> > > > nameserver 10.0.2.3
> >
> > > I've found a workaround, if I put the symlink into the
> > > archive attached
> > > to the elbe XML file, the symlink is correctly created. But
> > > why don't
> > > all the other methods work for resolv.conf?
> >
> > Don't use the <command> action but the <ln> action instead.
> >
> > The reason why this is important is because the <ln> action
> > will protect the
> > created symlink from being reverted to the original. The
> > <command> action
> > does not.
> > Let me know if that work for you.
> This worked!
> Thanks for the explanation.
You're welcome!
> Is there some documentation to more closely explain the
> individual
> finetuning actions?
You have a list of actions available in the finetuning section
here
<https://elbe-rfs.org/docs/sphinx/article-elbe-schema-reference.html#finetuning>.
> I've found no such warning in the docs, maybe it
> should be added.
Agree, the docs need to be more verbose.
Note that the <command> action should only be use if no other
built-in actions can do the job. It's really a last resort
action. Also, it might broke on some command due to a bug in
QEMU.
--
Olivier Dion
Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-Mühlhofen
More information about the elbe-users
mailing list