AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-572326

Pizza's questions

Martin Hope
Pizza
Asked: 2023-02-17 21:46:58 +0800 CST

dd 磁盘克隆后的 GPT 表修复

  • 5

在执行此操作之前,我使用 dd 将 500gb 硬盘驱动器克隆到 256gb SSD 我编辑了分区,以便使用 GParted 取消分配最后的 280gb(大致)。

最终 dd 在 240gb 时用完了空间,计划是它不会复制未分配的空间并且克隆将完成。

不幸的是,GPT 表不正确,我不知道如何整理。

GParted 讨厌它并告诉我它会使用一个未分配的整个驱动器的备份表。

GPT Fdisk 告诉我有 5 个错误,但是对于“p”,它确实表示所有分区都在那里。(这可能是提醒它是 Windows 驱动器的好时机)

我用的DDsudo dd if=/dev/sda of=/dev/sdc status=progress

结果 :dd: writing to '/dev/sdc': No space left on device 468862125+0 records in 468862124+0 records out 240057407488 bytes (240 GB, 224 GiB) copied, 21466.2 s, 11.2 MB/s

GPT fdisk:Warning! Disk size is smaller than the main header indicates!然后它说 MBR Protective 和 GPT Damaged Caution: invalid backup GPT header, but valid main header; regenerating backup header from main header.。Warning! One or more CRCs don't match. You should repair the disk!

在“v”上: 注意:备份分区表的 CRC 无效。该表可能已损坏。当您保存分区时,该程序将自动创建一个新的备份分区表。

问题:辅助标头的自指针表明它不在磁盘末尾。如果您已将磁盘添加到 RAID 阵列,请使用专家菜单上的“e”选项来调整辅助标头和分区表的位置。

问题:磁盘太小,无法容纳所有数据!(磁盘大小为 468862124 个扇区,需要为 976773168 个扇区。)专家菜单上的“e”选项可能会解决此问题。

问题:GPT 声称磁盘比实际大!(声称最后一个可用扇区是 976773134,但备份头是 976773167,磁盘大小是 468862124 个扇区。专家菜单上的“e”选项可能会解决这个问题

保护性 MBR 中的分区对于磁盘来说太大了!建议创建新的保护性或混合 MBR。

确定了 5 个问题!^

帮助将不胜感激

 sudo gdisk -l /dev/sda
GPT fdisk (gdisk) version 1.0.3

Partition table scan:
  MBR: protective
  BSD: not present
  APM: not present
  GPT: present

Found valid GPT with protective MBR; using GPT.
Disk /dev/sda: 976773168 sectors, 465.8 GiB
Model: ST500LM034-2GH17
Sector size (logical/physical): 512/4096 bytes
Disk identifier (GUID): 43B49B18-460C-4EDB-B63D-195389ABF232
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 976773134
Partitions will be aligned on 2048-sector boundaries
Total free space is 589831021 sectors (281.3 GiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048         1085439   529.0 MiB   2700  Basic data partition
   2         1085440         1290239   100.0 MiB   EF00  EFI system partition
   3         1290240         1323007   16.0 MiB    0C01  Microsoft reserved ...
   4         1323008       273028223   129.6 GiB   0700  Basic data partition
   5       273029120       274431999   685.0 MiB   2700  
   6       274434048       296837119   10.7 GiB    0700  Basic data partition
   7       297041920       387151871   43.0 GiB    0700  Basic data partition
$ sudo gdisk -l /dev/sdc
GPT fdisk (gdisk) version 1.0.3

Warning! Disk size is smaller than the main header indicates! Loading
secondary header from the last sector of the disk! You should use 'v' to
verify disk integrity, and perhaps options on the experts' menu to repair
the disk.
Caution: invalid backup GPT header, but valid main header; regenerating
backup header from main header.

Warning! One or more CRCs don't match. You should repair the disk!

Partition table scan:
  MBR: protective
  BSD: not present
  APM: not present
  GPT: damaged

****************************************************************************
Caution: Found protective or hybrid MBR and corrupt GPT. Using GPT, but disk
verification and recovery are STRONGLY recommended.
****************************************************************************
Disk /dev/sdc: 468862124 sectors, 223.6 GiB
Model: high speed      
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 43B49B18-460C-4EDB-B63D-195389ABF232
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 976773134
Partitions will be aligned on 2048-sector boundaries
Total free space is 589831021 sectors (281.3 GiB)

Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048         1085439   529.0 MiB   2700  Basic data partition
   2         1085440         1290239   100.0 MiB   EF00  EFI system partition
   3         1290240         1323007   16.0 MiB    0C01  Microsoft reserved ...
   4         1323008       273028223   129.6 GiB   0700  Basic data partition
   5       273029120       274431999   685.0 MiB   2700  
   6       274434048       296837119   10.7 GiB    0700  Basic data partition
   7       297041920       387151871   43.0 GiB    0700  Basic data partition
clone
  • 1 个回答
  • 33 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何减少“vmmem”进程的消耗?

    • 11 个回答
  • Marko Smith

    从 Microsoft Stream 下载视频

    • 4 个回答
  • Marko Smith

    Google Chrome DevTools 无法解析 SourceMap:chrome-extension

    • 6 个回答
  • Marko Smith

    Windows 照片查看器因为内存不足而无法运行?

    • 5 个回答
  • Marko Smith

    支持结束后如何激活 WindowsXP?

    • 6 个回答
  • Marko Smith

    远程桌面间歇性冻结

    • 7 个回答
  • Marko Smith

    子网掩码 /32 是什么意思?

    • 6 个回答
  • Marko Smith

    鼠标指针在 Windows 中按下的箭头键上移动?

    • 1 个回答
  • Marko Smith

    VirtualBox 无法以 VERR_NEM_VM_CREATE_FAILED 启动

    • 8 个回答
  • Marko Smith

    应用程序不会出现在 MacBook 的摄像头和麦克风隐私设置中

    • 5 个回答
  • Martin Hope
    Vickel Firefox 不再允许粘贴到 WhatsApp 网页中? 2023-08-18 05:04:35 +0800 CST
  • Martin Hope
    Saaru Lindestøkke 为什么使用 Python 的 tar 库时 tar.xz 文件比 macOS tar 小 15 倍? 2021-03-14 09:37:48 +0800 CST
  • Martin Hope
    CiaranWelsh 如何减少“vmmem”进程的消耗? 2020-06-10 02:06:58 +0800 CST
  • Martin Hope
    Jim Windows 10 搜索未加载,显示空白窗口 2020-02-06 03:28:26 +0800 CST
  • Martin Hope
    andre_ss6 远程桌面间歇性冻结 2019-09-11 12:56:40 +0800 CST
  • Martin Hope
    Riley Carney 为什么在 URL 后面加一个点会删除登录信息? 2019-08-06 10:59:24 +0800 CST
  • Martin Hope
    zdimension 鼠标指针在 Windows 中按下的箭头键上移动? 2019-08-04 06:39:57 +0800 CST
  • Martin Hope
    jonsca 我所有的 Firefox 附加组件突然被禁用了,我该如何重新启用它们? 2019-05-04 17:58:52 +0800 CST
  • Martin Hope
    MCK 是否可以使用文本创建二维码? 2019-04-02 06:32:14 +0800 CST
  • Martin Hope
    SoniEx2 更改 git init 默认分支名称 2019-04-01 06:16:56 +0800 CST

热门标签

windows-10 linux windows microsoft-excel networking ubuntu worksheet-function bash command-line hard-drive

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve