Search Admin Server Logs

You can send a POST request to search the Administration Server logs for records based on severity, time of occurrence, etc. The following steps show how to build this POST request using cURL:
  1. Identify the host name and port of your domain's Administration Server and construct the GET request using the /management/weblogic/{version}/serverRuntime/WLDFRuntime/WLDFAccessRuntime/WLDFDataAccessRuntimes/{name}/search endpoint. This WebLogic Server request uses the following URL structure:
    http://localhost:7001/management/weblogic/{version}/serverRuntime/WLDFRuntime/WLDFAccessRuntime/WLDFDataAccessRuntimes/{name}/search
  2. Specify the headers on the cURL command line:
    • -H X-Requested-By:MyClient

    • -H Accept:application/json

    • -H Content-Type:application/json

  3. Use the -d option to specify the limit (that is, the maximum number of matching records that will be returned) and the set the severity level to 'Info' as shown in the following example.

    -d "{
      limit: 2,
      query: 'SEVERITY = \'Info\''
    }" \

The following sample shows the complete POST request.

curl -v \
--user admin:admin123 \
-H X-Requested-By:MyClient \
-H Accept:application/json \
-H Content-Type:application/json \
-d "{
  limit: 2,
  query: 'SEVERITY = \'Info''
}" \
-X POST http://localhost:7001/management/weblogic/latest/serverRuntime/WLDFRuntime/WLDFAccessRuntime/WLDFDataAccessRuntimes/ServerLog/search

The POST request returns two records that have the severity level, 'Info'.

HTTP/1.1 200 OK

Response Body:
{
"records": [
{
  "RECORDID": 1,
  "DATE": "Oct 4, 2017 8:51:03,931 PM EDT",
  "SEVERITY": "Info",
  "SUBSYSTEM": "Security",
  "MACHINE": "machine1",
  "SERVER": "",
  "THREAD": "main",
  "USERID": "",
  "TXID": "",
  "CONTEXTID": "",
  "TIMESTAMP": "1507164663931",
  "MSGID": "BEA-090905",
  "MESSAGE": "Disabling the CryptoJ JCE Provider self-integrity check for better startup performance. To enable this check, specify -Dweblogic.security.allowCryptoJDefaultJCEVerification=true.",
  "SUPP_ATTRS": "[severity-value: 64] [partition-id: 0] [partition-name: DOMAIN] ",
  "SEVERITY_VALUE": 64,
  "PARTITION_ID": "0",
  "PARTITION_NAME": "DOMAIN",
  "RID": ""
},
{
  "RECORDID": 2,
  "DATE": "Oct 4, 2017 8:51:04,032 PM EDT",
  "SEVERITY": "Info",
  "SUBSYSTEM": "Security",
  "MACHINE": "machine1",
  "SERVER": "",
  "THREAD": "main",
  "USERID": "",
  "TXID": "",
  "CONTEXTID": "",
  "TIMESTAMP": "1507164664032",
  "MSGID": "BEA-090906",
  "MESSAGE": "Changing the default Random Number Generator in RSA CryptoJ from ECDRBG128 to HMACDRBG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true.",
  "SUPP_ATTRS": "[severity-value: 64] [partition-id: 0] [partition-name: DOMAIN] ",
  "SEVERITY_VALUE": 64,
  "PARTITION_ID": "0",
  "PARTITION_NAME": "DOMAIN",
  "RID": ""
}],
"nextRecordId": 3
}