gem5-users@gem5.org

The gem5 Users mailing list

View all threads

qemu boot ubuntu image from gem5_guest_binaries fail

李强
Wed, Apr 26, 2023 7:59 AM

Hi:

I am currently trying to boot ubuntu-18.04-arm64-docker.img using QEMU. The image file was extracted from aarch-system-20220707.tar.bz2, which I downloaded from https://www.gem5.org/documentation/general_docs/fullsystem/guest_binaries. I compiled my own kernel using the following commands:

git clone https://gem5.googlesource.com/arm/linux
make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- gem5_defconfig
make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- -j32

However, I encountered an error when I tried to boot using the QEMU command:

qemu-system-aarch64 \
-m 4096 \
-cpu cortex-a57 \
-nographic \
-machine virt \
-kernel /home/dev/gem5-all/power/prep/my-disks/linux/arch/arm64/boot/Image \
-append 'root=/dev/vda1 rw rootwait mem=4096M console=ttyAMA0,38400n8' \
-device virtio-blk-device,drive=image \
-drive if=none,id=image,file=/home/dev/gem5-all/power/prep/disks/ubuntu-18.04-arm64-docker.img


The error message I received was "

--[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00008400".

full log message is in attachment.

Could you please provide me with assistance on how to resolve this issue?

Thank you for your time and support.

Best regards,

Leon

Hi: I am currently trying to boot ubuntu-18.04-arm64-docker.img using QEMU. The image file was extracted from aarch-system-20220707.tar.bz2, which I downloaded from https://www.gem5.org/documentation/general_docs/fullsystem/guest_binaries. I compiled my own kernel using the following commands: ``` git clone https://gem5.googlesource.com/arm/linux make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- gem5_defconfig make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- -j32 ``` However, I encountered an error when I tried to boot using the QEMU command: ``` qemu-system-aarch64 \ -m 4096 \ -cpu cortex-a57 \ -nographic \ -machine virt \ -kernel /home/dev/gem5-all/power/prep/my-disks/linux/arch/arm64/boot/Image \ -append 'root=/dev/vda1 rw rootwait mem=4096M console=ttyAMA0,38400n8' \ -device virtio-blk-device,drive=image \ -drive if=none,id=image,file=/home/dev/gem5-all/power/prep/disks/ubuntu-18.04-arm64-docker.img ``` The error message I received was " --[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00008400". full log message is in attachment. Could you please provide me with assistance on how to resolve this issue? Thank you for your time and support. Best regards, Leon
GT
Giacomo Travaglini
Wed, Apr 26, 2023 8:41 AM

Hi,

I am not surprised. The disk image contains an init script with m5 operations (probably m5 readfile).

m5 is a gem5 specific pseudo-instruction and does not get recognised by QEMU.

You should either amend the init file within the disk or point to a different init executable from QEMU command line (for example /bin/bash)

Kind Regards

Giacomo

On 26/04/2023 08:59, 李强 via gem5-users wrote:
Hi:

I am currently trying to boot ubuntu-18.04-arm64-docker.img using QEMU. The image file was extracted from aarch-system-20220707.tar.bz2, which I downloaded from https://www.gem5.org/documentation/general_docs/fullsystem/guest_binaries. I compiled my own kernel using the following commands:

git clone https://gem5.googlesource.com/arm/linux
make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- gem5_defconfig
make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- -j32

However, I encountered an error when I tried to boot using the QEMU command:

qemu-system-aarch64 \
-m 4096 \
-cpu cortex-a57 \
-nographic \
-machine virt \
-kernel /home/dev/gem5-all/power/prep/my-disks/linux/arch/arm64/boot/Image \
-append 'root=/dev/vda1 rw rootwait mem=4096M console=ttyAMA0,38400n8' \
-device virtio-blk-device,drive=image \
-drive if=none,id=image,file=/home/dev/gem5-all/power/prep/disks/ubuntu-18.04-arm64-docker.img

The error message I received was "

--[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00008400".

full log message is in attachment.

Could you please provide me with assistance on how to resolve this issue?

Thank you for your time and support.

Best regards,

Leon


gem5-users mailing list -- gem5-users@gem5.orgmailto:gem5-users@gem5.org
To unsubscribe send an email to gem5-users-leave@gem5.orgmailto:gem5-users-leave@gem5.org

IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

Hi, I am not surprised. The disk image contains an init script with m5 operations (probably m5 readfile). m5 is a gem5 specific pseudo-instruction and does not get recognised by QEMU. You should either amend the init file within the disk or point to a different init executable from QEMU command line (for example /bin/bash) Kind Regards Giacomo On 26/04/2023 08:59, 李强 via gem5-users wrote: Hi: I am currently trying to boot ubuntu-18.04-arm64-docker.img using QEMU. The image file was extracted from aarch-system-20220707.tar.bz2, which I downloaded from https://www.gem5.org/documentation/general_docs/fullsystem/guest_binaries. I compiled my own kernel using the following commands: ``` git clone https://gem5.googlesource.com/arm/linux make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- gem5_defconfig make ARCH=arm64 CROSS_COMPILER=aarch64-linux-gnu- -j32 ``` However, I encountered an error when I tried to boot using the QEMU command: ``` qemu-system-aarch64 \ -m 4096 \ -cpu cortex-a57 \ -nographic \ -machine virt \ -kernel /home/dev/gem5-all/power/prep/my-disks/linux/arch/arm64/boot/Image \ -append 'root=/dev/vda1 rw rootwait mem=4096M console=ttyAMA0,38400n8' \ -device virtio-blk-device,drive=image \ -drive if=none,id=image,file=/home/dev/gem5-all/power/prep/disks/ubuntu-18.04-arm64-docker.img ``` The error message I received was " --[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x00008400". full log message is in attachment. Could you please provide me with assistance on how to resolve this issue? Thank you for your time and support. Best regards, Leon _______________________________________________ gem5-users mailing list -- gem5-users@gem5.org<mailto:gem5-users@gem5.org> To unsubscribe send an email to gem5-users-leave@gem5.org<mailto:gem5-users-leave@gem5.org> IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.