Skip to content

Commit

Permalink
Fix formatting from GitHub Actions run 73 (#9)
Browse files Browse the repository at this point in the history
* Auto fix formatting from GitHub Actions run 73

Co-authored-by: iBug <[email protected]>
  • Loading branch information
github-actions[bot] and iBug authored Feb 17, 2024
1 parent de4a141 commit 950de1c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 15 deletions.
8 changes: 4 additions & 4 deletions docs/advanced/cuda.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,19 @@ CUDA(Compute Unified Device Architecture)是由 NVIDIA 公司推出的开发

- NCCL:多 GPU 和多节点上的集合通信的库。

- Thrust:类似于 C++标准模板库(`STL`)的并行算法库。
- Thrust:类似于 C++ 标准模板库(`STL`)的并行算法库。

- CUDA Samples: 示例代码,涵盖了基本的`Hello World`程序到更复杂的应用程序。
- CUDA Samples:示例代码,涵盖了基本的`Hello World`程序到更复杂的应用程序。

- NVIDIA Nsight Tools: 集成开发环境和调试工具,用于帮助开发者优化 CUDA 应用程序的性能和可靠性。包括 `Nsight Eclipse Edition``Nsight Visual Studio Edition``Nsight Compute``Nsight Systems`
- NVIDIA Nsight Tools:集成开发环境和调试工具,用于帮助开发者优化 CUDA 应用程序的性能和可靠性。包括 `Nsight Eclipse Edition``Nsight Visual Studio Edition``Nsight Compute``Nsight Systems`

- CUDA Documentation:包括 API 参考、编程指南、最佳实践指南和其他技术资源等

## 配置 CUDA 环境

### 硬件准备

在开始之前,你需要确认显卡是否支持支持 CUDA 。在这里可以查看支持的列表:<https://developer.nvidia.com/CUDA-gpus>
在开始之前,你需要确认显卡是否支持支持 CUDA。在这里可以查看支持的列表:<https://developer.nvidia.com/CUDA-gpus>

表中的`Compute Capability`代表计算能力,同时也表明了 GPU 支持的 CUDA 特性和指令集版本。

Expand Down
18 changes: 9 additions & 9 deletions docs/ops/storage/filesystem.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

可以使用 `lsblk` 命令查看系统中的块设备。一个桌面系统的例子如下:

```console
```text
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
nvme0n1 259:0 0 1.9T 0 disk
├─nvme0n1p1 259:1 0 260M 0 part
Expand Down Expand Up @@ -192,8 +192,8 @@ MBR 信息存储在磁盘的第一个扇区[^sector](512 字节[^sector-size]

首先创建一个空文件:

```console
$ truncate -s 8G test.img
```shell
truncate -s 8G test.img
```

!!! info "稀疏文件"
Expand All @@ -209,10 +209,10 @@ $ truncate -s 8G test.img

之后我们就可以直接操作这个文件,而不用担心破坏真实的磁盘。

```console
$ fdisk test.img
$ # 或者
$ parted test.img
```shell
fdisk test.img
# 或者
parted test.img
```

以下的例子会创建一个 256M 的 EFI 分区,一个 1G 的 swap 分区,剩下的空间作为根文件系统的分区。
Expand Down Expand Up @@ -405,8 +405,8 @@ ext4 最常见的问题之一是 inode 的数量限制。
除此之外,ext4 默认的 5% 保留空间也是常会遇到的问题。这一部分保留空间仅允许 root 用户使用,以在磁盘空间不足时仍保证 root 权限的进程能够正常运行。
但是对于现代的大容量磁盘来说,这一部分空间可能会浪费很多。可以使用 `tune2fs` 命令调整这一参数:

```console
$ sudo tune2fs -m 1 /dev/sda1 # 将保留空间调整为 1%
```shell
sudo tune2fs -m 1 /dev/sda1 # 将保留空间调整为 1%
```

### Btrfs
Expand Down
4 changes: 2 additions & 2 deletions docs/ops/virtualization/qemu-kvm.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ QEMU(Quick Emulator)是一个开源的虚拟化软件,它通过动态二

### KVM

KVM(Kernel-based Virtual Machine)是一种基于Linux内核的开源虚拟化解决方案。KVM将Linux转变成一个虚拟机监视器(Hypervisor)。它利用了现代处理器中的硬件虚拟化支持(例如Intel VT或AMD-V),以实现高性能的虚拟化。它专注于以最小的开销在Linux上提供安全和隔离的虚拟环境,同时维持接近原生的性能。它向用户空间提供了虚拟 CPU 和内存子系统的配置和执行控制相关接口,但 KVM 不包含硬件模型,不能独立构成虚拟机。
KVM(Kernel-based Virtual Machine)是一种基于 Linux 内核的开源虚拟化解决方案。KVM 将 Linux 转变成一个虚拟机监视器(Hypervisor)。它利用了现代处理器中的硬件虚拟化支持(例如 Intel VT-x 或 AMD-V),以实现高性能的虚拟化。它专注于以最小的开销在 Linux 上提供安全和隔离的虚拟环境,同时维持接近原生的性能。它向用户空间提供了虚拟 CPU 和内存子系统的配置和执行控制相关接口,但 KVM 不包含硬件模型,不能独立构成虚拟机。

### QEMU/KVM

Check failure on line 21 in docs/ops/virtualization/qemu-kvm.md

View workflow job for this annotation

GitHub Actions / build

Multiple headings with the same content

docs/ops/virtualization/qemu-kvm.md:21 MD024/no-duplicate-heading Multiple headings with the same content [Context: "### QEMU/KVM"] https://github.com/DavidAnson/markdownlint/blob/v0.33.0/doc/md024.md

Check failure on line 21 in docs/ops/virtualization/qemu-kvm.md

View workflow job for this annotation

GitHub Actions / build

Multiple headings with the same content

docs/ops/virtualization/qemu-kvm.md:21 MD024/no-duplicate-heading Multiple headings with the same content [Context: "### QEMU/KVM"] https://github.com/DavidAnson/markdownlint/blob/v0.33.0/doc/md024.md

Expand Down Expand Up @@ -80,7 +80,7 @@ qemu-system-x86_64 \
QEMU 支持多种存储格式,每种格式都有其特定的优点和用途。以下是一些最常见的 QEMU 磁盘镜像格式:

1. raw: 这是最简单的磁盘镜像格式。它是未经过任何处理的磁盘镜像,没有任何元数据或附加特性。因为其简单性,它通常有最好的性能,并且可以直接被许多其他工具读取,比如 dd。如果主机文件系统支持稀疏文件,那么 raw 格式的磁盘镜像文件可以非常小,因为它只会在需要时才增长到所需大小。如果主机文件系统支持 hole-punching 操作,那么 raw 格式的磁盘镜像文件可以直接释放未使用的空间。
2. qcow2 (QEMU Copy-On-Write version 2): 这是QEMU最常用的磁盘镜像格式。它支持许多高级特性,如写时复制 (copy-on-write),快照,压缩,加密和增量备份。
2. qcow2 (QEMU Copy-On-Write version 2): 这是 QEMU 最常用的磁盘镜像格式。它支持许多高级特性,如写时复制 (copy-on-write),快照,压缩,加密和增量备份。

此外 QEMU 还支持许多其他磁盘格式,如 vmdk, vdi, vhdx 等。由于这些格式不是很常见,这里不再详细介绍。

Expand Down

0 comments on commit 950de1c

Please sign in to comment.