Show Table of Contents
5.3. ext4 ファイルシステムのサイズ変更
ext4 ファイルシステムのサイズを大きくする前に、基礎となるブロックデバイスが将来的にファイルシステムを保持するのに十分なサイズであることを確認してください。該当するブロックデバイスのサイズを変更する場合は、ブロックデバイスに適した方法を使ってサイズ変更を行ってください。
ext4 ファイルシステムは、
resize2fs を使用して、マウントしたままの状態でサイズを大きくすることができます。
# resize2fs /mount/device sizeresize2fs コマンドは、アンマウントしている ext4 ファイルシステムのサイズを小さくすることもできます。
# resize2fs /dev/device size
ext4 ファイルシステムのサイズを変更する際に、特定の単位を示すサフィックスが使用されていない限り、
resize2fs ユーティリティーは、ファイルシステムのブロックサイズ単位でサイズを読み込みます。特定の単位を指定するには、以下のサフィックスを使用します。
s— 512 バイトのセクターK— キロバイトM— メガバイトG— ギガバイト
注記
拡張時のサイズパラメーターはオプションになります (多くの場合は不要です)。
resize2fs は、論理ボリュームやパーティションなど、使用できるコンテナーの全領域に渡って自動的に拡張を行います。
ext4 ファイルシステムのサイズ変更に関する詳細は、
man resize2fs をご覧ください。

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.