No internet access through Pinephone hot spot
#1
I decided to try out the wifi hot spot feature since that looks like something that could be useful. Out of the box, the "Turn on Wi-Fi Hotspot" 3 dots menu item in Settings/Wi-Fi is greyed out. So I set it up via command line per the Mobian wiki :

Code:
sudo nmcli device wifi hotspot ifname wlan0 con-name Hotspot ssid Pinephone password HotspotPassword

This sets up the hot spot and connecting to it works, however there is no internet connectivity through that connection. (This is tested by pinging 8.8.8.8 so there are no name resolution issues.) Routing table on the laptop shows the default gateway as 10.42.0.1 and that pings, but nothing further out.

The phone is connected to 4G and has internet access itself. I've tried with a couple of different laptops with the same result. For test purposes firewalls on the phone and laptops are disabled. (A side effect seems to be that King's Cross terminal no longer responds to the virtual keyboard when the hot spot is enabled.) Rebooting the phone for good measure did not change the result.

Is there any other configuration that needs to be done, or is this something that is currently known not to work?
#2
(12-23-2020, 08:48 AM)Zebulon Walton Wrote: I decided to try out the wifi hot spot feature since that looks like something that could be useful. Out of the box, the "Turn on Wi-Fi Hotspot" 3 dots menu item in Settings/Wi-Fi is greyed out. So I set it up via command line per the Mobian wiki :

Code:
sudo nmcli device wifi hotspot ifname wlan0 con-name Hotspot ssid Pinephone password HotspotPassword

This sets up the hot spot and connecting to it works, however there is no internet connectivity through that connection. (This is tested by pinging 8.8.8.8 so there are no name resolution issues.) Routing table on the laptop shows the default gateway as 10.42.0.1 and that pings, but nothing further out.

The phone is connected to 4G and has internet access itself. I've tried with a couple of different laptops with the same result. For test purposes firewalls on the phone and laptops are disabled. (A side effect seems to be that King's Cross terminal no longer responds to the virtual keyboard when the hot spot is enabled.) Rebooting the phone for good measure did not change the result.

Is there any other configuration that needs to be done, or is this something that is currently known not to work?
It seems to me, that IP forwarding is not enabled. You could check it by:

---
root@mobian:~# sysctl net.ipv4.ip_forward

net.ipv4.ip_forward = 0
---

It should be 1
#3
Thanks, I did check it and that setting is being enabled automatically on the phone when the hotspot is enabled. (Also confirmed via "cat /proc/sys/net/ipv4/ip_forward".)

I also double-checked that 4G internet access is operational on the phone while the hotspot is enabled. From the phone's terminal emulator pinging google.com works, and ssh can connect to a remote host while the hotspot is up and a laptop connected. The laptop just can't ping out beyond the default gateway.
#4
I left my test setup for about an hour to do some other things and when I got back to it found that the hotspot had gone dead at some point, the laptop could no longer connect to it until  the hotspot was stopped and restarted on the phone. Then I was able to connect with the same result - from the laptop, pinging the gateway works and additionally it was able to ping to the wwan0 IP address (cellular modem) on the phone but of course still no internet access. So it looks like this is a feature that is a work in progress, which is certainly fair enough at this stage of development.
#5
(12-23-2020, 08:48 AM)Zebulon Walton Wrote: I decided to try out the wifi hot spot feature since that looks like something that could be useful. Out of the box, the "Turn on Wi-Fi Hotspot" 3 dots menu item in Settings/Wi-Fi is greyed out. So I set it up via command line per the Mobian wiki :
...

If you start with a fresh Mobian install then I suspect it should work out of the box. You have to enable WiFi first, then the "Turn on WiFi Hotspot" option will be available in the hamburger menu.

The reason I say "suspect/should" is I use USB or ethernet tethering. For sure USB tethering does indeed work out of the box on Mobian, ethernet tethering needs a tweak that can be done via the nmtui user interface. I have a multi-port USB-C dongle that includes an RJ45 socket: plug it all in then go into nmtui, edit the wired connection and change the IPv4 configuration to "Shared" (from Automatic). (In the early days this sharing was also required for USB; in fact I suspect it may be what is missing from your connection and a quick nmtui may fix things?)
  • ROCKPro64 v2.1 2GB, 16Gb eMMC for rootfs, SX8200Pro 512GB NVMe for /home, HDMI video & sound, Bluetooth keyboard & mouse. Arch (6.12 kernel, Openbox desktop) for general purpose daily PC.
  • PinePhone Pro Explorer Edition, daily driver, rk2aw & U-boot on SPI, Arch/SXMO on eMMC
  • PinePhone BraveHeart now v1.2b 3/32Gb, Tow-boot with pmOS/SXMO on eMMC
#6
(12-23-2020, 03:40 PM)dukla2000 Wrote:
(12-23-2020, 08:48 AM)Zebulon Walton Wrote: I decided to try out the wifi hot spot feature since that looks like something that could be useful. Out of the box, the "Turn on Wi-Fi Hotspot" 3 dots menu item in Settings/Wi-Fi is greyed out. So I set it up via command line per the Mobian wiki :
...

If you start with a fresh Mobian install then I suspect it should work out of the box. You have to enable WiFi first, then the "Turn on WiFi Hotspot" option will be available in the hamburger menu.

The reason I say "suspect/should" is I use USB or ethernet tethering. For sure USB tethering does indeed work out of the box on Mobian, ethernet tethering needs a tweak that can be done via the nmtui user interface. I have a multi-port USB-C dongle that includes an RJ45 socket: plug it all in then go into nmtui, edit the wired connection and change the IPv4 configuration to "Shared" (from Automatic). (In the early days this sharing was also required for USB; in fact I suspect it may be what is missing from your connection and a quick nmtui may fix things?)

Thanks, I'll have to give a fresh installation a try from a bootable SD card and play around with nmtui a bit to see how that works out.
#7
OK, I got the phone running on an SD card flashed with the latest nightly build of Mobian. I set up the APN for mobile internet and I have connectivity on the phone. Initially it was the same situation, "Turn on Wi-Fi Hotspot" greyed out, and no internet on the laptop when setting the hotspot up manually with nmcli.

However, after rebooting the phone, the GUI "Turn on Wi-Fi Hotspot" menu item was no longer greyed out. So I turned on the hotspot that way, but the laptop still had no internet connectivity. Went in with nmtui and the hotspot connection was already marked as Shared. Exited without changing or saving anything and the laptop suddenly was able to ping out to the internet. Rebooted the phone on the SD card and it still seemed to be working.

Then, booting up on my original installation I was unable to replicate that, so I guess I need to decide whether it's worth blowing away my encrypted Mobian installation on the eMMC (which otherwise is set up the way I want) in order to do this. I guess for now if I want to use the hotspot I can just boot off the SD card.


Possibly Related Threads…
Thread Author Replies Views Last Post
  Pinephone seems tobe using 4G data instead of Wifi data grump_fiddle_reinstall 6 1,025 Yesterday, 10:17 AM
Last Post: puffchumpy
  bookworm vs trixie discussion for mobian in pinephone regular. zetabeta 41 9,701 11-27-2024, 10:39 AM
Last Post: fernando_c_m
  Mobile internet via cellular network mostly not working Anna 18 14,220 01-19-2024, 02:59 AM
Last Post: anonymous
  unofficial kali linux for pinephone help needed pinesmell 5 5,205 01-08-2024, 02:50 PM
Last Post: ERPlegend
  Axolotl on PinePhone / Mobian arno_nuehm 219 204,743 03-26-2023, 01:49 AM
Last Post: shulamy
  PinePhone won't boot after software update jb2000 2 2,012 03-17-2023, 07:26 AM
Last Post: Zebulon Walton
Wink Pinephone lost graphic during mobian system upgrade cmpin 4 3,169 03-01-2023, 04:45 PM
Last Post: anonymous
  Battery problem with a Pinephone keyboard and Mobian elode 2 2,851 12-22-2022, 07:10 PM
Last Post: acid andy
  Sending Pinephone SMS from Desktop biketool 5 4,203 09-13-2022, 01:46 PM
Last Post: anonymous
  [SOLVED] Lost Internet connectivity after recent update drh 3 2,632 09-11-2022, 09:24 PM
Last Post: Katsujinken

Forum Jump:


Users browsing this thread: 1 Guest(s)