文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>linux磁盘分区

linux磁盘分区

时间:2010-04-13  来源:lsy011025

[root@localhost ~]#fdisk  –l   //查看所有的磁盘情况

 

  Disk /dev/hda: 300.0 GB, 300090728448 bytes

255 heads, 63 sectors/track, 36483 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

 

Device   Boot  Start    End     Blocks     Id    System

/dev/hda1  *    1       5099    40957686   7    HPFS/NTFS

/dev/hda2       5100    10198   40957717+  83   Linux

/dev/hda3       1019    10453   2048287+   82   Linux swap /Solaris

/dev/hda4       10454   36483   209085975  5    Extended

/dev/hda5       10454   16827   51199123+  83   Linux

 

[root@localhost ~]#fdisk   /dev/hda  //选择你要操作的那个磁盘

Command (m for help): d                   //删除分区

Partition number (1-5): 1                   //分区标号

Command (m for help): d

Partition number (1-5): 2

Command (m for help): d

Partition number (1-5): 3

Command (m for help): d

Partition number (1-5): 4

Command (m for help): d

No partition is defined yet!

 

Command (m for help): n              //建立新分区

Command action

   e   extended

   p   primary partition (1-4)

p

Partition number (1-4): 1

First cylinder (1-36483, default 1):

Using default value 1

Last cylinder or +size or +sizeM or +sizeK (1-36483, default 36483): +100G

 

Command (m for help): w

……

Command (m for help): q                //退出

[root@localhost ~]#

 

二.格式化: mkfs.ext3  /dev/hda1;(也可以是 ext2,lustre,vfat,iso9660等等)

三.挂载:mkdir /mnt/hda 

mount /dev/hda1 /mnt/hda

 

一些小经验:

多模式切换: Ctrl+Alt+F*;.新打开一个终端:Ctrl+Shift+n,在一个终端中新开一个窗口:Ctrl+Shift+t;在命令行模式下翻页:

Shift+ PAGE UP。

 

相关阅读 更多 +
排行榜 更多 +
百炼英雄抽卡技巧指南

百炼英雄抽卡技巧指南

休闲益智 下载
英雄没有闪滚雷旋风技能如何搭配

英雄没有闪滚雷旋风技能如何搭配

休闲益智 下载
英雄没有闪雷旋风BD构筑推荐

英雄没有闪雷旋风BD构筑推荐

休闲益智 下载