That makes sense. It's not stuck in an endless loop, it's waiting for some input.
So how do I tell it to read from a file, one line at a time and then "do" something with each line. On the version of the script that's working, I don't have to enter any input. That's all done from the crontab, which starts a small script that stops the server, rotates the logs, then calls another script to analyze the logs, with the inputs specified by the small script
./analyzelogs domains.txt
with all the "domain.coms" listed in the .txt file.
|