Instead of redirectingusing ">" to redirect like this:
java Foo > log
do it like thisuse ">>" to append normal "stdout" output to a new or existing file:
java Foo >> log
However, if you also want to capture "stderr" errors (That's assuming that's how you're redirectingsuch as why the output. If it's notJava program couldn't be started), please give more details.you should also use the "2>&1" tag which redirects "stderr" (the "2") to "stdout" (the "1"). For example:
java Foo >> log 2>&1