From adam@veda.is  Sat Oct 26 07:26:35 1996
Received: from veda.is (root@ubiq.veda.is [193.4.230.60])
          by freefall.freebsd.org (8.7.5/8.7.3) with ESMTP id HAA28695
          for <FreeBSD-gnats-submit@freebsd.org>; Sat, 26 Oct 1996 07:26:32 -0700 (PDT)
Received: (from adam@localhost) by veda.is (8.8.2/8.7.3) id OAA08755; Sat, 26 Oct 1996 14:26:24 GMT
Message-Id: <199610261426.OAA08755@veda.is>
Date: Sat, 26 Oct 1996 14:26:24 GMT
From: Adam David <adam@veda.is>
Reply-To: adam@veda.is
To: FreeBSD-gnats-submit@freebsd.org
Subject: install(1) removes target file
X-Send-Pr-Version: 3.2

>Number:         1892
>Category:       bin
>Synopsis:       install(1) removes target file
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    ru
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Oct 26 07:30:02 PDT 1996
>Closed-Date:    Tue Sep 25 07:31:46 PDT 2001
>Last-Modified:  Tue Sep 25 07:33:57 PDT 2001
>Originator:     Adam David
>Release:        FreeBSD 2.2-CURRENT i386
>Organization:
Veda Internet
>Environment:

	'make install' with a shortage of disk space

>Description:

	install(1) removes the target file if the disk becomes full during
	the operation.

>How-To-Repeat:

	on a machine with a shortage of space in /
	do a 'make install' in /usr/src
	notice that /bin/sh or /sbin/dump (for instance) can get clobbered

>Fix:
	
	relink to the old copy of the file if it still exists, as is likely
	the case for /bin/sh

	or:

	always keep a reference to the old copy, and relink to it on failure.

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->suspended 
State-Changed-By: phk 
State-Changed-When: Mon May 25 00:46:10 PDT 1998 
State-Changed-Why:  
awaiting committer 
Responsible-Changed-From-To: freebsd-bugs->n_hibma 
Responsible-Changed-By: n_hibma 
Responsible-Changed-When: Mon Jul 26 11:38:47 PDT 1999 
Responsible-Changed-Why:  
It might be useful to solve this problem, so I'll have a look at it someday. 
Remind me. 
State-Changed-From-To: suspended->closed 
State-Changed-By: ru 
State-Changed-When: Tue Sep 25 07:31:46 PDT 2001 
State-Changed-Why:  
install(1) now has the -S option (safe copy) that doesn't 
suffer from this problem. 


Responsible-Changed-From-To: n_hibma->ru 
Responsible-Changed-By: ru 
Responsible-Changed-When: Tue Sep 25 07:31:46 PDT 2001 
Responsible-Changed-Why:  

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=1892 
>Unformatted:
