Wirting a perl script (actually I'm done writing it, just tweaking it now) and need some help.
Perl version is 5.002, under Solaris 2.6.
What the script does:
1) opens a output file (.tmp_output)
2) telnets into one of our products (a core switch)
3) runs a few commands
4) does some error checking on the output, displaying the results within the screen (there is quite a bit of info that gets displayed, so the error checking just displays an 'OK' or a 'error' message on the screen)
5) exits the telnet session
So far, everything is working great. As the .tmp_output file has quite a bit of info in it, and the script only displays 'OK' or 'error', what I want to do is have a term window open and tail the file so the user can look that the .tmp_outfile when there is an error.
Under a shell prompt, this is easy enough: tail -f .tmp_output & . Trying to do this in perl. What I have in the script is system (`xterm -e tail -f .tmp_output &`); , which opens a xterm window just fine, but nothing gets displayed. It also just stops there, waiting for the xterm window to be closed. Want the script to continue running while the term window is still open.
And forgot to mention... xterm -e tail -f .tmp_output & works just fine from a shell prompt.
Anyone ?