Install Alpine in QEMU: Difference between revisions
(→Booting the Virtual Machine: Use code block) |
(→Create the Virtual Machine: Linked to setup-alpine) |
||
Line 16: | Line 16: | ||
{{Tip|Add option <code>-enable-kvm</code> if your hardware support this.}} | {{Tip|Add option <code>-enable-kvm</code> if your hardware support this.}} | ||
Log in as root (no password) and run: {{Cmd|setup-alpine}} | Log in as <code>root</code> (no password) and run: {{Cmd|setup-alpine}} | ||
Follow the [[Alpine_setup_scripts#setup-alpine|setup-alpine installation steps]]. | |||
Use <code>poweroff</code> to shut down the machine | |||
Use <code>poweroff</code> to shut down the machine. | |||
== Booting the Virtual Machine == | == Booting the Virtual Machine == |
Revision as of 18:51, 14 September 2019
Before You Start
- Download the latest Alpine image.
- Install QEMU on your system (e.g.
sudo apt install qemu
on Ubuntu,yum -y install qemu
on Fedora)
Create the Virtual Machine
Create a disk image if you want to install Alpine Linux.
qemu-img create -f qcow2 alpine.qcow2 8G
The following command starts QEMU with the Alpine ISO image as CDROM, the default network configuration, 512MB RAM, the disk image that was created in the previous step, and CDROM as the boot device.
qemu-system-x86_64 -m 512 -nic user -boot d -cdrom alpine-standard-3.10.2-x86_64.iso -hda alpine.qcow2
Tip: Add option
-enable-kvm
if your hardware support this.
Log in as root
(no password) and run:
setup-alpine
Follow the setup-alpine installation steps.
Use poweroff
to shut down the machine.
Booting the Virtual Machine
After the installation QEMU can be started from disk image (-boot c
) without CDROM.
qemu-system-x86_64 -m 512 -nic user -hda alpine.qcow2