[1] MLD-5.x / Systems / x86 Systeme (PC) / {MLD 5.4 testing} Wifi Hotspot
 

Offline gr4vity

  • Expert Member
  • *****
  • Posts: 604
    • View Profile
{MLD 5.4 testing} Wifi Hotspot
« on: April 24, 2020, 01:14:51 »



Hello,
I'm trying to create virtual wifi hotspot using the app in screenshot, although there is no errors after running it but it doesn't create a wifi connection.

The app depends on create_ap, so i tried to run it to see what happens.

Code: [Select]
MLD> create_ap wlan0 eth0 MLD-Hotspot wifi0000
WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt
Config dir: /tmp/create_ap.wlan0.conf.XXfyvsjZ
PID: 6615
Sharing Internet using method: nat
iptables v1.6.0: can't initialize iptables table `nat': Table does not exist (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.

Doing cleanup.. done

The problem is there are no iptables modules in MLD
I looked in my Ubuntu system, those modules should be in the following path

/lib/modules/5.x.x/kernel/net/ipv4/netfilter/iptable_filter.ko
/lib/modules/5.x.x/kernel/net/ipv4/netfilter/iptable_nat.ko
/lib/modules/5.x.x/kernel/net/ipv4/netfilter/ip_tables

Is it possible to compile them myself?
Any guide please?

Here is the app link in case someone interested to try it.

https://github.com/lakinduakash/linux-wifi-hotspot

Best Regards.
« Last Edit: April 24, 2020, 02:19:58 by gr4vity »

Offline clausmuus

  • Administrator
  • Expert Member
  • ********
  • Posts: 20529
    • View Profile
    • ClausMuus.de
{MLD 5.4 testing} Wifi Hotspot
« Reply #1 on: April 24, 2020, 11:10:00 »
May be you should try the iptables package :)
MLD 5.5 - Raspberry PI - 7" Touch TFT - Squeeze Play
MLD 6.5 - lirc yaUsbIR - OctopusNet - XFX GeForce 9300 mit Intel E3200 - 2GB RAM - 22TB HDD - Lian Li PC-C37B - Samsung LE40A559

Offline gr4vity

  • Expert Member
  • *****
  • Posts: 604
    • View Profile
{MLD 5.4 testing} Wifi Hotspot
« Reply #2 on: April 24, 2020, 15:22:32 »


Hi Claus,
It works great after building iptables package in docker container  :D
Thank you very much.
I only had to repack it coz of the following error

Code: [Select]
Unpacking iptables (1.6.0-3+5.4.20.202.42) ...
dpkg: error processing archive iptables_1.6.0-3+5.4.20.202.42_amd64.deb (--install):
 trying to overwrite '/lib/modules/5.4.20.202.42/kernel/net/llc/llc.ko', which is also in package network-wireless-drivers 0-10.6+5.4.20.202.42
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)

By the way, i don't know why i see this warning message
WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt
It doesn't show up on Ubuntu system.
Any idea?

« Last Edit: April 24, 2020, 16:10:51 by gr4vity »

Offline clausmuus

  • Administrator
  • Expert Member
  • ********
  • Posts: 20529
    • View Profile
    • ClausMuus.de
{MLD 5.4 testing} Wifi Hotspot
« Reply #3 on: April 24, 2020, 17:08:07 »
I have change the testing network wireless package. Please test if the conflickt is now gone.
MLD 5.5 - Raspberry PI - 7" Touch TFT - Squeeze Play
MLD 6.5 - lirc yaUsbIR - OctopusNet - XFX GeForce 9300 mit Intel E3200 - 2GB RAM - 22TB HDD - Lian Li PC-C37B - Samsung LE40A559

Offline gr4vity

  • Expert Member
  • *****
  • Posts: 604
    • View Profile
{MLD 5.4 testing} Wifi Hotspot
« Reply #4 on: April 24, 2020, 22:05:52 »



I have tested it, network-wireless-drivers package doesn't conflict with iptables package anymore.

By the way, i will ignore the following msg as long as wifi internet sharing connection is working fine.

Code: [Select]
WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt
mit besten grüßen  :)
« Last Edit: April 24, 2020, 22:11:13 by gr4vity »

Offline gr4vity

  • Expert Member
  • *****
  • Posts: 604
    • View Profile
{MLD 5.4 testing} Wifi Hotspot
« Reply #5 on: April 27, 2020, 16:34:38 »
Hi Claus,

I repacked dnsmasq coz it conflicts with curl.

Code: [Select]
Unpacking dnsmasq (2.76-1) ...
dpkg: error processing archive /var/cache/apt/archives/dnsmasq_2.76-1_amd64.deb (--unpack):
 trying to overwrite '/usr/bin/curl', which is also in package curl 7.52.1-5+deb9u10
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)

There is an option to share the internet from the same WiFi interface which works fine on Ubuntu as follows:

Code: [Select]
~/create_ap# create_ap wlp3s1 wlp3s1 MLD-Hotspot wifi0000
Config dir: /tmp/create_ap.wlp3s1.conf.KmB2KqkG
PID: 4179
Network Manager found, set ap0 as unmanaged device... DONE
Creating a virtual WiFi interface... ap0 created.
Sharing Internet using method: nat
hostapd command-line interface: hostapd_cli -p /tmp/create_ap.wlp3s1.conf.KmB2KqkG/hostapd_ctrl
Configuration file: /tmp/create_ap.wlp3s1.conf.KmB2KqkG/hostapd.conf
Using interface ap0 with hwaddr 00:01:00:00:00:00 and ssid "MLD-Hotspot"
ap0: interface state UNINITIALIZED->ENABLED
ap0: AP-ENABLED

It means that my wifi adapter is supported however it doesn't work on MLD

Code: [Select]
MLD> create_ap wlan0 wlan0 MLD-Hotspot wifi0000
WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt
ERROR: You can not share your connection from the same interface if you are using --no-virt option.

Any idea?

I also noticed the missing iptables modules i reported in post #1 are still not there

Code: [Select]
MLD> modprobe ip_tables
modprobe: module ip_tables not found in modules.dep

MLD> modprobe iptable_filter
modprobe: module iptable_filter not found in modules.dep

MLD> modprobe x_tables
modprobe: module x_tables not found in modules.dep

Is it possible to upgrade iptables package with the missing modules?

Best Regards.

Offline clausmuus

  • Administrator
  • Expert Member
  • ********
  • Posts: 20529
    • View Profile
    • ClausMuus.de
{MLD 5.4 testing} Wifi Hotspot
« Reply #6 on: April 28, 2020, 15:33:55 »
That modules are buildin into the kernel.
MLD 5.5 - Raspberry PI - 7" Touch TFT - Squeeze Play
MLD 6.5 - lirc yaUsbIR - OctopusNet - XFX GeForce 9300 mit Intel E3200 - 2GB RAM - 22TB HDD - Lian Li PC-C37B - Samsung LE40A559

Offline gr4vity

  • Expert Member
  • *****
  • Posts: 604
    • View Profile
{MLD 5.4 testing} Wifi Hotspot
« Reply #7 on: April 28, 2020, 17:43:41 »
Hello Claus,

The iptables package hasn't been updated since 2017, perhaps you could modify it in order to build the missing modules.

That modules are buildin into the kernel.

I don't understand, you mean that kernel 5.4.28 source doesn't have  ip_tables, iptable_filter, iptable_nat, x_tables?

Offline clausmuus

  • Administrator
  • Expert Member
  • ********
  • Posts: 20529
    • View Profile
    • ClausMuus.de
{MLD 5.4 testing} Wifi Hotspot
« Reply #8 on: April 28, 2020, 18:36:22 »
No, the modules are includet into the kernel and so they are always loaded. There is no need (and posibility) to load them by modprobe.
MLD 5.5 - Raspberry PI - 7" Touch TFT - Squeeze Play
MLD 6.5 - lirc yaUsbIR - OctopusNet - XFX GeForce 9300 mit Intel E3200 - 2GB RAM - 22TB HDD - Lian Li PC-C37B - Samsung LE40A559

Offline clausmuus

  • Administrator
  • Expert Member
  • ********
  • Posts: 20529
    • View Profile
    • ClausMuus.de
{MLD 5.4 testing} Wifi Hotspot
« Reply #9 on: April 29, 2020, 08:52:31 »
Since the Modules are included in the kernel, you can't load them, and can't see them by lsmod.
MLD 5.5 - Raspberry PI - 7" Touch TFT - Squeeze Play
MLD 6.5 - lirc yaUsbIR - OctopusNet - XFX GeForce 9300 mit Intel E3200 - 2GB RAM - 22TB HDD - Lian Li PC-C37B - Samsung LE40A559

Offline gr4vity

  • Expert Member
  • *****
  • Posts: 604
    • View Profile
{MLD 5.4 testing} Wifi Hotspot
« Reply #10 on: May 03, 2020, 16:36:10 »
Hi Claus,
I deleted unnecessary replies coz the problem wasn't related to iptables package.

Problem is now solved after running the following commands which i found in the developer repo.

Code: [Select]
iw dev wlan0 interface add ap0 type managed
ip link set down dev ap0
ip addr flush ap0
ip link set dev ap0 address 00:11:22:33:44:55
ip link set up dev ap0
ip addr add 192.168.12.1/24 broadcast 192.168.12.255 dev ap0

Here you go

Code: [Select]
MLD> create_ap wlan0 wlan0 MLD-Hotspot wifi0000
Config dir: /tmp/create_ap.wlan0.conf.XXvDLkXp
PID: 20086
wlan0 is already associated with channel 10 (2457 MHz), fallback to channel 10
Creating a virtual WiFi interface... ap0 created.
Sharing Internet using method: nat
hostapd command-line interface: hostapd_cli -p /tmp/create_ap.wlan0.conf.XXvDLkXp/hostapd_ctrl
Configuration file: /tmp/create_ap.wlan0.conf.XXvDLkXp/hostapd.conf
Using interface ap0 with hwaddr 00:01:00:00:00:00 and ssid "MLD-Hotspot"
ap0: interface state UNINITIALIZED->ENABLED
ap0: AP-ENABLED

This feature is really nice coz i was able to create an AP on the same WIFI adapter without any connected Ethernet cable.  :D

You should try it too, which WIFI adapter do you have?



[1] MLD-5.x / Systems / x86 Systeme (PC) / {MLD 5.4 testing} Wifi Hotspot
 



Users Online Users Online

0 Members and 1 Guest are viewing this topic.