• to be continued…

PART I

unpack

1
2
3
gunzip initrd.cpio.gz
allinone.sh new
#修改启动脚本

run.sh

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#! /bin/sh

# Note: -serial mon:stdio is here for convenience purposes.
# Remotely the chal is run with -serial stdio.

qemu-system-x86_64 \
-no-reboot \
-cpu max \
-net none \
-serial mon:stdio \
-display none \
-monitor none \
-vga none \
-kernel bzImage \
-initrd initrd.cpio.gz \
-append "console=ttyS0" \

runable

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#! /bin/sh

# Note: -serial mon:stdio is here for convenience purposes.
# Remotely the chal is run with -serial stdio.

qemu-system-x86_64 \
-no-reboot \
-cpu max \
-net none \
-serial mon:stdio \
-display none \
-monitor none \
-vga none \
-kernel bzImage \
-initrd initrd.cpio \
-append "console=ttyS0 quiet loglevel=0 panic=-1" \
-s \
  • loglevel=0用于彻底屏蔽日志信息,比quiet威力更大
    • loglevel=1quiet效果相似
  • panic=0panic=-1
    • panic=0表示panic时不重启,打印trace信息
    • panic=-1表示panic时直接退出,不打印trace信息