Path: utzoo!mnetor!uunet!husc6!cmcl2!brl-adm!brl-smoke!gwyn From: gwyn@brl-smoke.ARPA (Doug Gwyn ) Newsgroups: comp.unix.wizards Subject: Re: How does filling a disk to capacity affect performance? Message-ID: <7673@brl-smoke.ARPA> Date: 12 Apr 88 15:10:54 GMT References: <460@osupyr.mast.ohio-state.edu> <92@iravcl.ira.uka.de> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 22 In article <92@iravcl.ira.uka.de> fsinf@iravcl.ira.uka.de writes: >I've heard (but not verified) you can crash *every* unix-system using the >CP-command when there is not enough space on disk. CP will not check >whether the disk is full and overwrite blocks which are not free. The original >data will be lost; also the machine is likely to go down. This is totally off-the-wall. "cp" is just a user-mode utility; it is the KERNEL that maintains file system integrity. It is true that "cp" does not check whether there is enough space to hold the copy, but it cannot know that in advance (there are other processes asynchronously modifying the file system). I know of only two UNIX utilities that even attempt to check for sufficient space before writing a file (one is "ed"). The only real problems I know of with user-mode programs running a filesystem out of space are: If the filesystem contains /tmp, several critical system utilities may malfunction. Other applications that don't check for successful system call operation may not realize that their output is being truncated. This is an application design error.