linux更改分区名,修改Linux的分区ID号

[root@zhjj~]# fdisk /dev/sda

The number of cylinders for this disk is set to 9726.

There is nothing wrong with that, but this is larger than 1024,

and could in certain setups cause problems with:

1) software that runs at boot time (e.g., old versions of LILO)

2) booting and partitioning software from other OSs

(e.g., DOS FDISK, OS/2 FDISK)

Command (m for help): p  #查看分区

Disk /dev/sda: 80.0 GB, 80000000000 bytes

255 heads, 63 sectors/track, 9726 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot      Start         End      Blocks   Id  System

/dev/sda1   *           1          13      104391   83  Linux

/dev/sda2              14        3837    30716280   8e  Linux LVM

/dev/sda3            3838        4098     2096482+  82  Linux swap / Solaris

/dev/sda4            4099        9726    45206910    5  Extended

/dev/sda5            4099        4160      497983+  83  Linux

/dev/sda6            4161        4285     1004031   8e  Linux LVM

/dev/sda7            4286        4287       16033+  83  Linux

/dev/sda8            4288        4350      506016   fd  Linux raid autodetect

/dev/sda9            4351        4413      506016   fd  Linux raid autodetect

Command (m for help): n  #创建分区

First cylinder (4414-9726, default 4414):

Using default value 4414

Last cylinder or +size or +sizeM or +sizeK (4414-9726, default 9726): +80M  #指定大小

Command (m for help): t  #修改分区类型

Partition number (1-10): 10  #选择分区

Hex code (type L to list codes): 8e  #分区类型名称

Changed system type of partition 10 to 8e (Linux LVM)

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

The partition table has been altered!

Calling ioctl() to re-read partition table.

WARNING: Re-reading the partition table failed with error 16: Device or resource busy.

The kernel still uses the old table.

The new table will be used at the next reboot.

Syncing disks.

[root@zhjj~]# partprobe  #同步分区表

如果修改后出现开机无法正常启动,需要进入光盘引导进行系统修复。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值