Please forgive me if the answer to this mystery is obvious. I've got a Perl script running on a Solaris 2.6 server, which processes some data files. At the end of the script I use a system call to sort the final output file, like so:
system(" cat $file | sort -t\\| +1 -2 > $file.out ");
The script normally works fine, and has done so for months. Suddenly this week it has begun to misbehave, depending on the number of data files I'm processing. If I process more than 3 files (about 30mb each) it just skips over the system call, and the "sort" isn't executed. I thought there could be some memory limitation or something like that, but what's puzzling me is that I get no error messages. The script just skips the system call and goes on to the end. I've tried -w, $!, and all that to try and catch any sort of error, but nothing happens. The system call is just ignored. It's weird! I would be very, very grateful for any suggestions.