You have marked the thread "SOLVED"---this means that most people will not see your new question.
First: What happens if you just do this?:
ssh "10.0.2.15" /usr/java/j2sdk1.4.2_03/bin/java -version
It seems that "command 2> filename" does not always work. I'm not sure why