Log Service allows you to reindex logs for a Logstore after you modify indexing rules or when you need to configure indexes for historical logs. You can reindex the logs of a specified time range for a Logstore based on the most recent indexing rules. This topic describes how to reindex logs for a Logstore in the Log Service console.

Prerequisites

The indexing feature is enabled. For more information, see Configure indexes.

Limits

  • You can reindex only the logs that are generated within 15 minutes to 30 days earlier than the current time.
  • You can create a maximum of 10 reindexing tasks.
  • You can run only one reindexing task at a time.

Billing

  • Additional indexing fees and storage fees are generated when you reindex logs. Indexing fees are generated only once and storage fees are generated on an hourly basis. The unit price of a reindex is the same as the unit price of an index. For more information, see Billable items.
  • After you delete a reindexing task, the new index data is also deleted, you are no longer charged storage fees for the deleted index data.

Procedure

  1. Log on to the Log Service console.
  2. In the Projects section, click the name of the project that you want to view.
  3. Choose Log Storage > Logstores. On the Logstores tab, click the Logstore that you want to view.
  4. Choose Index Attributes > Reindex.
    Reindex
  5. In the Reindex panel, click Create Task.
  6. In the dialog box that appears, set the Task Name, Start Time and End Time parameters. Then, click OK.

    The Start Time parameter specifies the time when Log Service starts to receive logs. The End Time parameter specifies the time when Log Service stops receiving logs. The start time and end time must be within 15 minutes to 30 days earlier than the current time.

    After you create the task, you can view the reindexing progress. When the progress reaches 100%, the reindexing task is completed.

Related operations

After you create a reindexing task, you can perform the following operations:

  • Stop the reindexing task.
    In the Reindex panel, click Stop to stop the reindexing task.
    Notice After you stop the reindexing task, you can delete the reindexing task but cannot start it again. Proceed with caution.
  • Delete the reindexing task
    In the Reindex panel, click Delete to delete the reindexing task.
    Notice After you delete the reindexing task, the new index data is also deleted. Proceed with caution.