Celeb Glow
news | April 04, 2026

Can kdeconnect work in two networks at the same time?

Hi everybody and thanks for the great work you're doing; here's my question

two android phones: M, where the kdeconnect is installed and S A Kubuntu 20.04 Pc An ethernet wifi device

Case 1 - I connect to internet using M phone through usb tethering, and kdeconnect works smoothly

Case 2 - I connect to internet using M phone as an hotspot and the ethernet wifi device, and kdeconnect works smoothly

Case 3 - I connect to internet using S phone with usb tethering but I need to use kdeconnect on the M phone as a remote for my pc: it doesn't really seem to find the device, not even if I manually add the ip from kdeconnect android app. as soon as I disable that connection, kdeconnect gets going

How can I do it, in Case 3? how can I get to use S connection to surf the web while using an M network just for kdeconnect, at the same time? is there a way to route just the kdeconnect traffic to the M connection (which is, in both cases, a 192.168.43.x while the S is always 192.168.42.x)?

Thanks anyway for the help

1 Answer

Seems like I managed to obtain the result I wanted! I created another ethernet connection with my connection manager , which I use for my ethernet wi-fi device, and I called it "Ethernet-Local" : under IPv4 Settings I selected "Routes" and put a tick to "Use this connection only for resources on its network". When I want to use the other phone's usb-tethered connection, I switch on the "Ethernet-Local" connection, and the two seems to co-exist in harmony! When I'm using M as an hotspot I switch back to the normal connection, called "Ethernet-Web",

it's even easy to automate

we'll need a script that gets launched everytime something changes between connections, and it must be owned by root

sudo nano /etc/NetworkManager/dispatcher.d/90-kdecon

And here's what's inside the script

#!/bin/sh
ethweb=$(nmcli dev | grep "Ethernet-Web" | grep -w "connected")
usb=$(nmcli dev | grep "usb0" | grep -w "connected")
ethlocal=$(nmcli dev | grep "Ethernet-Local" | grep -w "connected")
if [ -n "$usb" ] && [ -n "$ethweb" ] ; then
nmcli c up Ethernet-Local
elif [ -z "$usb" ] && [ -n "$ethlocal" ] ; then
nmcli c up Ethernet-Web
fi

need to make it executable

sudo chmod +x /etc/NetworkManager/dispatcher.d/90-kdecon

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy