Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multipass conflicts with Mullvad VPN: fails to start a VM on mac m1 #3891

Open
stone-w4tch3r opened this issue Jan 23, 2025 · 3 comments
Open
Labels
bug needs triage Issue needs to be triaged

Comments

@stone-w4tch3r
Copy link

Describe the bug
When I try to launch a VM, multipass freezes for some time and than fails with timeout error. If I disable/disconnect mullvad VPN, issue resolves

To Reproduce

  1. Buy Mullvad VPN subscription for a month (5$)
  2. Install macos app and login
  3. Connect
  4. multipass launch --name test

Expected behavior
Multipass does not interferes with VPN and both do their job fine

Logs

logs

Trying to launch with mullvad:

multipass launch --name test -vvvvv

[2025-01-23T16:57:03.678] [trace] [url downloader] Found https://codeload.github.com/canonical/multipass-blueprints/zip/refs/heads/main in cache: true
[2025-01-23T16:57:03.699] [debug] [blueprint provider] Loading "anbox-cloud-appliance" v1
[2025-01-23T16:57:03.706] [debug] [blueprint provider] Loading "charm-dev" v1
[2025-01-23T16:57:03.707] [debug] [blueprint provider] Loading "docker" v1
[2025-01-23T16:57:03.708] [debug] [blueprint provider] Loading "jellyfin" v1
[2025-01-23T16:57:03.708] [debug] [blueprint provider] Loading "minikube" v1
[2025-01-23T16:57:03.709] [debug] [blueprint provider] Loading "ros2-humble" v1
[2025-01-23T16:57:03.710] [debug] [blueprint provider] Loading "ros2-jazzy" v1
[2025-01-23T16:57:03.717] [debug] [qemu-system-aarch64] [53218] started: qemu-system-aarch64 --version
[2025-01-23T16:57:03.753] [debug] [qemu-img] [53219] started: qemu-img info /var/root/Library/Caches/multipassd/qemu/vault/images/noble-20250115/ubuntu-24.04-server-cloudimg-arm64.img
[2025-01-23T16:57:03.772] [debug] [qemu-img] [53220] started: qemu-img resize /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img 5368709120
[2025-01-23T16:57:03.784] [debug] [qemu-img] [53221] started: qemu-img snapshot -l /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img
[2025-01-23T16:57:03.792] [debug] [qemu-img] [53222] started: qemu-img amend -o compat=1.1 /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img
[2025-01-23T16:57:03.800] [debug] [test] process working dir ''
[2025-01-23T16:57:03.800] [info] [test] process program 'qemu-system-aarch64'
[2025-01-23T16:57:03.800] [info] [test] process arguments '-machine, virt,gic-version=3, -accel, hvf, -drive, file=/Library/Application Support/com.canonical.multipass/bin/../Resources/qemu/edk2-aarch64-code.fd,if=pflash,format=raw,readonly=on, -cpu, host, -nic, vmnet-shared,model=virtio-net-pci,mac=52:54:00:64:f8:ef, -device, virtio-scsi-pci,id=scsi0, -drive, file=/var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img,if=none,format=qcow2,discard=unmap,id=hda, -device, scsi-hd,drive=hda,bus=scsi0.0, -smp, 1, -m, 1024M, -qmp, stdio, -chardev, null,id=char0, -serial, chardev:char0, -nographic, -cdrom, /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/cloud-init-config.iso'
[2025-01-23T16:57:03.803] [debug] [qemu-system-aarch64] [53223] started: qemu-system-aarch64 -machine virt,gic-version=3 -nographic -dump-vmstate /private/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/multipassd.uAGyJd
[2025-01-23T16:57:03.840] [info] [test] process state changed to Starting
[2025-01-23T16:57:03.843] [info] [test] process state changed to Running
[2025-01-23T16:57:03.843] [debug] [qemu-system-aarch64] [53224] started: qemu-system-aarch64 -machine virt,gic-version=3 -accel hvf -drive file=/Library/Application Support/com.canonical.multipass/bin/../Resources/qemu/edk2-aarch64-code.fd,if=pflash,format=raw,readonly=on -cpu host -nic vmnet-shared,model=virtio-net-pci,mac=52:54:00:64:f8:ef -device virtio-scsi-pci,id=scsi0 -drive file=/var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img,if=none,format=qcow2,discard=unmap,id=hda -device scsi-hd,drive=hda,bus=scsi0.0 -smp 1 -m 1024M -qmp stdio -chardev null,id=char0 -serial chardev:char0 -nographic -cdrom /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/cloud-init-config.iso
[2025-01-23T16:57:03.843] [info] [test] process started
launch failed: The following errors occurred:
test: timed out waiting for response

Trying to launch with another VPN (FoxRay)

multipass launch --name test -vvvvv

[2025-01-23T16:55:08.353] [debug] [qemu-system-aarch64] [53003] started: qemu-system-aarch64 --version
[2025-01-23T16:55:09.499] [debug] [qemu-img] [53004] started: qemu-img info /var/root/Library/Caches/multipassd/qemu/vault/images/noble-20250115/ubuntu-24.04-server-cloudimg-arm64.img
[2025-01-23T16:55:09.520] [debug] [qemu-img] [53005] started: qemu-img resize /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img 5368709120
[2025-01-23T16:55:09.533] [debug] [qemu-img] [53006] started: qemu-img snapshot -l /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img
[2025-01-23T16:55:09.542] [debug] [qemu-img] [53007] started: qemu-img amend -o compat=1.1 /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img
[2025-01-23T16:55:09.549] [debug] [test] process working dir ''
[2025-01-23T16:55:09.549] [info] [test] process program 'qemu-system-aarch64'
[2025-01-23T16:55:09.549] [info] [test] process arguments '-machine, virt,gic-version=3, -accel, hvf, -drive, file=/Library/Application Support/com.canonical.multipass/bin/../Resources/qemu/edk2-aarch64-code.fd,if=pflash,format=raw,readonly=on, -cpu, host, -nic, vmnet-shared,model=virtio-net-pci,mac=52:54:00:51:59:57, -device, virtio-scsi-pci,id=scsi0, -drive, file=/var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img,if=none,format=qcow2,discard=unmap,id=hda, -device, scsi-hd,drive=hda,bus=scsi0.0, -smp, 1, -m, 1024M, -qmp, stdio, -chardev, null,id=char0, -serial, chardev:char0, -nographic, -cdrom, /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/cloud-init-config.iso'
[2025-01-23T16:55:09.552] [debug] [qemu-system-aarch64] [53008] started: qemu-system-aarch64 -machine virt,gic-version=3 -nographic -dump-vmstate /private/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/multipassd.tfqKFZ
[2025-01-23T16:55:09.585] [info] [test] process state changed to Starting
[2025-01-23T16:55:09.588] [info] [test] process state changed to Running
[2025-01-23T16:55:09.588] [debug] [qemu-system-aarch64] [53009] started: qemu-system-aarch64 -machine virt,gic-version=3 -accel hvf -drive file=/Library/Application Support/com.canonical.multipass/bin/../Resources/qemu/edk2-aarch64-code.fd,if=pflash,format=raw,readonly=on -cpu host -nic vmnet-shared,model=virtio-net-pci,mac=52:54:00:51:59:57 -device virtio-scsi-pci,id=scsi0 -drive file=/var/root/Library/Application Support/multipassd/qemu/vault/instances/test/ubuntu-24.04-server-cloudimg-arm64.img,if=none,format=qcow2,discard=unmap,id=hda -device scsi-hd,drive=hda,bus=scsi0.0 -smp 1 -m 1024M -qmp stdio -chardev null,id=char0 -serial chardev:char0 -nographic -cdrom /var/root/Library/Application Support/multipassd/qemu/vault/instances/test/cloud-init-config.iso
[2025-01-23T16:55:09.588] [info] [test] process started
Launched: test

Additional info

  • OS: macOS 15.2 24C101 arm64
  • multipass 1.15.0+mac multipassd 1.15.0+mac
  • multipass get local.driver: qemu
multipass info
Name:           test
State:          Unknown
Snapshots:      0
IPv4:           --
Release:        --
Image hash:     f11282a728ad (Ubuntu 24.04 LTS)
CPU(s):         --
Load:           --
Disk usage:     --
Memory usage:   --
Mounts:         --

Additional context
Why multipass interferes with VPN at all? Seems as a fragile design in networking

@stone-w4tch3r stone-w4tch3r added bug needs triage Issue needs to be triaged labels Jan 23, 2025
@giuliazanchi
Copy link
Contributor

Hi @stone-w4tch3r , thanks for reporting the issue, we're aware that VPN usage can interfere with Multipass. Have you already looked at our Troubleshooting documentation?

@stone-w4tch3r
Copy link
Author

stone-w4tch3r commented Jan 24, 2025

Oh, troubleshooting page actually gave me ideas that fixed the issue!

There were stated:

VPN software can be aggressive at managing routes and may route 192.168.64 subnet through the VPN interface, instead of keeping it locally available.

So I enabled "local network sharing" in mullvad settings > vpn settings, and now I can launch instance and shell into it! Maybe you can add this to troubleshooting page

Thanks

@giuliazanchi
Copy link
Contributor

That's great, @stone-w4tch3r , I'm glad you were able to fix this by looking at our docs! The Troubleshooting topic is still a work in progress, but the most frequent and common issues should be covered :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug needs triage Issue needs to be triaged
Projects
None yet
Development

No branches or pull requests

2 participants