![resize2fs를 사용하여 파일 시스템을 축소할 때 올바른 파티션 크기를 계산하는 방법](https://linux55.com/image/182543/resize2fs%EB%A5%BC%20%EC%82%AC%EC%9A%A9%ED%95%98%EC%97%AC%20%ED%8C%8C%EC%9D%BC%20%EC%8B%9C%EC%8A%A4%ED%85%9C%EC%9D%84%20%EC%B6%95%EC%86%8C%ED%95%A0%20%EB%95%8C%20%EC%98%AC%EB%B0%94%EB%A5%B8%20%ED%8C%8C%ED%8B%B0%EC%85%98%20%ED%81%AC%EA%B8%B0%EB%A5%BC%20%EA%B3%84%EC%82%B0%ED%95%98%EB%8A%94%20%EB%B0%A9%EB%B2%95.png)
GNU/Linux에서 resize2fs를 사용하여 읽기 전용 파일 시스템을 축소한 후 축소된 파일 시스템에 대한 올바른 파티션 항목을 어떻게 결정합니까?
원격 호스트의 초기 파티션 구성표:
Disk /dev/sda: 1,8 TiB, 1999844147200 bytes, 3905945600 sectors
Disk model: xxx
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xf79ea8df
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 487423 485376 237M 83 Linux
/dev/sda2 487424 3841943551 3841456128 1,8T 83 Linux
/dev/sda3 3841943552 3883886591 41943040 20G 83 Linux
Command (m for help):
크기 조정 명령을 실행하십시오.
[root@home ~]# resize2fs /dev/sda2 200G
resize2fs 1.44.5 (15-Dec-2018)
Resizing the filesystem on /dev/sda2 to 52428800 (4k) blocks.
The filesystem on /dev/sda2 is now 52428800 (4k) blocks long.
시작 섹터가 487424이고 크기가 8배 52428800 * 512바이트 블록인 /dev/sda2에 대한 파티션 항목을 다시 생성할 때 생성된 파티션이 실제로 전체 축소 파일 시스템을 포함합니까? 이를 증명하는 방법은 무엇입니까?
Disk /dev/sda: 1,8 TiB, 1999844147200 bytes, 3905945600 sectors
Disk model: xxx
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xf79ea8df
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 487423 485376 237M 83 Linux
/dev/sda2 487424 419917824 419430401 200G 83 Linux
/dev/sda3 3841943552 3883886591 41943040 20G 83 Linux
Command (m for help):