Emulation on Parallels
Table of Contents
Emulation on Parallels Desktop 17#
Recently Parallels Desktop released version 17, which will utilize Rosetta2 for emulating x86_64.
I had to try it and I usually use Fedora Silverblue as my main OS, along side macOS. How ever, as I found out by trying and testing; only Debian-based Linux distros was supported. Parallels Desktop claims that they will also support Fedora, Red Hat and more later, so we’ll just have to wait and see.
On Debian 12 it works amazing.
A little background history for my excitement.
I switch to an immutable OS (Fedora Silverblue) about a year ago, which is running virtualized on my arm64 macOS machine and all my applications are running inside Podman conatiners.
Now this gives me alot of possibilities, since my host OS (Fedora Silverblue) is not being cluttered with different packages, temporary files, caches and more.
This also makes upgrading and downgrading host OS more easy and dependency-hell is nonexistent.
The containers will also run GUI applications and if I need persistent storage, I usually have a folder mounted from my home-folder from the host OS.
Let’s say I need to do some development or test some python code. Easy! I just use the miniconda3 image from docker to test in my podman container, and nothing ever clutters my host OS or give me dependency errors.
If a container starts behaving badly or looks at me a funny way, I then don’t have to use countless hours to try an debug why I am getting that specific error. I Just delete the container and roll a new one.
Being a nerd that I am, I’ve made script for easily rebuild my containers, either all of them or individual containers.
How to set it up#
1. Install Debian 12 - this part should be pretty straight forward.#
2. Install Paralles Tools and reboot the host OS - this also should be pretty forward and simpel to do.#
3. Make sure the following packages are installed:#
sudo apt update && sudo apt install -y qemu qemu-user-static binfmt-support podman distrobox
4. Create a Dockerfile with the following:#
FROM ubuntu:22.04
This is important, since we want to use the official Ubuntu image and not just some random dudes “amd64 Ubuntu image”, that we find on dockerhub.
5. Build the image:#
podman build --platform=linux/amd64 -t amd64-ubuntu-2204 .
After the image is build it is usually called localhost/{what-ever-we-named-it}. You can check by runnging the command below:
host_OS:~$ podman images
REPOSITORY TAG IMAGE ID CREATED SIZE
docker.io/library/fedora 38 fc9b2be30191 39 hours ago 560 MB
docker.io/library/debian 12 e2acfb335c11 9 days ago 287 MB
localhost/amd64-ubuntu-2204 latest c6b84b685f35 4 weeks ago 161 MB <--- THE IMAGE WE BUILD
docker.io/library/ubuntu 22.04 c6b84b685f35 4 weeks ago 161 MB
<none> <none> f838063d816c 6 weeks ago 560 MB
6. Create the containter:#
distrobox create -i localhost/amd64-ubuntu-2204 -n test
7. Enter the container with:#
distrobox enter test
8. Check the architecture:#
user@test:~$ uname -m
x86_64
Great success!