![dd를 사용하여 작은 디스크를 큰 디스크로 복제한 후 GPT 수정](https://linux55.com/image/211444/dd%EB%A5%BC%20%EC%82%AC%EC%9A%A9%ED%95%98%EC%97%AC%20%EC%9E%91%EC%9D%80%20%EB%94%94%EC%8A%A4%ED%81%AC%EB%A5%BC%20%ED%81%B0%20%EB%94%94%EC%8A%A4%ED%81%AC%EB%A1%9C%20%EB%B3%B5%EC%A0%9C%ED%95%9C%20%ED%9B%84%20GPT%20%EC%88%98%EC%A0%95.png)
dd를 사용하여 더 작은 디스크를 더 큰 디스크로 복제했지만 이제 시작 시 dmesg 오류가 발생합니다.
[Fri Sep 30 11:48:43 2022] GPT:Primary header thinks Alt. header is not at the end of the disk.
[Fri Sep 30 11:48:43 2022] GPT:1953525167 != 3907029167
[Fri Sep 30 11:48:43 2022] GPT:Alternate GPT header not at the end of the disk.
[Fri Sep 30 11:48:43 2022] GPT:1953525167 != 3907029167
[Fri Sep 30 11:48:43 2022] GPT: Use GNU Parted to correct GPT errors.
이 문제를 어떻게 해결할 수 있나요? 오류에는 parted를 사용하라는 메시지가 표시되지만 어떤 명령을 실행해야 할지 잘 모르겠습니다.
답변1
특별한 작업을 수행할 필요는 없습니다. p
디스크에 대한 정보를 인쇄하는 데 사용하면 됩니다. parted는 파티션 테이블 오류를 알려주고 무엇을 해야 할지 묻습니다 Fix
.
# parted /dev/loop0
GNU Parted 3.5
Using /dev/loop0
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) p
Warning: Not all of the space available to /dev/loop0 appears to be used, you can fix the GPT to use all of the space (an extra 10485760 blocks) or continue with the current setting?
Fix/Ignore? Fix
...
( /dev/loop0
예를 들어 디스크로 교체하십시오 /dev/sda
.)