I’m looking for a way to share my internet, which is connected via VPN, as a Wi-Fi hotspot on Linux (endeavor Linux). My goal is to share the VPN internet with other devices, such as my mobile phone, through a Wi-Fi hotspot.
Here are the details:
My wireless interface is wlan0.
My VPN is active on the ppp0 interface.
When I run the create_ap command, I encounter errors like “invalid arithmetic operator” and “Your adapter can not transmit to channel 0”.
Question: What methods are available to share VPN internet as a Wi-Fi hotspot?
I’d appreciate it if anyone with experience in this area could offer some help.
I’m not aware of your entire network set up, but it sounds like it would be easier to set up the VPN on your router and then connect to it on wifi with your phone and let it route the traffic through the VPN. If that’s not an option, it’s like that what you are trying to do is possible (assuming you have the right hardware), but it’s not something I’ve ever done myself.
The problem is that I create something like this, but when I click connect, it disconnects my main internet on my laptop, which is connected via Wi-Fi.
It shows a program used on Linux, and it’s from here:
Just a note: if you install it and it doesn’t connect, try changing the channel on your Wi-Fi. For me, it was channel 6.
Also, make sure to turn off the firewall. However, if you find a way to make it work without turning off the firewall, I’d really appreciate it if you could let me know.
Firewall solution:
To solve this, I searched through this link and found these solutions:
There are also options like Open WRT available for ARM-based hardware like a raspberry pi. Using a production machine as a router, while possible, is not ideal in the long term. From a power-consumption perspective, you’d be better off configuring your VPN at a router level and running off that.