签到成功

知道了

CNDBA社区CNDBA社区

fdisk WARNING: Re-reading the partition

2021-11-09 19:43 1288 0 原创 Linux
作者: hbhe0316
[root@test ~]# fdisk /dev/sda
WARNING: fdisk GPT support is currently new, and therefore in an experimental phase. Use at your own discretion.
Welcome to fdisk (util-linux 2.23.2).

Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.


Command (m for help): n
Partition number (4-128, default 4): 
First sector (34-1873045470, default 1017546752): 
Last sector, +sectors or +size{K,M,G,T,P} (1017546752-1873045470, default 1873045470): 
Created partition 4


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 or after you run partprobe(8) or kpartx(8)
Syncing disks.

fdisk -l看不到磁盘分区,
执行命令刷新,使用fdisk工具只是将分区信息写到磁盘,如果需要mkfs磁盘分区则需要重启系统,
而使用partprobe则可以使kernel重新读取分区 信息,从而避免重启系统。http://www.cndba.cn/hbhe0316/article/5056

http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056
http://www.cndba.cn/hbhe0316/article/5056

[root@test ~]# partprobe

版权声明:本文为博主原创文章,未经博主允许不得转载。

linux

用户评论
* 以下用户言论只代表其个人观点,不代表CNDBA社区的观点或立场
hbhe0316

hbhe0316

关注

1.只有承认无知,才能装下新的东西; 2.进步来自一点点滴滴的积累; 3.广博让你更优秀,而专业让你无法替代; 4.挫折和失败能够转换为一种财富。

  • 889
    原创
  • 1
    翻译
  • 13
    转载
  • 24
    评论
  • 访问:1038204次
  • 积分:1523
  • 等级:核心会员
  • 排名:第6名
精华文章
    最新问题
    查看更多+
    热门文章
      热门用户
      推荐用户
        Copyright © 2016 All Rights Reserved. Powered by CNDBA · 皖ICP备2022006297号-1·

        QQ交流群

        注册联系QQ