When Angelfish processes a log file, it needs know the contents and position of each field in the log. Angelfish gets this information from the log format assigned to each Datasource.
If your log file format doesn't match one of the predefined log formats, you'll need to create a custom log format. The Log Format utility can be accessed by Angelfish admins in Configure - Global - Log Formats.
Creating a Custom Log Format
Log formats are space delimited, with specific fields surrounded by quotes. Use the dropdown to select a field and click the arrow to move it into the log format box.
Once you create your custom log format, copy and paste a single log line into the "Test Log Format" field and click the Test button. If the utility is able to successfully parse the log line and the data & fields match, then the format is correct.
Here's a sample log line:
18.104.22.168 analyticsmarket.com - [23/Oct/2012:12:02:03 -0500] "GET /blog/google-analytics-vs-log-files HTTP/1.1" 200 186 "http://www.analyticsmarket.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/536.26.14 (KHTML, like Gecko) Version/6.0.1 Safari/536.26.14" "JSESSIONID=a1eea565c4b83f8ba94c8ba2a285c8fb" 23Q12 "f5 failover"
Here's an example of a custom log format that will parse the above line. Please note how the quote-encapsulated fields in the log line match the quote-encapsulated fields in the custom log format:
%a %h %* %t "%r" %s %b "%R" "%ua" "%c" %* "%*"
If you get stuck, please let us know! Our support team will help you create a custom log format quickly.
|Ignore Field (%*)||The contents of the field will be ignored.|
|Client IP (%a)||IP Address of the remote client.|
|Hostname (%h)||Server Hostname.|
|Username (%u)||Username making the requests, present if user is authenticated.|
|Date (%d)||The date of the request.|
|Time (%T)||Timestamp of request|
|Date & Time (%t)||A combined date/timestamp, common in Apache logs.|
|Request (%r)||The full request made by the client. (a.k.a. cs-request)|
|Request Stem (%U)||Stem of the requested resource.|
|Request Query (%q)||The string of data appended to the page stem in the resource request.|
|Method (%m)||The method used to request the resources, i.e. GET, POST, or HEAD.|
|Status Code (%s)||Status code.|
|Bytes (%b)||The size of the response in bytes.|
|User-agent (%ua)||User Agent of the client|
|Referrer (%R)||The URL of any referring web page linking the client to the request.|
|Cookies (%c)||Contents of the Cookie field|
|Server IP (%A)||IP Address of the machine serving up the resources for the client requests.|
|Server Name (%v)||Name of the server responding to the request.|
|Port (%p)||The port number on which the server serves the request.|
|Logname (%l)||The remote logname (if supplied).|
|Request Time (%S)||The time taken to serve the request, in seconds.|