I have a rpi3 which is connected to a wireless wifi network using OSMC firmware. I want via tethering(ethernet cable) to share internet network to another device. I have made all the apropriate actions, i have enabled the tethering options in OSMC control panel(without receiving any error message -i have downgraded to 4.14.78-4-osmc kernel version-). But i still haven’t internet access on the final device. When i tried to user a VPN connection to the final device, everything worked perfect, so i guess that i have to asjust some settings in the rpi3 tethering configuration, such as dns, or something? Any ideas/help?
I think tethering means if your device is on ethernet, then you can share that connection via wifi but not the other way round. The connman docs are vague on this, so I’m not sure if the option WiFi to Ethernet works as expected.
But i have tried the same setup, a year ago with same rpi3 and it worked fine!
Furthermore i want to mention again that when i connect the ethernet cable to my laptop and try to connect to the internet(from my laptop) using a VPN application, everything works fine…
I dont know if in the latest versions of OSMC the tethering feature Wifi ==> Ethernet has been disabled, but i use an older version -4.14.78-4-osmc kernel- in which it should work…
Anyone else having the same issue plz?
A while back I got 99% of the way there, but I had to configure connman manually and do some iptables and routing stuff and I don’t think I ever got the ‘tethered’ device to see the interweb. My use case was to have one device talk the other which had all my media on without two WiFi hops.
I had a look just now and I think the upgrade to Buster must have nuked the config I had.
So I think it should be possible to set up but needs some self-assembly.
Thank you for your answer graham.
I have tried some self-configurations but for now i didn’t manage to make it work.
I will keep looking and i will let you know if i have any update on that.
I had a quick look at this. I now have a vero on the main wifi network connected with a ethernet cable to another vero - all working.
When connman sets up a tether wifi->ethernet it makes itself 192.168.0.1 on the tethered side, so if your main network is that subnet you are in trouble. My main network is 192.168.1.0.
My notes from years ago say I set up the tether with
root@vero4tv:/home/osmc# iptables -A FORWARD -i tether -o wlan0 -j ACCEPT
root@vero4tv:/home/osmc# iptables -A FORWARD -i wlan0 -o tether -j ACCEPT
and on each of the other devices on the network
sudo ip route add 192.168.0.0/24 via 192.168.1.1
However there’s no indication that those iptables and ip route settings are still there and I can still reach the 192.168.0.0 subnet and vice-versa and all devices can ping public URLs.
What is needed, though, on every device is /etc/resolv.conf with your dns servers. Mine lists 8.8.8.8 and my main network router’s address.
Hope this helps. I can’t see why it wouldn’t work with a Pi just the same.
Edit: realised I still had a wifi connection to the second vero. When I disabled that, connman wiped /etc/resolv.conf and I lost the internet. Restoring that file from another device running OSMC made the internet come back.
It’s been a while, but I seem to recall that it will use 192.168.0.0 on the tethered side unless the main network is also 192.168.0.0, when it will switch to 192.168.1.0 on the tethered side.
wlan0: flags=-28605<UP,BROADCAST,RUNNING,MULTICAST,DYNAMIC> mtu 1500
inet 192.168.1.8 netmask 255.255.255.0 broadcast 192.168.1.255
tether: flags=-28605<UP,BROADCAST,RUNNING,MULTICAST,DYNAMIC> mtu 1500
inet 192.168.0.1 netmask 255.255.255.0 broadcast 192.168.0.255
The tether environment is on 192.168.0.1 and my main on 192.168.1.0
My route settings are the following:
osmc@osmc:~$ sudo ip route
default via 192.168.1.1 dev wlan0
192.168.0.0/24 dev tether proto kernel scope link src 192.168.0.1
192.168.1.0/24 dev wlan0 proto kernel scope link src 192.168.1.8
192.168.1.1 dev wlan0 scope link
and my main router is defined as a DNS Server:
nameserver= 192.168.1.1
Should i change any of them or add the 8.8.8.8. google dns also in the /etc/resolv.conf file?
What device are you connecting via ethernet? It’s that device that needs to be told the nameserver. For another OSMC device /etc/resolv.conf would look like
It’s a pay-TV set-top box. And i just want to connect it to the internet in order to have access in movies, series, etc.
I can’t configure the set-top box manually unfortunately.
I had made it to play before with the same devices without any specific configuration in osmc.
Update:
I tried to tether my laptop instead of the set-top box.
At first i hade the same issue, the internet didn’t worked.
Then i configured manually the dns server of my laptop to 192.168.0.1(the default gateway of osmc) and it worked fine!
I don’t know. Interesting that your laptop is happy with a DNS setting of 192.168.0.1. Connman is providing DHCP on 192.168.0.0 but I didn’t think it acted as a DNS relay - that’s why I set my router’s IP as the second nameserver.
But if OSMC/connman is providing routing, DHCP and DNS then your set-top box should be happy - what else would it need?
Odd that the STB would provide ethernet but no means of setting a manual IP/gateway/DNS. Maybe a factory re-set would bring it to its senses.
I tried to factory re-set my STB but the issue is still the same.
The actual problem is that all the tethered devices i tried(STB & Laptop), cannot take automated the dns server(192.168.0.1).
In the laptop where i can configure the dns server manually, everything works fine, but in the STB i cannot configure the DNS manually.
Is there any way to configure the osmc(via connman i don’t know) in order to force all the tethered devices to use by default the dns 192.168.0.1?
I think what’s needed is for connman to say ‘look at me, I’m a DNS’ but you’re stretching the boundaries of my knowledge of both networking and connman now. IIRC connman documentation (such that it is) is on github.
@Tom_Doyle after so much troubleshooting, the FallbackNameservers proposal, solved my problem!
STB finally connected to the internet, i am so excited!!!
Thank you very much guys for your time and your suggestions in order to find a solution to my problem.
Thank you all guys, and especially @grahamh for your support