Viewing the WebSphere HPEL logs using the logViewer command

Home > Search
  by

The command is to view the HPEL log and HPEL trace log, because these logs are in binary format. In other words, you wouldn't use a text editor to view the HPEL log and HPEL trace log. The LogViewer command converts the HPEL log and HPEL trace log from binary to text. 

  • logViewer.bat (Windows) 
  • logViewer.sh (Linux WAS)
  • logViewer (Linux Liberty) 

 

If you attempt to run the logViewer command outside of the profile directory, such as was_home/bin/logViewer.sh, the -repositoryDir option must be included.

~]# was_home/bin/logViewer.sh -repositoryDir was_home/profiles/your_profile/logs/your_app_server/

 

It is usually much easier to run the logViewer command from the profile directory.

~]# was_home/profiles/profile01/bin/logViewer.sh
[3/14/18 20:13:23:123 CDT] 0000009f ServletWrappe I com.ibm.webcontainer.servlet.ServletWrapper init SRV0242EI: [Beta_war] [/beta] [com.main.servlet.Results]: Initialization successful. 

 


Watch the log in real time

The -monitor option can be used to watch event written to the log in real time.

~]# was_home/profile/your_profile/bin/logViewer.sh -monitor

 


Redirect to text file

The -outLog option can be used to redirect the output of the logViewer command to a text file.

~]# was_home/profile/your_profile/bin/logViewer.sh -outLog /tmp/file1.txt

 


Filter date and time

The -startDate and -stopData option can be used to filter the log to only show events in a certain date and time range.

~]# was_home/profile/your_profile/bin/logViewer.sh -startDate "01/01/2018 09:00:00:000 CDT" -stopDate "01/01/2018 10:00:00:000 CDT"

 


Set log level

The possible log levels are FINE, FINER, FINEST, DETAIL, CONFIG, INFO, AUDIT, WARNING, SEVERE, FATAL.

The -level option can be used to only display events at a certain log level.

~]# was_home/profile/your_profile/bin/logViewer.sh -level FINE

 

 

The -minLevel and -maxLevel options can be used to specify the minimum and maximum log level, so that only events within certain log level are displayed.

~]# was_home/profile/your_profile/bin/logViewer.sh -minLevel WARNING -maxLevel INFO


Add a Comment




We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.




Please enter in the box below so that we can be sure you are a human.




Comments