problem in passthroughing USB tethering to VM

why-be-banned

Member
Apr 4, 2023
34
3
8
Proxmox VE 8.0.4
Linux 6.2.16-6-pve #1 SMP PREEMPT_DYNAMIC PMX 6.2.16-7 (2023-08-01T11:23Z)

What I did:

1.Enabled USB tethering in my phone.
Screenshot_20230829-212916_Settings.png

2.passthroughed USB tethering to VM
屏幕截图 2023-08-29 214505.png
another way to pass through:
屏幕截图 2023-08-29 214308.png

The problem is:
In the windows VM, the "Remote NDIS internet sharing device" appeared for 0.1 second, then disappeared, then appeared again, then disappeared again..... again and again.

屏幕截图 2023-08-29 215441.jpg

I have tested it with another phone and have the same problem.
I have tested on another PVE machine and have the same problem.
I have tested it on a windows physical machine and there is no such problem.
 
Last edited:
I'm just curious, but what is the use-case for this? Why can't your VM use your regular Internet/LAN connection and you are trying to use a whole separate network with tethering instead?
 
I'm going to try tethering my phone at the host level on a spare server, will post back.

It works.

If you have a laptop you should still be able to hook it up to a local wired-ethernet LAN and share the internet between multiple devices in your own room, but I would recommend setting up a squid + pihole server so your ISP only sees requests coming from 1 device.

https://www.datahoards.com/installing-pi-hole-inside-a-proxmox-lxc-container/

And I would recommend to make sure you have at least 25-50GB/month phone data plan, and do not plan on watching streaming videos.

Details:

. Tethered android phone to my laptop running PVE - network interface showed up as "enx"+macaddress
. Set that interface to autostart and gave it a comment, with nothing else in the fields

. Created Bridge "vmbr4", set to autostart, put "Bridge ports" as the enx* adapter with a comment, and nothing else in the fields

. Created a Debian 12 Container with defaults (512 RAM/512 swap, 1 core)

Under Network eth0, I pointed it to vmbr4, no VLAN, no firewall
IPV4: DHCP
IPV6: SLAAC
DNS: 9.9.9.9, 1.1.1.1

Container booted up and got a DHCP 192.168.35.x IP address (not using my home / router network)

Was able to ping google, apt-get update, apt-get install packages with no issues.

Now I have not tested this solely with the phone tether and no other connection, as PVE is not really designed to work without a static address.
But the initial results are promising, and other VMs / containers should also be able to use vmbr4.

Others may be able to chime in on how to share things with NAT, setup pfsense / opnsense / ipfire, etc but it works as proof-of-concept without having to passthru a USB port to VM.

Epilogue: No idea what country / area you're in or what monthly budget you have, but in the US: Verizon Wireless offers a little white-cube wireless Internet router with 2x 1Gbit Ethernet ports and unlimited Internet (no data caps.)
 
Last edited:
Thanks for your reply, I have bought a 5G CPE device, it has Ethernet ports.

It works.

If you have a laptop you should still be able to hook it up to a local wired-ethernet LAN and share the internet between multiple devices in your own room, but I would recommend setting up a squid + pihole server so your ISP only sees requests coming from 1 device.

https://www.datahoards.com/installing-pi-hole-inside-a-proxmox-lxc-container/

And I would recommend to make sure you have at least 25-50GB/month phone data plan, and do not plan on watching streaming videos.

Details:

. Tethered android phone to my laptop running PVE - network interface showed up as "enx"+macaddress
. Set that interface to autostart and gave it a comment, with nothing else in the fields

. Created Bridge "vmbr4", set to autostart, put "Bridge ports" as the enx* adapter with a comment, and nothing else in the fields

. Created a Debian 12 Container with defaults (512 RAM/512 swap, 1 core)

Under Network eth0, I pointed it to vmbr4, no VLAN, no firewall
IPV4: DHCP
IPV6: SLAAC
DNS: 9.9.9.9, 1.1.1.1

Container booted up and got a DHCP 192.168.35.x IP address (not using my home / router network)

Was able to ping google, apt-get update, apt-get install packages with no issues.

Now I have not tested this solely with the phone tether and no other connection, as PVE is not really designed to work without a static address.
But the initial results are promising, and other VMs / containers should also be able to use vmbr4.

Others may be able to chime in on how to share things with NAT, setup pfsense / opnsense / ipfire, etc but it works as proof-of-concept without having to passthru a USB port to VM.

Epilogue: No idea what country / area you're in or what monthly budget you have, but in the US: Verizon Wireless offers a little white-cube wireless Internet router with 2x 1Gbit Ethernet ports and unlimited Internet (no data caps.)
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!