Subj : Re: background scripts To : Jame Clay From : James Vahn Date : Sun Apr 07 2002 10:40 am >> How do you fork a child process from within Perl? I think that's >> the proper terminolgy > > To "fork" a program is to start another copy of itself... Doesn't a daemon do that? The main program returns to the caller with the child still running.. > If you're referring to the startup "init" scripts; that's likely > because they're already being put into the background by the program > that's running them... Nope. That's the problem with my script- it never exits. It does a running tail on the log files looking for things. The init just hangs until I quit the script. If I run it &, then init seems to just kill it right away. For some reason atd will do the job, but that seems like an odd solution. > And btw, I'm curious about what you're doing in the script; for > instance, as far as I know, the "seek" command is byte oriented & not > line oriented... And I think you have last two parameters to it > reversed... The first seeks to EOF. The second seeks back one, the open doesn't see the EOF and the program loops. It works very well, and doesn't use anywhere near the amount of CPU and memory that I thought it would. --- Debian GNU/Linux * Origin: 300 Miles East (1:346/3) .