
---
url: /mod/smart.md
---
# x smart

smartctl is a tool for control and monitor disks, used to check disk health, including SMART (Self-Monitoring, Analysis, and Reporting Technology) data.

This module aims to help users quickly use the smartctl tool without installation and provides an interactive way to list local disk devices, making it easy for users to choose the disk they want to check.


::: tip
The smartctl command needs to be run with root privileges to allow access to the disk's SMART data.

If you are a Linux user, the sudo module will be automatically invoked to run the command, without the need to add the sudo prefix
:::


## Examples

List all available disk paths

```sh
x smart --ls
```

Open an interactive UI to choose the disk and display all SMART information

```sh
x smart
```

displays all SMART information of the disk /dev/disk0 in macOS

```sh
x smart -a /dev/disk0
```

Generate a report using Gemini based on the SMART information of the disk

```sh
x smart -a /dev/disk0 | @gemini generate a report
```

Open an interactive Gemini session to discuss the SMART information of the disk

```sh
x smart -a /dev/disk0 | @gemini
```

Search the smartmontools.com website for content related to "disk health" and display the search results in an interactive table format.

```sh
x smart : disk health
```

## Sub Commands

| Name | Description |
| ------- | ------- |
| [x smart --app](/mod/smart/--app.md) | Display all SMART information for the disk interactively |
| [x smart --ls](/mod/smart/--ls.md) | List available disk paths |
| [x smart ddgo](/mod/smart/ddgo.md) | Search for relevant information on the smartmontools.com website using DuckDuckGo |
