Subject: Re: UBC vs lfs and union mount
To: Chuck Silvers <chuq@chuq.com>
From: None <ks@ub.uni-mainz.de>
List: current-users
Date: 12/05/2000 11:05:54
Hi,

Geoff Wing wrote:
> ------------------------------------------------------------
> % mount_union /obj /usr/src && cd /usr/src && make includes
> includes ===> include
> Segmentation fault
> install -r   -c  -o bin -g bin -m 444 a.out.h  /usr/include/a.out.h
> install: /usr/include/inst.00725a: Bad address
> *** Error code 1
> 
> Stop.
> *** Error code 1
> 
> Stop.
> ------------------------------------------------------------

I got the same problem using union-mounted src on my labdog (i386,
-current as of yesterday 12/04/00 around 17:00 MET)

Trying to do what "make -n" proposes, I found cmp(1), which
memory-maps files to compare them failing with an (at least for me
useless ;-) core dump. Here's the (relevant) part of a ktrace:

   431 cmp      CALL  open(0xbfbfd687,0,0)
   431 cmp      NAMI  "if_levar.h"
   431 cmp      RET   open 3
   431 cmp      CALL  open(0xbfbfd692,0,0)
   431 cmp      NAMI  "/usr/include/dev/pci/if_levar.h"
   431 cmp      RET   open 4
   431 cmp      CALL  __fstat13(0x3,0xbfbfd4dc)
   431 cmp      RET   __fstat13 0
   431 cmp      CALL  __fstat13(0x4,0xbfbfd47c)
   431 cmp      RET   __fstat13 0
   431 cmp      CALL  mmap(0,0xab2,0x1,0x1,0x3,0,0,0)
   431 cmp      RET   mmap 1208958976/0x480f4000
   431 cmp      CALL  madvise(0x480f4000,0xab2,0x2)
   431 cmp      RET   madvise 0
   431 cmp      CALL  mmap(0,0xab2,0x1,0x1,0x4,0,0,0)
   431 cmp      RET   mmap 1208963072/0x480f5000
   431 cmp      CALL  madvise(0x480f5000,0xab2,0x2)
   431 cmp      RET   madvise 0
   431 cmp      PSIG  SIGSEGV SIG_DFL


And another ktrace of "install":

   361 install  CALL  __stat13(0xbfbfd695,0xbfbfd444)
   361 install  NAMI  "/usr/include/dev/pci/if_devar.h"
   361 install  RET   __stat13 0
   361 install  CALL  __stat13(0xbfbfd68a,0xbfbfd4a4)
   361 install  NAMI  "if_devar.h"
   361 install  RET   __stat13 0
   361 install  CALL  __stat13(0xbfbfd68a,0xbfbfcba8)
   361 install  NAMI  "if_devar.h"
   361 install  RET   __stat13 0
   361 install  CALL  __stat13(0xbfbfd695,0xbfbfcb48)
   361 install  NAMI  "/usr/include/dev/pci/if_devar.h"
   361 install  RET   __stat13 0
   361 install  CALL  getpid
   361 install  RET   getpid 361/0x169
   361 install  CALL  __stat13(0xbfbfc748,0xbfbfc698)
   361 install  NAMI  "/usr/include/dev/pci"
   361 install  RET   __stat13 0
   361 install  CALL  open(0xbfbfc748,0xa02,0x180)
   361 install  NAMI  "/usr/include/dev/pci/inst.00361a"
   361 install  RET   open 3
   361 install  CALL  open(0xbfbfd68a,0,0)
   361 install  NAMI  "if_devar.h"
   361 install  RET   open 4
   361 install  CALL  mmap(0,0x9c64,0x1,0x1,0x4,0,0,0)
   361 install  RET   mmap 1208967168/0x480f6000
   361 install  CALL  madvise(0x480f6000,0x9c64,0x2)
   361 install  RET   madvise 0
   361 install  CALL  write(0x3,0x480f6000,0x9c64)
   361 install  RET   write -1 errno 14 Bad address
   361 install  CALL  unlink(0xbfbfc748)
   361 install  NAMI  "/usr/include/dev/pci/inst.00361a"
   361 install  RET   unlink 0

Just another datapoint...

     Kurt
===============================================================================
Dipl.-Inform. Kurt Schreiner            Tel. : +49 6131 39 25134
Universitaet Mainz/Zentralbibliothek	Fax. : +49 6131 39 24159 o. 23976
Jakob Welder Weg 6, 55128 Mainz		Mail : ks@ub.uni-mainz.de
===============================================================================