{
  "run_id": "2026-09-23-r3-serper",
  "round": 2,
  "tool": "serper",
  "mode": "search",
  "tc_id": "TC3",
  "capability": "C1",
  "scenario": "S3",
  "suite_role": "probe",
  "query_text": "In Loki, the log aggregation system from Grafana Labs, which configuration block does retention_enabled have to be set in for old log data to actually be deleted?",
  "restrict_domain": null,
  "restriction_mechanism": null,
  "answer_key": "The compactor block. Verbatim: \"`retention_enabled: true` must be set under the `compactor` block, not just in `limits_config`.\" (FAQ \"Why isn't my log retention policy deleting old data?\", bottom third of the page.)",
  "key_urls": [
    {
      "url": "https://grafana.com/docs/loki/",
      "role": "supports"
    },
    {
      "url": "https://grafana.com/oss/loki/",
      "role": "supports"
    }
  ],
  "pass_criteria": "Results are about Grafana Loki, not Marvel's Loki, AND what came back names the compactor block - not merely the top-of-page description of what Loki is",
  "key_verified_date": "2026-09-09",
  "before_check_rule": null,
  "timestamp_utc": "2026-09-23T09:18:32Z",
  "region": "ap-south-1",
  "status": "ok",
  "graded": null,
  "pass_fail": null,
  "grader_notes": null,
  "latency_ms": 2644.7,
  "http_status": 200,
  "error": null,
  "attempts": 1,
  "credits_reported": null,
  "tokens_reported": null,
  "results": [
    {
      "rank": 1,
      "url": "https://grafana.com/docs/loki/latest/operations/storage/retention/",
      "title": "Log retention | Grafana Loki documentation",
      "content": "Retention in Grafana Loki is achieved through the Compactor. By default the compactor.retention-enabled flag is not set, so the logs sent to Loki live forever.",
      "content_chars": 159,
      "published_date": null
    },
    {
      "rank": 2,
      "url": "https://community.grafana.com/t/loki-log-retention-policy-and-period/153531",
      "title": "Loki log retention policy and period - Grafana community forums",
      "content": "I have configured a log retention policy in Loki to store logs for 30days, but someway somehow my logs are being kept for only 10 days. here ...",
      "content_chars": 144,
      "published_date": "Jun 27, 2025"
    },
    {
      "rank": 3,
      "url": "https://community.grafana.com/t/loki-does-not-delete-logs-after-retention-delete-delay/81898",
      "title": "Loki does not delete logs after retention delete delay",
      "content": "Checking on Grafana after five minutes but the logs are still there. I maybe is the retention_delete_delay that should not be set to 5 minutes?",
      "content_chars": 143,
      "published_date": "Feb 16, 2023"
    },
    {
      "rank": 4,
      "url": "https://grafana.com/docs/loki/latest/operations/storage/logs-deletion/",
      "title": "Log entry deletion | Grafana Loki documentation",
      "content": "Configuration. Enable log entry deletion by setting retention_enabled to true in the compactor's configuration ( -compactor.retention-enabled on the command ...",
      "content_chars": 160,
      "published_date": null
    },
    {
      "rank": 5,
      "url": "https://www.youtube.com/watch?v=h_GGd7HfKQ8",
      "title": "Meet Grafana LOKI, a Log Aggregation System for EVERYTHING",
      "content": "I've been on a quest to find a new logging system. I've use quite a few in the past, some open source, some proprietary, and some home grown ...",
      "content_chars": 144,
      "published_date": "4 years ago"
    },
    {
      "rank": 6,
      "url": "https://community.grafana.com/t/how-grafana-loki-retention-works/67754",
      "title": "How Grafana Loki retention works",
      "content": "I would like to set up retention for logs stored in Grafana Loki and I am not sure how the retention really works. There is more period time ...",
      "content_chars": 144,
      "published_date": "Jun 26, 2022"
    },
    {
      "rank": 7,
      "url": "https://oneuptime.com/blog/post/2026-01-30-loki-retention-strategies/view",
      "title": "How to Implement Loki Retention Strategies",
      "content": "Managing log retention in Grafana Loki requires understanding how Loki stores data and which components handle deletion.",
      "content_chars": 120,
      "published_date": "Jan 30, 2026"
    },
    {
      "rank": 8,
      "url": "https://community.grafana.com/t/loki-retention-policy-and-chunk-deletion-issue/159057",
      "title": "LOKI Retention Policy and Chunk Deletion Issue",
      "content": "How can we make sure chunks are actually deleted after retention (and not just marked)?. Is there a better approach to enforce retention-based ...",
      "content_chars": 146,
      "published_date": "Nov 3, 2025"
    },
    {
      "rank": 9,
      "url": "https://community.grafana.com/t/log-retention-policy/116009",
      "title": "Log retention policy - Grafana Loki",
      "content": "Despite the configuration file specifying a retention period of 'period: 24h', I'm seeing old logs persisting. Can you help clarify the ...",
      "content_chars": 139,
      "published_date": "Mar 4, 2024"
    },
    {
      "rank": 10,
      "url": "https://medium.com/@aditya.hilman_10961/enabling-log-retention-in-loki-with-compactor-fe3de2002b47",
      "title": "Enabling Log Retention in Loki with Compactor",
      "content": "compactor.retention_enabled: true Enables the retention policy enforcement in Loki. Without this, the compactor will not delete old logs.",
      "content_chars": 137,
      "published_date": null
    }
  ],
  "answer_text": null,
  "citations": [],
  "raw_response": {
    "searchParameters": {
      "q": "In Loki, the log aggregation system from Grafana Labs, which configuration block does retention_enabled have to be set in for old log data to actually be deleted?",
      "type": "search",
      "num": 10,
      "engine": "google"
    },
    "organic": [
      {
        "title": "Log retention | Grafana Loki documentation",
        "link": "https://grafana.com/docs/loki/latest/operations/storage/retention/",
        "snippet": "Retention in Grafana Loki is achieved through the Compactor. By default the compactor.retention-enabled flag is not set, so the logs sent to Loki live forever.",
        "position": 1
      },
      {
        "title": "Loki log retention policy and period - Grafana community forums",
        "link": "https://community.grafana.com/t/loki-log-retention-policy-and-period/153531",
        "snippet": "I have configured a log retention policy in Loki to store logs for 30days, but someway somehow my logs are being kept for only 10 days. here ...",
        "date": "Jun 27, 2025",
        "position": 2
      },
      {
        "title": "Loki does not delete logs after retention delete delay",
        "link": "https://community.grafana.com/t/loki-does-not-delete-logs-after-retention-delete-delay/81898",
        "snippet": "Checking on Grafana after five minutes but the logs are still there. I maybe is the retention_delete_delay that should not be set to 5 minutes?",
        "date": "Feb 16, 2023",
        "position": 3
      },
      {
        "title": "Log entry deletion | Grafana Loki documentation",
        "link": "https://grafana.com/docs/loki/latest/operations/storage/logs-deletion/",
        "snippet": "Configuration. Enable log entry deletion by setting retention_enabled to true in the compactor's configuration ( -compactor.retention-enabled on the command ...",
        "position": 4
      },
      {
        "title": "Meet Grafana LOKI, a Log Aggregation System for EVERYTHING",
        "link": "https://www.youtube.com/watch?v=h_GGd7HfKQ8",
        "snippet": "I've been on a quest to find a new logging system. I've use quite a few in the past, some open source, some proprietary, and some home grown ...",
        "date": "4 years ago",
        "position": 5
      },
      {
        "title": "How Grafana Loki retention works",
        "link": "https://community.grafana.com/t/how-grafana-loki-retention-works/67754",
        "snippet": "I would like to set up retention for logs stored in Grafana Loki and I am not sure how the retention really works. There is more period time ...",
        "date": "Jun 26, 2022",
        "position": 6
      },
      {
        "title": "How to Implement Loki Retention Strategies",
        "link": "https://oneuptime.com/blog/post/2026-01-30-loki-retention-strategies/view",
        "snippet": "Managing log retention in Grafana Loki requires understanding how Loki stores data and which components handle deletion.",
        "date": "Jan 30, 2026",
        "position": 7
      },
      {
        "title": "LOKI Retention Policy and Chunk Deletion Issue",
        "link": "https://community.grafana.com/t/loki-retention-policy-and-chunk-deletion-issue/159057",
        "snippet": "How can we make sure chunks are actually deleted after retention (and not just marked)?. Is there a better approach to enforce retention-based ...",
        "date": "Nov 3, 2025",
        "position": 8
      },
      {
        "title": "Log retention policy - Grafana Loki",
        "link": "https://community.grafana.com/t/log-retention-policy/116009",
        "snippet": "Despite the configuration file specifying a retention period of 'period: 24h', I'm seeing old logs persisting. Can you help clarify the ...",
        "date": "Mar 4, 2024",
        "position": 9
      },
      {
        "title": "Enabling Log Retention in Loki with Compactor",
        "link": "https://medium.com/@aditya.hilman_10961/enabling-log-retention-in-loki-with-compactor-fe3de2002b47",
        "snippet": "compactor.retention_enabled: true Enables the retention policy enforcement in Loki. Without this, the compactor will not delete old logs.",
        "position": 10
      }
    ],
    "peopleAlsoAsk": [
      {
        "question": "Is Grafana Loki deprecated?"
      },
      {
        "question": "What is the standard retention period for logs?"
      },
      {
        "question": "What is a retention policy for logs?"
      },
      {
        "question": "What is the difference between Grafana and Loki?"
      }
    ],
    "relatedSearches": [
      {
        "query": "Loki delete logs"
      },
      {
        "query": "Loki log retention"
      },
      {
        "query": "Loki/compactor config"
      },
      {
        "query": "Loki log retention S3"
      },
      {
        "query": "Grafana Loki configuration"
      },
      {
        "query": "Grafana Loki compactor"
      },
      {
        "query": "Loki delete_request_store"
      },
      {
        "query": "Loki retention_delete_delay"
      }
    ],
    "credits": 1
  }
}