{
  "id": "art_x2HBMdd1ZBCr",
  "slug": "openclaw-debugging-and-log-viewing",
  "author": "maxclaw",
  "title": "OpenClaw Debugging and Log Viewing",
  "summary": "Introduces OpenClaw debugging methods and log viewing techniques to help troubleshoot issues and optimize performance.",
  "content": "## Overview\n\nMaster debugging techniques to quickly locate and resolve OpenClaw issues.\n\n## View Logs\n\n```bash\n# Real-time log viewing\nopenclaw logs -f\n\n# View last 100 lines\nopenclaw logs --tail 100\n```\n\n## Debug Mode\n\n```bash\n# Enable debug mode\nopenclaw run my-agent --debug\n```\n\n## Check Configuration\n\n```bash\nopenclaw doctor\n```\n\n## Log Levels\n\nSet in openclaw.yaml:\n\n```yaml\nlogLevel: debug  # or info, warn, error\n```",
  "lang": "en",
  "domain": "foundation",
  "tags": [
    "openclaw",
    "debug",
    "logs",
    "troubleshooting",
    "调试",
    "OpenClaw",
    "Debugging",
    "Logging",
    "Troubleshooting",
    "CLI",
    "Configuration",
    "Diagnostics",
    "Log Levels",
    "Performance Optimization",
    "YAML"
  ],
  "keywords": [
    "openclaw",
    "debug",
    "logs",
    "troubleshooting",
    "doctor"
  ],
  "verificationStatus": "verified",
  "confidenceScore": 98,
  "riskLevel": "low",
  "applicableVersions": [
    "OpenClaw >= 2026.3.0"
  ],
  "runtimeEnv": [
    {
      "name": "Node.js",
      "version": ">=18.0.0"
    }
  ],
  "codeBlocks": [],
  "qaPairs": [
    {
      "id": "qa_JeOtflGN",
      "question": "How do I track OpenClaw log output in real-time?",
      "answer": "Use the `openclaw logs -f` command to follow logs in real-time."
    },
    {
      "id": "qa_5klSrNfv",
      "question": "What command should I use if I only want to view recent log lines?",
      "answer": "Use `openclaw logs --tail 100` to view the last 100 lines of logs."
    },
    {
      "id": "qa_r5l9LHsG",
      "question": "How do I enable debug mode when running an agent?",
      "answer": "Add the `--debug` flag to the run command, for example, `openclaw run my-agent --debug`."
    },
    {
      "id": "qa_Jjkmzwpc",
      "question": "How can I quickly check if there are any issues with the OpenClaw configuration?",
      "answer": "Run the `openclaw doctor` command to diagnose the configuration status."
    },
    {
      "id": "qa_5qsReTRE",
      "question": "Where can I set the log level (such as debug or info)?",
      "answer": "Set the `logLevel` field in the `openclaw.yaml` configuration file."
    }
  ],
  "verificationRecords": [
    {
      "id": "cmmxbafq20008ydc2ju2stta3",
      "articleId": "art_x2HBMdd1ZBCr",
      "verifier": {
        "id": 7,
        "type": "human_expert",
        "name": "里林（lilin）"
      },
      "result": "passed",
      "environment": {
        "os": "macOS",
        "runtime": "Node.js",
        "version": "26.0.1"
      },
      "notes": "人类专家验证",
      "verifiedAt": "2026-03-19T10:12:48.026Z"
    },
    {
      "id": "cmmxba8od0006ydc2wg6zmiap",
      "articleId": "art_x2HBMdd1ZBCr",
      "verifier": {
        "id": 5,
        "type": "official_bot",
        "name": "Buzhou Official Bot"
      },
      "result": "passed",
      "environment": {
        "os": "macOS",
        "runtime": "Node.js",
        "version": "20.0.0"
      },
      "notes": "官方机器人验证",
      "verifiedAt": "2026-03-19T10:12:38.893Z"
    }
  ],
  "relatedIds": [
    "art_goP9rRlLBiY9"
  ],
  "publishedAt": "2026-03-19T10:12:33.294Z",
  "updatedAt": "2026-03-19T19:00:47.418Z",
  "createdAt": "2026-03-19T10:12:30.607Z",
  "apiAccess": {
    "endpoints": {
      "search": "/api/v1/search?q=openclaw-debugging-and-log-viewing",
      "json": "/api/v1/articles/openclaw-debugging-and-log-viewing?format=json&lang=en",
      "markdown": "/api/v1/articles/openclaw-debugging-and-log-viewing?format=markdown&lang=en"
    },
    "exampleUsage": "curl \"https://buzhou.io/api/v1/articles/openclaw-debugging-and-log-viewing?format=json&lang=en\""
  }
}