Page 1 of 1

How to share wifi through ethernet port as a wireless extender?

Posted: Tue Jul 12, 2022 8:13 am
by jabbado

Just wondering if this would be possible with puppy.

I have an old Dell Inspiron mini someone gave me. Could I install puppy on it, have it connected to my wifi network (if the adapter will work) and share the connection through the ethernet port to another device which doesn't have wifi?

EDIT: So I have Bionic installed and the wifi adapter is working "out of the box". However none of the gui tools seem to have options for sharing internet. Will this have to be done via the terminal, if at all possible?


Re: share wifi through ethernet port as a wireless extender

Posted: Tue Jul 12, 2022 12:35 pm
by mouldy

Internet----(eth0/wlan0)-Linux-(eth1)------Another PC

Assume this is what you want?

If so then you might look at https://github.com/garywill/linux-router

I have not used this and have never tried sharing an internet connection on one computer to another directly through ethernet. Several articles for doing this in linux like Ubuntu and Manjaro, using network manager. But not sure in Puppy though some mention of it over decade ago on the old Murga forum.

Lot more common to share an internet connection (any kind) by creating a wifi hotspot. Create_ap was always my goto for this, but it only shares via wifi hotspot. Cant share via ethernet. It made life lot easier than trying to set up a hotspot manually.

Lot people here far more experienced than me with networking and may have easy way already in Puppy. But if not, might want to look at link above, think it would do what you want.


Re: share wifi through ethernet port as a wireless extender

Posted: Tue Jul 12, 2022 1:23 pm
by bigpup

First :welcome:

So I have Bionic installed

You have to be very specific about the Puppy version.
Is this Bionicpup32 8.0?
Bionicpup64 8.0?

All versions of Puppy are slightly different.
Even the two versions of Bionicpup are different.
Big difference:
32bit
64bit
Slightly different programs in them.

We always need this specific info,
The Puppy version.

However, more info could be needed and posting it, in the first post of the topic, helps all of us.

This is info that always helps:
https://forum.puppylinux.com/viewtopic.php?t=218


Re: share wifi through ethernet port as a wireless extender

Posted: Tue Jul 12, 2022 8:36 pm
by jabbado
bigpup wrote: Tue Jul 12, 2022 1:23 pm

You have to be very specific about the Puppy version.
Is this Bionicpup32 8.0?
Bionicpup64 8.0?

Sorry yes it's Bionicpup32-8.0 with frugal install.

I found this guide
Which seems to be roughly what I want. However it'd be good to have dhcp working rather than having to use a static ip on the connected device.

mouldy wrote: Tue Jul 12, 2022 12:35 pm

If so then you might look at https://github.com/garywill/linux-router

That actually looks promising. Thanks!


Re: share wifi through ethernet port as a wireless extender

Posted: Wed Jul 13, 2022 12:24 am
by williwaw

Re: share wifi through ethernet port as a wireless extender

Posted: Wed Jul 13, 2022 3:45 am
by jabbado
mouldy wrote: Tue Jul 12, 2022 12:35 pm

Internet----(eth0/wlan0)-Linux-(eth1)------Another PC

Assume this is what you want?

If so then you might look at https://github.com/garywill/linux-router

I can't get this to work as the script attempts to initially backup settings and complains with:

Code: Select all

ERROR: Failed backing up interface ipv6 bits

It seems to be looking for config in /proc/sys/net/ipv6 directory which doesn't exist. And the script doesn't have an option to disable ipv6 use, only to enable it.
I'm guessing BionicPup32 doesn't have ipv6 enabled by default?


Re: How to share wifi through ethernet port as a wireless extender?

Posted: Thu Jul 14, 2022 2:08 am
by Phoenix

More likely the kernel doesn't even have Ipv6 seeing it was supported since 1996.
Maybe try bridging?


Re: How to share wifi through ethernet port as a wireless extender?

Posted: Thu Jul 14, 2022 9:54 am
by rcrsn51

@williwaw: Thank you for posting the link to Routermaker. I have it working with several Puppies.


Re: share wifi through ethernet port as a wireless extender

Posted: Thu Jul 14, 2022 12:44 pm
by mouldy
jabbado wrote: Wed Jul 13, 2022 3:45 am
mouldy wrote: Tue Jul 12, 2022 12:35 pm

Internet----(eth0/wlan0)-Linux-(eth1)------Another PC

Assume this is what you want?

If so then you might look at https://github.com/garywill/linux-router

I can't get this to work as the script attempts to initially backup settings and complains with:

Code: Select all

ERROR: Failed backing up interface ipv6 bits

It seems to be looking for config in /proc/sys/net/ipv6 directory which doesn't exist. And the script doesn't have an option to disable ipv6 use, only to enable it.
I'm guessing BionicPup32 doesn't have ipv6 enabled by default?

Are you trying to use "eth1" as in example, is it telling you it doesnt exist???

I may have a copy of 32bit Bionicpup somewhere, I remember using it long ago. But seeing how I currently have MX19 running, I installed lnxrouter script to it. I got following. First the no ipv6 bits when I tried to set it using eth1. But when I tried the existing eth0, it works.

nowhereman@mx:~
$ sudo lnxrouter -i eth1
linux-router 0.6.6 (https://github.com/garywill/linux-router)
Released under LGPL, with no warranty. Use on your own risk.

PID: 6646
Target interface is eth1 ()
Use random LAN IPv4 address 192.168.35.1
Device "eth1" does not exist.
cp: cannot stat '/proc/sys/net/ipv6/conf/eth1/disable_ipv6': No such file or directory
cp: cannot stat '/proc/sys/net/ipv6/conf/eth1/accept_ra': No such file or directory
cp: cannot stat '/proc/sys/net/ipv6/conf/eth1/use_tempaddr': No such file or directory
cp: cannot stat '/proc/sys/net/ipv6/conf/eth1/addr_gen_mode': No such file or directory
Error occured

ERROR: Failed backing up interface ipv6 bits

Doing cleanup..
Undoing iptables changes ..
Exiting: This is the only running instance
Cleaning up done

^See same error you got.

nowhereman@mx:~
$ sudo lnxrouter -i eth0
linux-router 0.6.6 (https://github.com/garywill/linux-router)
Released under LGPL, with no warranty. Use on your own risk.

PID: 6710
Target interface is eth0 (c8:9c:dc:53:83:17) PCI: 0000:01:00.0 Ethernet controller [0200]: Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller [10ec:8168] (rev 03)
Use random LAN IPv4 address 192.168.85.1

iptables v1.8.2 (nf_tables)
NOTICE: Not showing all operations done to iptables rules

iptables: NAT
MASQUERADE all opt -- in * out !eth0 192.168.85.0/24 !-> 192.168.85.0/24 /* lrt6710eth0 */
ACCEPT all opt -- in eth0 out * 192.168.85.0/24 -> 0.0.0.0/0 /* lrt6710eth0 */
ACCEPT all opt -- in * out eth0 0.0.0.0/0 -> 192.168.85.0/24 /* lrt6710eth0 */
Loaded kernel module nf_nat_pptp

iptables: allow DNS
ACCEPT tcp opt -- in eth0 out * 192.168.85.0/24 -> 192.168.85.1 tcp dpt:53 /* lrt6710eth0 */
ACCEPT udp opt -- in eth0 out * 192.168.85.0/24 -> 192.168.85.1 udp dpt:53 /* lrt6710eth0 */

iptables: allow dhcp
ACCEPT udp opt -- in eth0 out * 0.0.0.0/0 -> 0.0.0.0/0 udp dpt:67 /* lrt6710eth0 */

Starting dnsmasq
Jul 14 07:34:09 dnsmasq[6787]: started, version 2.80 cachesize 150
Jul 14 07:34:09 dnsmasq[6787]: compile time options: IPv6 GNU-getopt DBus i18n IDN DHCP DHCPv6 no-Lua TFTP conntrack ipset auth DNSSEC loop-detect inotify dumpfile
Jul 14 07:34:09 dnsmasq-dhcp[6787]: DHCP, IP range 192.168.85.10 -- 192.168.85.250, lease time 1h
Jul 14 07:34:09 dnsmasq-dhcp[6787]: DHCP, sockets bound exclusively to interface eth0
Jul 14 07:34:09 dnsmasq[6787]: reading /etc/resolv.conf
Jul 14 07:34:09 dnsmasq[6787]: using nameserver 8.8.8.8#53
Jul 14 07:34:09 dnsmasq[6787]: using nameserver 8.8.4.4#53
Jul 14 07:34:09 dnsmasq[6787]: using nameserver 91.239.100.100#53
Jul 14 07:34:09 dnsmasq[6787]: using nameserver 194.187.251.67#53
Jul 14 07:34:09 dnsmasq[6787]: using nameserver 9.9.9.9#53
Jul 14 07:34:09 dnsmasq[6787]: using nameserver 1.1.1.1#53
Jul 14 07:34:09 dnsmasq[6787]: cleared cache
dnsmasq PID: 6787

== Setting up completed, now linux-router should be working ==

^Here it succeeded cause eth0 exists. There is an ethernet card and it sees it as eth0 even though I am not using it. I imagine if I plugged cable into it and into another computer, the other would share my existing connection on this computer no matter the source. I probably have some ethernet cable around here somewhere but havent used it in years so no idea where or I would try it.


Re: share wifi through ethernet port as a wireless extender

Posted: Fri Jul 15, 2022 8:37 pm
by jabbado
mouldy wrote: Thu Jul 14, 2022 12:44 pm

Are you trying to use "eth1" as in example, is it telling you it doesnt exist???
...

No the problem seems to be lack of ipv6 support in BionicPup32. I haven't played with linux in a long time so not sure of the real reason.
The lnxrouter script attempts to backup current network config before making changes and since the /proc/sys/net/ipv6 directory is missing it errors out. I asked the author of the script and he said try commenting out the ipv6 stuff which I did but then ran into other dependency issues. This is all potentially fixable once the deps are installed but I haven't had time yet.

I decided to try lnxrouter on Lubuntu 18.04 and it works great so definitely want to get it working in Pup.

Is there a Puppy 32-bit flavor which has ipv6 support out of the box?

**EDIT: Scrap the last bit. After more playing around I discovered the ipv6 kernel module does exist and just needed loading. It now loads on boot after adding it to MODULESCONFIG
But now the lnxrouter script errors out because the file

/proc/sys/net/ipv6/conf/ens33/addr_gen_mode

doesn't exist. when and how is this file created?


Re: How to share wifi through ethernet port as a wireless extender?

Posted: Sat Jul 16, 2022 4:15 am
by rcrsn51

RouterMaker can do what you want. See the note about using BIonicpup32.


Re: share wifi through ethernet port as a wireless extender

Posted: Sat Jul 16, 2022 5:04 am
by mouldy
jabbado wrote: Fri Jul 15, 2022 8:37 pm
mouldy wrote: Thu Jul 14, 2022 12:44 pm

Are you trying to use "eth1" as in example, is it telling you it doesnt exist???
...

No the problem seems to be lack of ipv6 support in BionicPup32. I haven't played with linux in a long time so not sure of the real reason.
The lnxrouter script attempts to backup current network config before making changes and since the /proc/sys/net/ipv6 directory is missing it errors out. I asked the author of the script and he said try commenting out the ipv6 stuff which I did but then ran into other dependency issues. This is all potentially fixable once the deps are installed but I haven't had time yet.

I decided to try lnxrouter on Lubuntu 18.04 and it works great so definitely want to get it working in Pup.

Is there a Puppy 32-bit flavor which has ipv6 support out of the box?

**EDIT: Scrap the last bit. After more playing around I discovered the ipv6 kernel module does exist and just needed loading. It now loads on boot after adding it to MODULESCONFIG
But now the lnxrouter script errors out because the file

/proc/sys/net/ipv6/conf/ens33/addr_gen_mode

doesn't exist. when and how is this file created?

Without putting super amount energy into this, I tried booting first three 32bit dvds I found. Dpup Buster 8.0.0 had same problem you had with Bionicpup. Now I also booted Bionic DOG and Buster DOG. Both 32bit, they are Fred's creations, not official puppies, but very Puppy-like, much more mini Ubuntu/Debian though. Anyway they ran the script but errored out missing dnsmask. Its big hassle for me to go online with live dvd for one time effort, since I have to setup either Azilink or EasyTether to share internet with my phone. No other internet. Or I would installed dnsmask. I think likely 32bit Bionic Dog or Buster Dog would be easiest way to go since they dont have the ipv6 issues. Apparently as you say some kernel issues in 32bit Puppies around ipv6 for whatever reason.


Re: How to share wifi through ethernet port as a wireless extender?

Posted: Sat Jul 16, 2022 5:47 am
by mouldy
rcrsn51 wrote: Sat Jul 16, 2022 4:15 am

RouterMaker can do what you want.

No doubt that would be easier, and for sure worth trying if needed NOW since its been set up as puppy package. But sometimes its interesting why something isnt working as much as it is having it work first time out of box. The "linux-router" script is interesting and does work nicely in MX19. And according to OP, also in Lubuntu. I think after adding dnsmask, it should work ok in Bionic Dog and Buster Dog, well if there isnt any other missing bits. But the dogs dont have the kernel issues with ipv6. I havent paid lot attention to 32bit Puppies, maybe if there are any with newer kernel, might work too.


Re: How to share wifi through ethernet port as a wireless extender?

Posted: Sat Jul 16, 2022 8:37 pm
by jabbado
mouldy wrote: Sat Jul 16, 2022 5:47 am

But sometimes its interesting why something isnt working as much as it is having it work first time out of box.

Yeah that was my point - to learn how and why.
I got it working fairly easily in both Jammy and FocalPup (newest versions).

But after looking at the RouterMaker script - which I originally thought only worked with wired connections - I can see it does a lot less changes to the system. It basically runs the commands you'd normally do manually for IP masquerading, with less dependencies required. So I'll give that a shot and see if it runs on more bare systems.