copying /etc/resolv.conf produces error
Manuel Hachtkemper
hacman at math.uni-bonn.de
Wed Jan 15 19:12:26 CET 2014
Hi,
the following lines in /usr/lib/fai/subroutines
# some generale network files are needed on the client
# resolv.conf is needed, /etc/hosts is useful in /target
# use a file from the config space or from /etc inside the nfsroot
if ! fcopy -BMv /etc/resolv.conf ; then
if test -L $FAI_ROOT/etc/resolv.conf && \
[ $(readlink -f /etc/resolv.conf) = $(readlink -f $FAI_ROOT/etc/resolv.conf) ] ; then
echo "/etc/resolv.conf + $FAI_ROOT/etc/resolv.conf are already pointing to the same file."
else
cp -v /etc/resolv.conf $FAI_ROOT/etc
fi
fi
generate following warning/error lines (in our setup) during a softupdate
fcopy: Nonexisting directory /var/lib/fai/config/files/etc/resolv.conf. No files copied.
cp: /etc/resolv.conf' and //etc/resolv.conf are the same file
.
We're using DHCP and therefore we don't need a resolv.conf in our config space (and don't want to have multiple of these files since we have a few networks with different IP addresses for resolvers).
I think in our case it's safe to ignore these messages, but in my opinion this is a bug. I don't have a patch, however an easy/dirty solution would be to check (after "else") if the file already exists.
Best regards,
Manuel Hachtkemper
More information about the linux-fai
mailing list