Subject: Re: Warning message: Why do I care?
To: Peter Seebach <>
From: Steven M. Bellovin <>
List: current-users
Date: 07/19/2002 10:43:49
In message <>, Peter Seebach writes
>set{u,g}id pid 1699 (df) was invoked by uid 100 ppid 369 (perl) with fd 0 clos
>I have a perl script which runs as a daemon (disconnected from stdin, stdout),
>and which wants to use df.
>Why on earth is it bad to do this?  What is this warning trying to warn me of?
You should open /dev/null instead.  

There are programs that open files, then write to stdout or stderr, or 
read from stdin.  If those file descriptors are closed, the new files 
might be assigned to 0, 1, or 2 -- so the program might write Bad 
Things to an important file.

		--Steve Bellovin, (me) ("Firewalls" book)