Skip to content

Commit c0d19c6

Browse files
committed
qemu: use 9p by default
Templates for the following distro are updated to continue using reverse-sshfs, as 9p is not available on them. - AlmaLinux - CentOS Stream - Debian - openSUSE - Oracle Linux - Rocky Linux Close issue 971 Signed-off-by: Akihiro Suda <[email protected]>
1 parent 3e736f6 commit c0d19c6

16 files changed

+32
-10
lines changed

.github/workflows/test.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -171,13 +171,6 @@ jobs:
171171
retry_on: error
172172
max_attempts: 3
173173
command: ./hack/test-templates.sh templates/default.yaml
174-
- name: "Test experimental/9p.yaml"
175-
uses: nick-invision/retry@v2
176-
with:
177-
timeout_minutes: 30
178-
retry_on: error
179-
max_attempts: 3
180-
command: ./hack/test-templates.sh templates/experimental/9p.yaml
181174
- name: "Test test-misc.yaml"
182175
uses: nick-invision/retry@v2
183176
with:

examples/almalinux-8.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ images:
1616
arch: "x86_64"
1717
- location: "https://repo.almalinux.org/almalinux/8/cloud/aarch64/images/AlmaLinux-8-GenericCloud-latest.aarch64.qcow2"
1818
arch: "aarch64"
19+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
20+
mountType: "reverse-sshfs"
1921
mounts:
2022
- location: "~"
2123
- location: "/tmp/lima"

examples/almalinux-9.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ images:
1313
arch: "x86_64"
1414
- location: "https://repo.almalinux.org/almalinux/9/cloud/aarch64/images/AlmaLinux-9-GenericCloud-latest.aarch64.qcow2"
1515
arch: "aarch64"
16+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
17+
mountType: "reverse-sshfs"
1618
mounts:
1719
- location: "~"
1820
- location: "/tmp/lima"

examples/centos-stream-8.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ images:
1717
arch: "x86_64"
1818
- location: "https://cloud.centos.org/centos/8-stream/aarch64/images/CentOS-Stream-GenericCloud-8-latest.aarch64.qcow2"
1919
arch: "aarch64"
20+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
21+
mountType: "reverse-sshfs"
2022
mounts:
2123
- location: "~"
2224
- location: "/tmp/lima"

examples/centos-stream-9.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ images:
1414
arch: "x86_64"
1515
- location: "https://cloud.centos.org/centos/9-stream/aarch64/images/CentOS-Stream-GenericCloud-9-latest.aarch64.qcow2"
1616
arch: "aarch64"
17+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
18+
mountType: "reverse-sshfs"
1719
mounts:
1820
- location: "~"
1921
- location: "/tmp/lima"

examples/debian-11.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ images:
1414
- location: "https://cloud.debian.org/images/cloud/bullseye/latest/debian-11-genericcloud-arm64.qcow2"
1515
arch: "aarch64"
1616

17+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
18+
mountType: "reverse-sshfs"
1719
mounts:
1820
- location: "~"
1921
- location: "/tmp/lima"

examples/debian-12.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ images:
1414
- location: "https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-genericcloud-arm64.qcow2"
1515
arch: "aarch64"
1616

17+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
18+
mountType: "reverse-sshfs"
1719
mounts:
1820
- location: "~"
1921
- location: "/tmp/lima"

examples/default.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ mounts:
9999

100100
# Mount type for above mounts, such as "reverse-sshfs" (from sshocker), "9p" (EXPERIMENTAL (until Lima v1.0), from QEMU’s virtio-9p-pci, aka virtfs),
101101
# or "virtiofs" (EXPERIMENTAL, needs `vmType: vz`)
102-
# 🟢 Builtin default: "reverse-sshfs" (for QEMU), "virtiofs" (for vz)
102+
# 🟢 Builtin default: "9p" (for QEMU, since Lima v1.0), "virtiofs" (for vz)
103103
mountType: null
104104

105105
# Lima disks to attach to the instance. The disks will be accessible from inside the

examples/deprecated/centos-7.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ images:
1212
containerd:
1313
system: false
1414
user: false
15+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel.
16+
mountType: "reverse-sshfs"
1517
mounts:
1618
- location: "~"
1719
- location: "/tmp/lima"

examples/experimental/opensuse-tumbleweed.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ images:
1717
- location: "https://provo-mirror.opensuse.org/ports/aarch64/tumbleweed/appliances/openSUSE-Tumbleweed-ARM-JeOS-efi.aarch64.qcow2"
1818
arch: "aarch64"
1919

20+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
21+
mountType: "reverse-sshfs"
2022
mounts:
2123
- location: "~"
2224
- location: "/tmp/lima"

examples/opensuse.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ images:
55
arch: "x86_64"
66
- location: "https://download.opensuse.org/distribution/leap/15.5/appliances/openSUSE-Leap-15.5-Minimal-VM.aarch64-Cloud.qcow2"
77
arch: "aarch64"
8+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
9+
mountType: "reverse-sshfs"
810
mounts:
911
- location: "~"
1012
- location: "/tmp/lima"

examples/oraclelinux-8.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ images:
1212
- location: "https://yum.oracle.com/templates/OracleLinux/OL8/u8/aarch64/OL8U8_aarch64-kvm-b42.qcow"
1313
arch: "aarch64"
1414
digest: "sha256:8fe33ebf15780a2d3917a80b3bddabac834f97ac62fc677d35480ebc80cd6db5"
15+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
16+
mountType: "reverse-sshfs"
1517
mounts:
1618
- location: "~"
1719
- location: "/tmp/lima"

examples/oraclelinux-9.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ images:
99
- location: "https://yum.oracle.com/templates/OracleLinux/OL9/u2/aarch64/OL9U2_aarch64-kvm-b39.qcow"
1010
arch: "aarch64"
1111
digest: "sha256:48351bc318b59ab6d54a2f22d11a28891cd54b9ec2fbbcdf83a7c8483b856221"
12+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
13+
mountType: "reverse-sshfs"
1214
mounts:
1315
- location: "~"
1416
- location: "/tmp/lima"

examples/rocky-8.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ images:
1010
- location: "https://dl.rockylinux.org/pub/rocky/8.8/images/aarch64/Rocky-8-GenericCloud-Base-8.8-20230518.0.aarch64.qcow2"
1111
arch: "aarch64"
1212
digest: "sha256:dcedb823982fab67094c6c8237b8c06e28cf5c4a7bfe7db43ff23c1b9347c746"
13+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
14+
mountType: "reverse-sshfs"
1315
mounts:
1416
- location: "~"
1517
- location: "/tmp/lima"

examples/rocky-9.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ images:
77
- location: "http://dl.rockylinux.org/pub/rocky/9.2/images/aarch64/Rocky-9-GenericCloud-Base-9.2-20230513.0.aarch64.qcow2"
88
arch: "aarch64"
99
digest: "sha256:eb7752c0be359007ad470e43b0d8c921e31d3ad7d4bcec9b6a2b18a8d17c05d8"
10+
# The mount type is set to reverse-sshfs because 9p (default for QEMU) is not supported by the guest kernel. VZ users should specify `--mount-type=virtiofs` on `limactl create` for better performance.
11+
mountType: "reverse-sshfs"
1012
mounts:
1113
- location: "~"
1214
- location: "/tmp/lima"

pkg/limayaml/defaults.go

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -518,9 +518,12 @@ func FillDefault(y, d, o *LimaYAML, filePath string) {
518518
y.MountType = o.MountType
519519
}
520520
if y.MountType == nil || *y.MountType == "" {
521-
if *y.VMType == VZ {
521+
switch *y.VMType {
522+
case VZ:
522523
y.MountType = pointer.String(VIRTIOFS)
523-
} else {
524+
case QEMU:
525+
y.MountType = pointer.String(NINEP)
526+
default:
524527
y.MountType = pointer.String(REVSSHFS)
525528
}
526529
}

0 commit comments

Comments
 (0)