Monday, December 23, 2013

Unix/Linux log script outputs to a file

In any scripts that print something out, the simplest way to capture those printed stuffs is to append with

>> logfilename.log 2>&1 

All the outputs (stdout, stderr) will be redirect to file logfilename.log. To learn this in details, search for something like "unix stdout redirection"

No comments:

Useful commands for observe running JVM process

$ jcmd List running processes $ jinfo  Get details of a process $ jps -lvm List running processes with params