File tree Expand file tree Collapse file tree 2 files changed +41
-0
lines changed Expand file tree Collapse file tree 2 files changed +41
-0
lines changed Original file line number Diff line number Diff line change 3
3
- file-system.md : 文件系统
4
4
- cron.md : Cron 定时任务
5
5
- systemd.md : SystemD
6
+ - hardware.md : 硬件管理
6
7
- xargs.md : xargs 命令
7
8
- distro/ : 发行版
8
9
- distro/arch.md : Arch Linux
Original file line number Diff line number Diff line change
1
+ # Linux 硬件管理
2
+
3
+ ## 挂载外部硬盘
4
+
5
+ 系统接入外部硬盘后,先用 fdisk 命令找出硬盘编号。
6
+
7
+ ``` bash
8
+ $ sudo fdisk -l
9
+ ```
10
+
11
+ 这里假定硬盘编号是` /dev/sdc ` 。
12
+
13
+ 然后,创建一个挂载点目录` /mnt/sdd ` 。
14
+
15
+ ``` bash
16
+ $ sudo mkdir /mnt/sdd
17
+ ```
18
+
19
+ 接着,使用 mount 命令将外部硬盘挂载到该目录。
20
+
21
+ ``` bash
22
+ $ sudo mount /dev/sdc /mnt/sdc
23
+ ```
24
+
25
+ 如果挂载的硬盘为 NTFS 格式,需要用 mount 命令的` -t ` 参数指定挂载类型。
26
+
27
+ ``` bash
28
+ # 只读
29
+ $ sudo mount -t ntfs /dev/sdc /mnt/sdc
30
+
31
+ # 读写
32
+ $ sudo mount -t ntfs-3g /dev/sdc /mnt/sdc
33
+ ```
34
+
35
+ 最后,使用 df 命令查看是否挂载成功。
36
+
37
+ ``` bash
38
+ $ df -h
39
+ ```
40
+
You can’t perform that action at this time.
0 commit comments