2000字范文,分享全网优秀范文,学习好帮手!
2000字范文 > linux 分区 格式化 挂载 新硬盘

linux 分区 格式化 挂载 新硬盘

时间:2019-12-18 00:52:49

相关推荐

linux 分区 格式化 挂载 新硬盘

独角兽企业重金招聘Python工程师标准>>>

1、给硬盘分区

fdisk /dev/sda

Command (m for help): n

Command action

e extended

p primary partition (1-4)

输入:e

Partition number (1-4): 1

First cylinder (1-9729, default 1):回车

Last cylinder or +size or +sizeM or +sizeK (1-9729, default 9729):回车

Command (m for help):w(保存退出)

2、式化硬盘

fdisk -l

mkfs -t ext3 /dev/sda1

Writing superblocks and filesystem accounting information:直接回车。

3、挂载

mkdir /test

mount -t ext3 /dev/sda1 /test

4、开机直接挂载

编辑/etc/fstab文件

添加:/dev/sda1 /test ext3 defaults 1 1

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。