From sa@nkz.delikates-nk.ru  Thu Aug 10 15:28:35 2006
Return-Path: <sa@nkz.delikates-nk.ru>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 6F59616A4DA
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 10 Aug 2006 15:28:35 +0000 (UTC)
	(envelope-from sa@nkz.delikates-nk.ru)
Received: from delikates-nk.ru (delikates-nk.ru [81.16.143.98])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 7AE7E43D45
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 10 Aug 2006 15:28:32 +0000 (GMT)
	(envelope-from sa@nkz.delikates-nk.ru)
Received: from nkz.delikates-nk.ru (ws097.delikates-nk.ru [192.168.1.97])
	by delikates-nk.ru (8.13.6/8.13.6) with ESMTP id k7AFST1l027336
	for <FreeBSD-gnats-submit@freebsd.org>; Thu, 10 Aug 2006 23:28:29 +0800 (KRAST)
	(envelope-from sa@nkz.delikates-nk.ru)
Received: (from root@localhost)
	by nkz.delikates-nk.ru (8.13.6/8.13.6/Submit) id k7ANa5Gk068275;
	Fri, 11 Aug 2006 07:36:05 +0800 (KRAST)
	(envelope-from sa)
Message-Id: <200608102336.k7ANa5Gk068275@nkz.delikates-nk.ru>
Date: Fri, 11 Aug 2006 07:36:05 +0800 (KRAST)
From: Eugene Grosbein <eugen@kuzbass.ru>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: sysinstall(8): Sysinstall does not obey /usr/ports symlink while installing ports tree
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         101762
>Category:       bin
>Synopsis:       sysinstall(8) does not obey /usr/ports symlink while installing ports tree
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-sysinstall
>State:          analyzed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Thu Aug 10 15:30:15 GMT 2006
>Closed-Date:    
>Last-Modified:  Tue Jul 13 15:30:06 UTC 2010
>Originator:     Eugene Grosbein
>Release:        FreeBSD 6.1-RELEASE i386
>Organization:
Svyaz Service JSC
>Environment:
System: FreeBSD nkz.delikates-nk.ru 6.1-RELEASE FreeBSD 6.1-RELEASE #0: Sun May 7 04:42:56 UTC 2006 root@opus.cse.buffalo.edu:/usr/obj/usr/src/sys/SMP i386

>Description:
	I've booted 6.1-RELEASE installation CD and installed this release
	using 'Custom' mode. I've created 128M-sized root and 256M-sized /usr,
	4G /usr/local and 15G /home and selected only base distribution
	(and kernels).

	I've booted the new installation from hard drive, created directory
	/home/ports and made symlink /usr/ports -> /home/ports.
	Then I mounted CD and ran sysinstall to install Ports Collection.
	I hoped it will populate /home/ports. However, sysinstall removed
	/usr/ports symlink and started to fill /usr/ports directory,
	quickly ran out of vnodes and failed.

	The same attempt for src distribution was successful, sysinstall
	has not removed /usr/src -> /home/src symlink and populated /home/src
	directory.

>How-To-Repeat:
	
	Make empty /home/ports directory, make /usr/ports symlink pointing
	to /home/ports, run sysinstall and try to install Ports Collection
	from FreeBSD 6.1-RELEASE CD (disk1). Sysinstall removes /usr/ports
	symlink, recreates it as directory and unrolls ports to /usr partition.

>Fix:

	Unknown.

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-qa 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Aug 10 19:18:32 UTC 2006 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=101762 
State-Changed-From-To: open->analyzed 
State-Changed-By: erwin 
State-Changed-When: Sun Dec 17 15:52:04 UTC 2006 
State-Changed-Why:  
The problem here is that the tarballs for source are packaged 
relative to /usr/src/... while the ports tarball is relative 
to /usr/... and unpackages ports/... Thus the src tarballs 
never touch src/, but ports will create, and overwrite any 
existing, ports/. 

Fixing is easy, from a code viewpoint.  Change the 
DTE_TARBALL for ports to /usr/ports and let the release 
building process build ports relative to /usr/ports/. 
However, doing this will create a ports tarball that is 
no longer usable by older sysinstall and some form of 
backwards compatability magic is needed. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=101762 
Responsible-Changed-From-To: freebsd-bugs->freebsd-sysinstall 
Responsible-Changed-By: gavin 
Responsible-Changed-When: Tue Jul 13 13:37:09 UTC 2010 
Responsible-Changed-Why:  
Over to maintainer(s) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=101762 

From: Garrett Cooper <yanegomi@gmail.com>
To: bug-followup@FreeBSD.org, eugen@kuzbass.ru
Cc:  
Subject: Re: bin/101762: sysinstall(8) does not obey /usr/ports symlink while 
	installing ports tree
Date: Tue, 13 Jul 2010 08:27:34 -0700

 To add another dimension to the issue, cpio is used when extracting
 the dist tarballs, and -du is specified on the cpio command line:
 
      -d      (i and p modes) Create directories as necessary.
 
      -u      (i and p modes) Unconditionally overwrite existing files.  Ordi-
              narily, an older file will not overwrite a newer file on disk.
 
 So it creates the directories if they don't already exist.
 
 See media.c for more details.
 
 Cheers,
 -Garrett
>Unformatted:
