> For the complete documentation index, see [llms.txt](https://docs.islandrouter.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.islandrouter.com/island-router-cli-2.3.2/commands/clear-syslog.md).

# clear syslog

Deletes a system log file.

## Syntax

```
clear syslog [<directory>] <file>
```

## Syntax Description

<table><thead><tr><th width="203">Keyword</th><th>Description</th></tr></thead><tbody><tr><td>directory</td><td>(Optional)The log directory containing the log file.</td></tr><tr><td>file</td><td>The name of the file to be deleted.</td></tr></tbody></table>

## Defaults

If is not specified, the top-level log directory is assumed.

## Usage Guidelines

This command deletes a system log file.

&#x20;To see a list of system log files, use the `show syslog ?` command.

## Examples

```
clear syslog backup.log
clear syslog slog 20240514-151755
```

## Related Commands

{% content-ref url="/pages/uoSfg7pzZjhUhgKPr0tt" %}
[show syslog](https://docs.islandrouter.com/island-router-cli-2.3.2/commands/show-syslog.md)
{% endcontent-ref %}

{% content-ref url="/pages/m5afi8XUpJOEZiR3etGE" %}
[write syslog](https://docs.islandrouter.com/island-router-cli-2.3.2/commands/write/write-syslog.md)
{% endcontent-ref %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.islandrouter.com/island-router-cli-2.3.2/commands/clear-syslog.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
