🎮 Batocera#
Install Batocera in a VM#
To install the Batocera distribution in a virtual machine (VM), follow these steps based on the available guides:
Download and Prepare the Image: Obtain the Batocera image file from the official website, typically in the
.img.gzformat Extract the compressed file using a command likegzip -dk batocera-x86_64-*.img.gzto get the raw.imgfileResize the Image (Optional): If you need more storage space for games and BIOS files, expand the image size using
truncate -s 16G batocera-x86_64-*.img(adjust the size as needed, e.g., 32G, 64G)Create the VM:
Use a virtualization platform such as Proxmox VE, VirtualBox, or QEMU.
When creating the VM, do not use a bootable ISO; instead, import the
.imgfile directly as a diskFor Proxmox VE, use
qm importdisk <vmid> batocera-x86_64-*.img <storage name>to import the imageEnsure the VM uses the q35 machine type (not i440fx), as it is required for PCIe passthrough and proper functionality
Set the OS type to Linux (64-bit) and disable secure boot
Configure Hardware:
Remove any default disk or CD/DVD drive, as Batocera uses a raw disk image, not an ISO
Assign at least 2048 MB of RAM and 2–4 CPU cores depending on your system and emulator needs
Use the e1000 network adapter instead of virtio, as Batocera does not recognize virtio drivers
For storage, configure the imported image as a SATA or SCSI disk with SSD emulation and Discard enabled to improve performance and disk management
Boot Configuration:
In the VM settings, ensure the boot order prioritizes the virtual disk (e.g., SATA or SCSI) over other devices
For Proxmox, add custom boot arguments to mount the image as a removable USB device for booting, using commands like
-set drive.drive-scsi0.readonly=on,-drive, and-device usb-storage
Optional: GPU Passthrough (Proxmox):
To enable full graphics performance, assign your physical GPU to the VM via PCI passthrough
This requires the VM to use q35 machine type and the GPU to be unbound from the host
Start the VM:
Once configured, start the VM. Batocera will boot directly from the imported image
The default login credentials are
rootwith passwordlinuxfor SSH/SFTP access
Add Games and BIOS:
Use the file manager or network sharing (e.g., SMB/NFS) to transfer ROMs and BIOS files to the appropriate folders within the VM
ROMs should be placed in the
romsdirectory, organized by system
For detailed setup instructions, refer to the official Batocera wiki, which provides step-by-step guidance for running Batocera in a VM using QEMU