Path: utzoo!attcan!uunet!lll-winken!lll-tis!ames!mailrus!uflorida!ukma!rutgers!att!ihlpf!kmk From: kmk@ihlpf.ATT.COM (00704a-Krakman) Newsgroups: comp.unix.questions Subject: administering open files Keywords: UNIX question Message-ID: <6512@ihlpf.ATT.COM> Date: 31 Oct 88 18:41:47 GMT Organization: AT&T Bell Laboratories - Naperville, Illinois Lines: 29 I want to chop down the size of a file that is being written to by a currently running process - actually one that is running out of /etc/inittab and may never die. Here are some possibilities: testprog > logfile & 1) mv logfile old.log >logfile This appears to work but I don't know how it could! When you create the logfile in the second line it should have a different inode than the one the testprog process knows about. So how can the testprog write to the "correct" logfile? 2) To administer the /usr/lib/cron/log file, the UNIX System V Release 3 System Administrator's guide says to put this entry in your cronfile: tail -100 /usr/lib/cron/log > /tmp/log;mv /tmp/log /usr/lib/cron/log If /etc/cron always has this log open (I'm assuming it does), than won't it also be writing to the wrong file? It should have no way of knowing the inode of the "new" /usr/lib/cron/log Thanks ahead of time, Ken Krakman att!ihlpf!kmk