> ## Documentation Index
> Fetch the complete documentation index at: https://documentation.bearsampp.com/llms.txt
> Use this file to discover all available pages before exploring further.

# View and Use Bearsampp Service Logs

> Learn where Bearsampp stores log files, how to open them from the tray menu, and how to adjust verbosity to diagnose persistent issues.

Logs are the fastest way to understand why a service failed or behaved unexpectedly. Bearsampp records activity for each service it manages, and you can access those logs directly from the tray menu without opening any files manually.

## Where log files are stored

All log files are written to the `bearsampp/logs/` folder. Each service writes to its own file within that directory. You can open these files in any text editor, but using the tray menu shortcuts described below is usually faster.

## Accessing logs from the tray menu

Right-click the Bearsampp tray icon and navigate to the service you want to inspect:

<CardGroup cols={2}>
  <Card title="Apache">
    * **Apache → Access logs** — all incoming HTTP requests
    * **Apache → Error logs** — configuration errors and runtime failures
    * **Apache → Rewrite logs** — URL rewrite rule processing
  </Card>

  <Card title="PHP">
    * **PHP → Logs** — PHP errors, warnings, and notices
  </Card>

  <Card title="MySQL / MariaDB">
    * **MySQL → Access logs** — database connection activity
    * **MySQL → Error logs** — startup failures and query errors
    * **MariaDB → Access logs** — database connection activity
    * **MariaDB → Error logs** — startup failures and query errors
  </Card>

  <Card title="Other services">
    Depending on the module, you may also see:

    * **Session logs** — active session records
    * **Stats logs** — usage statistics
    * **Transfer logs** — file transfer records (Xlight FTP)
  </Card>
</CardGroup>

## Log verbosity levels

Bearsampp supports four verbosity levels that control how much detail is written to log files. You can change the level from the tray menu under **Settings → Logs verbose**, or by editing `bearsampp.conf` directly.

| Level | Name   | What gets logged                              |
| ----- | ------ | --------------------------------------------- |
| `0`   | Simple | Errors only                                   |
| `1`   | Report | Errors and warnings                           |
| `2`   | Debug  | Detailed activity including info messages     |
| `3`   | Trace  | Everything — very verbose, for deep debugging |

<Tip>
  When troubleshooting a persistent issue, switch to **Debug** or **Trace** to capture as much detail as possible. Once the problem is resolved, switch back to **Simple** to keep log files small and easy to scan.
</Tip>

## Controlling log archives

Bearsampp can rotate and archive older logs automatically. The `maxLogsArchives` setting in `bearsampp.conf` controls how many archived log files are kept before older ones are deleted. Set this to a lower number if disk space is a concern, or raise it if you need a longer history for auditing.

## Freeing up disk space

Temporary files can accumulate over time and take up significant disk space. To clear them:

<Steps>
  <Step title="Open the tray menu">
    Right-click the Bearsampp icon in the system tray.
  </Step>

  <Step title="Navigate to Tools">
    Select **Tools → Clear temp folders**.
  </Step>

  <Step title="Confirm">
    Bearsampp removes temporary files immediately. No restart is required.
  </Step>
</Steps>

<Note>
  Clearing temp folders does not affect your project files, databases, or configuration. It only removes internally generated temporary data.
</Note>
