From 0e674d25b34cbbd3cc3e13ffac7fc69213cf6331 Mon Sep 17 00:00:00 2001 From: Seungjae Yoo Date: Mon, 21 Sep 2026 06:19:33 +0000 Subject: [PATCH 1/2] Add passt and uidmap as dependencies of cuttlefish-podcvd Rootless Podman requires uidmap (newuidmap and newgidmap) for setting up user namespaces with subordinate UIDs/GIDs, and passt (pasta) for rootless container networking. Add them to Depends for cuttlefish-podcvd so that hosts installing the package have all required dependencies. --- container/debian/control | 2 ++ 1 file changed, 2 insertions(+) diff --git a/container/debian/control b/container/debian/control index f086d4d78c0..49daa635419 100644 --- a/container/debian/control +++ b/container/debian/control @@ -16,7 +16,9 @@ Depends: acl, crun, libnss3-tools, mkcert, + passt, podman (>= 4.4), + uidmap, yq, Pre-Depends: ${misc:Pre-Depends} Description: Cuttlefish Android Virtual Device companion package From 400a1cbb6a5e2b155083493103c27a9ac6afa047 Mon Sep 17 00:00:00 2001 From: Seungjae Yoo Date: Mon, 21 Sep 2026 06:35:59 +0000 Subject: [PATCH 2/2] Check character devices exist before modprobe in podcvd Check whether /dev/vhost-net and /dev/vhost-vsock character devices already exist and are registered in sysfs before attempting to load their modules with modprobe. --- container/debian/cuttlefish-podcvd.cuttlefish-podcvd.init | 4 ++-- container/debian/podcvd-setup | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/container/debian/cuttlefish-podcvd.cuttlefish-podcvd.init b/container/debian/cuttlefish-podcvd.cuttlefish-podcvd.init index 5d1c5f699a7..c734d5aff13 100644 --- a/container/debian/cuttlefish-podcvd.cuttlefish-podcvd.init +++ b/container/debian/cuttlefish-podcvd.cuttlefish-podcvd.init @@ -57,8 +57,8 @@ start() { echo 1 > /proc/sys/net/ipv4/ip_forward echo 1 > /proc/sys/net/ipv6/conf/all/forwarding - modprobe vhost_net || true - modprobe vhost_vsock || true + [ -c /dev/vhost-net ] && [ -e /sys/class/misc/vhost-net ] || modprobe vhost_net + [ -c /dev/vhost-vsock ] && [ -e /sys/class/misc/vhost-vsock ] || modprobe vhost_vsock ip link add "${podcvd_ifname}" type dummy ip link set "${podcvd_ifname}" up diff --git a/container/debian/podcvd-setup b/container/debian/podcvd-setup index 03d246d6516..601082b32f2 100755 --- a/container/debian/podcvd-setup +++ b/container/debian/podcvd-setup @@ -112,8 +112,8 @@ KERNEL=="vhost-vsock", RUN+="/usr/bin/setfacl -m u:$username:rw /dev/%k" EOF # Ensure vhost_net and vhost_vsock exists - modprobe vhost_net - modprobe vhost_vsock + [ -c /dev/vhost-net ] && [ -e /sys/class/misc/vhost-net ] || modprobe vhost_net + [ -c /dev/vhost-vsock ] && [ -e /sys/class/misc/vhost-vsock ] || modprobe vhost_vsock udevadm control --reload-rules udevadm trigger --action=change /dev/kvm