February 7, 2017

[HDGEM] Location of Java Fatal Error Log

If the -XX:ErrorFile= file flag is not specified, by default the file name is hs_err_pid pid .log, where pid is the process ID of the process.


In addition, if the -XX:ErrorFile= file flag is not specified, the system attempts to create the file in the working directory of the process. In the event that the file cannot be created in the working directory (insufficient space, permission problem, or other issue), the file is created in the temporary directory for the operating system. On Solaris OS and Linux the temporary directory is /tmp. On Windows the temporary directory is specified by the value of the TMP environment variable; if that environment variable is not defined, the value of the TEMP environment variable is used.

The product flag -XX:ErrorFile= file can be used to specify where the file will be created, where file represents the full path for the file location. The substring %% in the file variable is converted to %, and the substring %p is converted to the process ID of the process.

In the following example, the error log file will be written to the directory /var/log/java and will be named java_error pid .log.
          java -XX:ErrorFile=/var/log/java/java_error%p.log


--
Posted By Blogger to HDGEM at 2/07/2017 12:40:00 PM
Post a Comment

Featured Post

Updated Coupons / promo codes for Google Apps for Work / Business

To redeem: 1. Sign up for Google Apps   2. Go to your billing settings  3. Choose your payment plan  4. Enter your promo code ...