Kernel panic after resizing a clone

ramle

New Member
Aug 1, 2021
1
0
1
30
I've tried to clone a template vm and resize it's disk. At first, the clone start-up with a kernel panic. If I stop it by force and then restart it, the clone boots correctly. I've tried Ubuntu 20.04 and Debian 10. This is not a problem with the disk and I have tried remote storage with NFS and multiple HDDs.
 
Last edited:

MikePT

New Member
Jan 13, 2020
2
0
1
31
Hey,

Facing this same issue with Debian 11.

Any idea?
 

Attachments

  • photo_2021-12-10_10-50-03.jpg
    photo_2021-12-10_10-50-03.jpg
    95.2 KB · Views: 27

serafin.rusu

Member
Jul 6, 2015
5
4
23
I have the same issue, only on Debian 11. I don't have any issues with Almalinux/Ubuntu.
 
Last edited:

Fosten

New Member
Feb 9, 2022
1
0
1
42
Same issue here. Debian 11. kernel panic on first boot of a template clone with vm resize.
 

floh8

Active Member
Jul 27, 2021
259
31
28
what is your doing. which commands you use? which tool?
this problem ist a very important one.
 

hotelrwanda

New Member
Apr 20, 2022
6
1
3
I don't know about the others, but I'm using the Ubuntu 22.04 cloudimg image, and I'm running (after cloning):
Bash:
qm resize $vmid scsi0 3G
The command is succesful, but on the first boot, I get a kernel Panic. After a qm reset $vmid, it works just fine, with the new disk size...
 
Last edited:

tom

Proxmox Staff Member
Staff member
Aug 29, 2006
15,521
908
163
tja, i ask myself why the staff is so silent
with almost zero information about the setup, its impossible to give advice.
 

oz1cw7yymn

Member
Feb 13, 2019
70
9
13
Hi Tom,

I'm not sure what information you need but I'll try to provide it. I am running on latest 7, but recall having the same issue also with 6.4.

Steps taken:
  1. Use a cloud image, I use cloud images from https://cdimage.debian.org/cdimage/cloud/bullseye/latest/, dowload and add the disk to a vm.
  2. Go to Hardware in pve, resize the disk to add more space. This step is sometimes taken before first boot, after the machine has been running for a while or even after having resized the disk previously.
  3. The VM is (re)booted.
Expected result
  1. The VM boots into a login screen, the file system has been resized to fit the added space on the disk.
Actual result
  1. The VM stops at boot with the kernel panic, as seen in the message above from MikePT.
  2. I stop the VM using the stop button.
  3. The VM is started again.
  4. The VM boots into a login screen, the file system has been resized to fit the added space on the disk.
As such, there is an easy workaround that works consistently. I just have to start the VM twice after a resize instead of once.

But if there is an underlying issue or of if can just be resolved so we don't need to restart twice, it might be something to look into.
 

lolmannz

Member
Feb 15, 2017
2
0
21
33
I'm having the exact same issue and been dealing with it for a long time now.
Again, the steps are very common thing to do:

1. Downloaded a cloudimg version of Debian from: https://cdimage.debian.org/cdimage/cloud/bullseye/latest/
2. Used qm import disk to import the disk image into an existing VM with no disk.
3. Attach the imported image as a disk to the VM using the WebUI
4. Using the WebUI, resize the disk by giving it extra 10-20GB of space.
5. Start the VM - Kernel panics
6. Reset the VM - Boots normally

This happens later on as well if I decide to give this VM some more space.
 

Fabian_E

Proxmox Staff Member
Staff member
Aug 1, 2019
1,814
320
88
Hi,
this is very likely the same as https://bugs.launchpad.net/ubuntu/+source/cloud-initramfs-tools/+bug/1123220 and I don't think there's a real "fix" from the outside. The guest is configured to expect a serial console, so you should add one with qm set <ID> -serial0 socket (or change the default kernel commandline to not expect one, but that would need to be done inside the image).
 
  • Like
Reactions: achina

lolmannz

Member
Feb 15, 2017
2
0
21
33
Hi,
this is very likely the same as https://bugs.launchpad.net/ubuntu/+source/cloud-initramfs-tools/+bug/1123220 and I don't think there's a real "fix" from the outside. The guest is configured to expect a serial console, so you should add one with qm set <ID> -serial0 socket (or change the default kernel commandline to not expect one, but that would need to be done inside the image).
Ah, I just tested this by adding a serial port and - viola! It was indeed the culprit. Who would've guessed it would've have something to do with not having a serial port. Anyway - I guess I'll just add the serial port to the template and be done with it for now. Thanks!
 

achina

New Member
Jun 14, 2022
1
0
1

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!