DevPortal

How do I redirect output from Server to text files or logs?


Starting Pramati Server with -redirect option redirects all messages written to System.out to text Files. System.out will be written to stdOut.log, System.err will be written to stdErr.log. Both these log files can be found in the <install_dir>/server/node/<node_name>/logs directory.

To start Pramati Server with -redirect option, pass the -redirect switch to script files: runserver.sh/runserver.bat.

Example:

~/builds/1120/Pramati/server/bin
$ ./runserver.sh -redirect & Server's System.out and System.err streams are redirected. They will be written to [stdOut.log] and [stdErr.log] files in directory [/home/prashant/builds/1120/Pramati/server/nodes/default/logs].
~/builds/1120/Pramati/server/nodes/default/logs $ tail -f stdOut.log
3:48:14 PM- Server [default] [ ... ] Type [J2EE] User [root], Realm [system] Mon Nov 14 15:48:14 IST 2005
3:48:14 PM- MBeanServerAgent [ ... ]
3:48:14 PM- MBeanServerAgent [STARTED]
3:48:14 PM- Extension Classloading directory: [/home/prashant/builds/1120/Pramati/server/lib/ext]
3:48:14 PM- Extension Classloader MBean registered ...

Some issues to consider

© Pramati Technologies 2007 Runs on Pramati Server | Feedback | Legal