I would like to change the partitions on my Google Cloud instance disk. One big 64GB ext4 partition should be split into 16GB ext4, 16GB swap and 32GB btrfs partitions.

Until now, this has worked for me in instances which were built from ubuntu-1804-lts source images. I added a script to /etc/initramfs-tools/scripts/init-premount/, ran update-initramfs and rebooted the machine. The script then executed the changes using fdisk before the root partition was mounted.

When I recently switched to ubuntu-2004-lts source images, this approach does not work any more. I checked that the script is included into the initrd.img, but it seems to not be executed any more. Activating kernel debug via grub.cfg, which should lead to a /run/initramfs/initramfs.debug file, does also not work any more, so I have no way to debug the init process.

Has anything changed in the init process of Ubuntu 20.04 LTS Google Cloud images? I noticed the new line [ 2.037881] systemd-hibernate-resume-generator[149]: Not running in an initrd, quitting. in dmesg; don't know if this has something to do with it.

GCloud-CLI commands are no solution for me as I am creating the instances with packer and therefore need scripts to execute.

I hope you can help me or point me in the right direction :)

Best regards


  • What script? You have provided an overview but not the details that we need to help you. – John Hanley May 12 at 17:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.