Hi Santhosh,
Answers to your questions:
1. There are lot of files where you can check the java start up logs. The dev_sever<n>.log
file is the best possible log file where you can find the detailed start up logs.
2. Well, from personal experience, it is the java stack which is the "bad kid" among the two. The memory error can be due to a number of reasons. Primarily some of them:
- JVM not being properly loaded - error needs to be analysed.
- Incorrect JVM Memory settings (Need to check the config tool).
For details you can refer
or you can check the note 724452.
On the other note, The best possible solution can be found at http://scn.sap.com/thread/1516744.
Thanks,
Avishek