> For the complete documentation index, see [llms.txt](https://docs.nexthink.com/platform/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.nexthink.com/platform/ja/references/investigating-storage-disks-and-volumes.md).

# ストレージ、ディスク、およびボリュームの調査

### ディスク <a href="#investigatingstorage-disksandvolumes-disk" id="investigatingstorage-disksandvolumes-disk"></a>

ディスクとは、コンピュータの物理的なストレージデバイスを指します。ただし、論理的なストレージデバイスを表すこともでき、これが1つ以上の物理ディスクにまたがる場合があります。例えば、RAID（Redundant Array of Independent Disks）構成は、複数の物理ディスクを組み合わせて単一の論理ディスクを形成し、パフォーマンスの向上や冗長性、あるいはその両方を提供します。

**Windows**

Disk Managementアプリケーションでは、システムが物理ドライブをディスクと呼び、`Disk 0`、`Disk 1`、...というラベルを付けます。このPCでは、システムがこれらのストレージデバイスにドライブ文字（`C:`、`D:`、...）を割り当てます。

これらのデバイスは、ローカルディスク、USBドライブ、または仮想ディスクなどの種類が異なることがあります。

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-640afe4e544bc38d2b79da9a12d032008a6e04f8%2Fscreenshot-2023-03-30-at-14-07-24.png?alt=media" alt="" width="544"><figcaption></figcaption></figure>

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-f8504b282debf81baa5f7db93c0b65a4e37bccfd%2Fscreenshot-2023-03-30-at-14-08-45.png?alt=media" alt="" width="340"><figcaption></figcaption></figure>

**macOS**

Disk Utilityアプリケーションでは、システムが物理ドライブをメディアと呼び、トップレベルのエントリとして表示されます。システムはそれらを内部または外部として分類し、`disk0`、`disk1`、...というラベルを付けます。

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-fef041e38bebd81f4de58043e71b3a3d493214aa%2Fnxcheseaux-20230419-171420-2x-20230419-151421.png?alt=media" alt="" width="544"><figcaption></figcaption></figure>

`diskutil list`コマンドを使用して、すべてのデバイスを`/dev/disk0`、`/dev/disk1`、...のように表示できます。

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-bfcda09acaea0c1ee6f9bbc78a29aaad9e992960%2Fscreenshot-2023-03-30-at-14-11-19.png?alt=media" alt=""><figcaption></figcaption></figure>

### ボリューム <a href="#investigatingstorage-disksandvolumes-volume" id="investigatingstorage-disksandvolumes-volume"></a>

ボリュームは、データを整理および管理するためにディスク内の記憶単位を指します。それは論理パーティションとして機能し、ファイルシステムでフォーマットすることができ、ユーザーがファイルを保存およびアクセス可能にします。単一のディスクに複数のボリュームが含まれる場合がありますが、各ボリュームは独立して動作し、ストレージシステムに追加の柔軟性と整理を提供します。

**Windows**

Windowsでは、Disk Managementアプリケーションで、システムがボリュームをボリュームとして一覧表示します。

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-3cfffcc7a12b1fedb8956ac75ecc4b99b007c626%2Fnxcheseaux-20230419-170847-2x-20230419-150922.png?alt=media" alt=""><figcaption></figcaption></figure>

**macOS**

Disk Utilityアプリケーションでは、システムがそれらが属するメディアの下にボリュームを表示します。

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-1266062905c11f450121f7e5a98d5128b159deae%2Fnxcheseaux-20230419-171303-2x-20230419-151304.png?alt=media" alt="" width="544"><figcaption></figcaption></figure>

macOSでの`diskutil list`コマンドを使用すると、ボリュームがそれぞれのディスクドライブの下に表示され、`/dev/disk0s1`、`/dev/disk0s2`のような識別子が付けられます。

<figure><img src="https://3549141153-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FeLm8O7QKZDn6z806e7Sv%2Fuploads%2Fgit-blob-bfcda09acaea0c1ee6f9bbc78a29aaad9e992960%2Fscreenshot-2023-03-30-at-14-11-19.png?alt=media" alt=""><figcaption></figcaption></figure>

### NQL例 <a href="#investigatingstorage-disksandvolumes-nqlexamples" id="investigatingstorage-disksandvolumes-nqlexamples"></a>

<details>

<summary>デバイス上のシステムドライブ（ボリューム/パーティション）の空きスペースを一覧表示します。</summary>

{% code overflow="wrap" lineNumbers="true" %}

```
devices during past 7d
| include volumes 
| where system == true 
| compute system_drive_free_space = capacity.sum() * (1 - usage.sum()) 
| list device.name, system_drive_free_space
```

{% endcode %}

</details>

<details>

<summary>デバイス上のシステムドライブの使用状況を一覧表示します。</summary>

{% code overflow="wrap" lineNumbers="true" %}

```
devices during past 7d 
| include device_performance.events during past 7d 
| compute system_drive_used = event.system_drive_usage.avg() 
| list device.name, system_drive_used 
| sort system_drive_used desc
```

{% endcode %}

</details>

<details>

<summary>システムドライブに空きが5GB未満のデバイスを一覧表示します。</summary>

{% code overflow="wrap" lineNumbers="true" %}

```
devices during past 7d
| include volumes 
| where system == true 
| compute system_drive_free_space = capacity.sum() * (1 - usage.sum()) 
| where system_drive_free_space < 5000000000 
| list device.name, system_drive_free_space
```

{% endcode %}

</details>

<details>

<summary>デバイスのディスクとボリュームの概要を一覧表示します。</summary>

{% code overflow="wrap" lineNumbers="true" %}

```
devices during past 7d 
| list device.name, disks, volumes 
```

{% endcode %}

</details>

<details>

<summary>すべてのデバイスからのすべてのディスクのサイズ、起動可能状態、およびタイプ（SSDまたはHDD）を一覧表示します。</summary>

{% code overflow="wrap" lineNumbers="true" %}

```
disks
| list device.name, name, is_bootable, capacity , type 
```

{% endcode %}

</details>


---

# 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.nexthink.com/platform/ja/references/investigating-storage-disks-and-volumes.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.
