永続ディスクのサイズを変更する
bookmark_borderbookmark
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
このサンプルでは、永続ディスクのサイズを GB 単位で指定のサイズに変更します。ディスクをサイズ変更したら、オペレーティング システムが追加の容量にアクセスできるように、ファイル システムのサイズを変更する必要があります。
コードサンプル
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["わかりにくい","hardToUnderstand","thumb-down"],["情報またはサンプルコードが不正確","incorrectInformationOrSampleCode","thumb-down"],["必要な情報 / サンプルがない","missingTheInformationSamplesINeed","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["その他","otherDown","thumb-down"]],[],[[["This content provides code samples in Java and Python to resize a persistent disk to a specified size in gigabytes (GB)."],["Resizing the disk using the provided code is only the first step; you must subsequently resize the file system so the operating system can utilize the added space."],["The code samples require setting up authentication and using the Google Cloud Compute Engine client libraries, as indicated in the prerequisite documentation links."],["The code shows how to send requests using the client libraries and how to wait for the resize operation to finish, while handling potential errors and warnings."],["The Python code allows for resizing disks located in both zones and regions, while the Java code sample resizes a disk located in a specific zone."]]],[]]