• No results found

Scenario: Automating Web Log Analysis Reports— Conserving System Resources

For this scenario, you are running Microsoft IIS and rotate your log files daily.

You have a drive mapped to your web server, and you need to run reports on a daily and monthly basis.

Note: Follow these steps if your system has limited free disk space and the speed at which the reports are generated is not an issue.

Step 1: Create two separate log analysis profiles with FastTrends cache turned off. One of the profiles should specify the previous day’s log, the other should specify the daily logs.

Step 2: Memorize report settings specifying the last month’s activity for the date range.

Step 3: Create two scheduled events, one based on the “daily” log analysis profile, and one based on the “all” log analysis profile with the “monthly”

memorized report settings.

Adding a Log Analysis Profile for Scheduled Reports

Your first step is to identify the location and method of processing your web server log file.

For more detailed explanations of each of the options, see Adding a Web Log Analysis Profile on page 28.

1. Click New in the WebTrends main console to add a new log analysis profile. The Add Log Profile-- Title, URL dialog appears.

2. Enter a description for the log analysis profile that identifies it as one specifying all of your log files in the LOGFILES directory.

3. In the Log File URL Path field, enter the location of the server log file.

In this case, use the * wildcard to include all of the log files in the directory:

P:\WINNT\SYSTEM32\LOGFILES\*.LOG

For more information about the format, location and definition of Web server log files in WebTrends log analysis profiles, see Understanding Log Files on page 16.

For more information about date file name macros, see the File Name Macros section on page 37.

4. Click Next. The Add Web Log Profile -- DNS Lookup dialog appears.

5. Select Resolve Mode to have WebTrends resolve all IP addresses which may not have been converted by the server.

6. Click Next >. The Add Web Log Profile -- Home Page dialog appears.

7. Identify the location and file name of your site’s home page. For example:

P:\WINNT\SYSTEM32\… and DEFAULT.HTM

8. Click Next. The Filters dialog appears. Since you want to report on all of your web site’s activity, click Next> again accept the default Include Everything filter. The Database and Real-Time dialog appears.

9. Make sure the FastTrends Cache box is not checked.

For more information about the real-time analysis and reporting options, see Chapter 7. FastTrends and Real Time Reporting on page 83.

10. Click Finish to save your log analysis profile settings.

Note: To speed up reporting, check your Log Cache options in the Web Log Analysis options dialog. Select either Download the log file once and keep it for subsequent reports or

Download the log file only when changes are detected in the remote log file.

Memorizing Settings for Scheduled Reports

Now that you have added your log analysis profiles, you are ready to memorize the report settings that you want the scheduler to use.

As long as you accept the default report settings (format, language, style, save as information), you only need to memorize report settings for the monthly reports; the log analysis profile for the daily reports already identifies the proper range (yesterday’s log file).

1. From the WebTrends main console, highlight the “daily” log analysis profile to select it.

2. Click Report.

3. In the Create Report window, select Last Month from the drop-down list in the Report Range field.

4. Select the Save As/Mail To tab to specify the location in which to save your reports. Use the date file name macros to identify a variable destination file name based on the month (for example,

“… \%mm%%yy%.htm).

For more information about date file name macros, see the File Name Macros section on page 37.

5. Click Memorize to save your settings. The Memorize Report dialog appears.

6. Enter a descriptive name for these report settings.

Scheduling Web Log Analysis Reports

Now that you have your profiles and memorized report settings prepared, you are ready to define your scheduled reports.

Adding a Scheduled Report

Now that you have your log analysis profiles and memorized report settings, you are ready to set up the scheduled reports.

To create scheduled events, complete the following steps:

1. Click Scheduler.

2. Click Add in the main scheduler window to add a new scheduled event.

The Schedule Report window appears.

3. Select the default Complete Summary from the Memorized Type list.

Note: You can modify existing memorized report settings or create new ones by clicking on the New button next to the Memorized Type field.

4. Select your “daily” log analysis profile from the Profile Description drop-down list.

5. To have the report run every morning at 2 a.m., enter 02:00:00 (hh:mm:ss) in the Start Time field.

6. In the Repeat Every fields, type “1” and then click and select “Day(s)”

in the second field. 7. In the Save Report To: field you can override the Save As/Mail To values as saved in the Memorized Report Settings. See Creating a Log Analysis Report on page 33.

See Email Options on page 124 for more information about enabling and configuring the WebTrends e-mail feature.

Tip:

You can use the date file name macros in the Save Report To:

field. For more information, see File Name Macros on page 37.

8. Click Save to save your scheduled event.

You are returned to the main Scheduler window, and your scheduled event appears in the scheduled report list.

9. Click OK to return to the WebTrends main console.