Hello Rogerio,
I am not exactly sure what you are trying to do: I mean is the
java program processing a file and sending the email ot is the shell script? Do you have a way of making your program produce a log file with what is going?
If an email is truncated there maybe a number of reasons for that happening:
1) Your program fails, despite the fact that you have tested it and it worked, you are not there when it runs (I assume). You need a log file.
2) Your program terminates processing abnormally for that specific email. It may be just that one not every single one, again you need a log file.
3) The mail server virus scanner maybe stripping lines, but that would generally produce a message for the recepient identifying what has happened and why.
4) many more reason are also possible.
Post a piece of code or an example if you need direction.
Thanks.