Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!ucla-cs!oahu!frazier From: frazier@oahu.cs.ucla.edu (Greg Frazier) Newsgroups: comp.lang.perl Subject: Re: Backgrounding a perl program Message-ID: Date: 25 Jun 91 16:19:01 GMT References: <1991Jun24.225506.29103@massey.ac.nz> Sender: usenet@cs.ucla.edu (Mr. News Himself) Organization: UCLA, Computer Science Department Lines: 37 Nntp-Posting-Host: oahu.cs.ucla.edu G.Eustace@massey.ac.nz (Glen Eustace) writes: >If I type the command > mu_quotasummary | more >I get exactly what I wanted. > mu_quotasummary > results & >sits in a Stopped state, awaiting tty input. >I don't read from STDIN or /dev/tty at all. Is there some trick to >getting the program to run in the background. I had wanted to put it >in to crontab to run every week but my first attempts have meet with >little success. Do you have "rsh" commands in your program? I.e. system ("rsh thatmachine doquota"); If you do, it is the "rsh" that wants the tty input. Change the command to system ("rsh thatmachine -n doquota"); This redirects stdin to be from /dev/null on the remote machine, rather than from your keyboard. Yes, I realize that "doquota", or whatever your command is, does not use the keyboard, but "rsh" still tries to grab stdin before calling "doquota". If you don't have "rsh" in your code, then please ignore all of that babble. -- Greg Frazier frazier@CS.UCLA.EDU !{ucbvax,rutgers}!ucla-cs!frazier