Date: Sun, 22 Sep 2002 09:59:16 +0930 (CST) From: "Greg 'groggy' Lehey" <grog@lemis.com> To: FreeBSD-gnats-submit@FreeBSD.org Subject: bin/43214: mergemaster does not handle missing /etc correctly Message-ID: <20020922002916.ABAB48130F@wantadilla.lemis.com>
next in thread | raw e-mail | index | archive | help
>Number: 43214
>Category: bin
>Synopsis: mergemaster does not handle missing /etc correctly
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Sat Sep 21 17:30:02 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator: Greg 'groggy' Lehey
>Release: FreeBSD 5.0-CURRENT i386
>Organization:
LEMIS (SA) Pty Ltd
>Environment:
System: FreeBSD wantadilla.lemis.com 5.0-CURRENT FreeBSD 5.0-CURRENT #0: Mon Dec 31 19:08:24 CST 2001 grog@monorchid.lemis.com:/src/FreeBSD/5-CURRENT-MONORCHID/src/sys/i386/compile/MONORCHID i386
>Description:
If mergemaster is run with a non-existent or empty /etc
directory, it does not do anything useful. It would be hoped
that this method could be used to install a virgin /etc
directory.
# mergemaster -p -a
*** The directory specified for the temporary root environment,
/var/tmp/temproot, exists. This can be a security risk if untrusted
users have access to the system.
*** Creating the temporary root environment in /var/tmp/temproot.0922.00.20.04
*** /var/tmp/temproot.0922.00.20.04 ready for use
*** Creating and populating directory structure in /var/tmp/temproot.0922.00.20.04
*** Beginning comparison
*** ./etc/master.passwd will remain for your consideration
*** ./etc/group will remain for your consideration
*** Comparison complete
*** Files that remain for you to merge by hand:
/var/tmp/temproot.0922.00.20.04/etc/master.passwd
/var/tmp/temproot.0922.00.20.04/etc/group
grep: /etc/make.conf: No such file or directory
*** Comparing make variables
*** From /etc/make.conf
*** From /usr/src/share/examples/etc/make.conf
In this case, it returns a condition code 0.
# ls -l /etc
ls: /etc: No such file or directory
# mergemaster -i -a
*** The directory specified for the temporary root environment,
/var/tmp/temproot, exists. This can be a security risk if untrusted
users have access to the system.
*** Creating the temporary root environment in /var/tmp/temproot.0922.00.20.47
*** /var/tmp/temproot.0922.00.20.47 ready for use
*** Creating and populating directory structure in /var/tmp/temproot.0922.00.20.47
set - `grep "^[a-zA-Z]" /src/FreeBSD/5-CURRENT-WANTADILLA/src/etc/locale.deprecated`; while [ $# -gt 0 ] ; do for dir in /usr/share/locale /usr/share/nls /usr/local/share/nls; do test -d /var/tmp/temproot.0922.00.20.47/${dir} && cd /var/tmp/temproot.0922.00.20.47/${dir}; test -L "$2" && rm -rf "$2"; test \! -L "$1" && test -d "$1" && mv "$1" "$2"; done; shift; shift; done
mtree -deU -f /src/FreeBSD/5-CURRENT-WANTADILLA/src/etc/mtree/BSD.root.dist -p /var/tmp/temproot.0922.00.20.47/
mtree: line 6: unknown user root
*** Error code 1
Stop in /src/FreeBSD/5-CURRENT-WANTADILLA/src/etc.
*** FATAL ERROR: Cannot 'cd' to /usr/src/etc and install files to
the temproot environment
>How-To-Repeat:
As above
>Fix:
It's probably not worth fixing this bug in isolation. The
real issue here is the difficulty of installing /etc at all.
The only way I know is via a release CD-ROM. It shouldn't be
that difficult: it should be part of the base installworld
target. Consider this PR a flag to be closed when a good
solution has been found.
>Release-Note:
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020922002916.ABAB48130F>
