Chadster766 / McDebian

Linksys WRT3200ACM, WRT1900AC, WRT1900ACS, WRT1200AC and WRT32X Router Debian Implementation
98 stars 14 forks source link

McDebian 4.14.6 Final #44

Closed Chadster766 closed 6 years ago

Chadster766 commented 6 years ago

McDebian 4.14.6 Beta

Updates:

Firmware:

wget --user=mcdebian --password=mcdebian123 http://www.protechs-online.com/downloads/McDebian/firmwares/McDebian-Stretch-Firmwares_4.14.6.tar.gz

Root File System:

wget --user=mcdebian --password=mcdebian123 http://www.protechs-online.com/downloads/McDebian/rootfs/mcdebian-stretch-router-WRT-1900-1200-3200-Kernel_4_14_6-base.gz

To enable IPv6 in this beta release you need to enable radvd:

systemctl enable radvd

Then uncomment the IPv6 config lines in:

vim /etc/default/isc-dhcp-server

After that reboot the router.

Chadster766 commented 6 years ago

To resolve the crda kernel warning about the missing db.txt file:

# CONFIG_CFG80211_INTERNAL_REGDB is not set
CONFIG_CFG80211_CRDA_SUPPORT=y
ValCher1961 commented 6 years ago

Oh, it seems to be a translator's game. Sorry. :)

Chadster766 commented 6 years ago

Yes but I don't want the kernel using an internal reg database.

Chadster766 commented 6 years ago

I've made some modifications to the "/etc/network/interfaces" file so it will work properly with multi SSID wireless configs.

# interfaces(5) file used by ifup(8) and ifdown(8)
# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback

#auto eth0 -- Do not uncomment it will cause major startup delays
iface eth0 inet manual

auto eth1
iface eth1 inet manual

auto lan1
iface lan1 inet manual
        #locally administered mac address
        hwaddress ether 02:3b:45:92:19:06

auto lan2
iface lan2 inet manual
        hwaddress ether 02:4a:dc:6f:cd:7d

auto lan3
iface lan3 inet manual
        hwaddress ether 02:3d:2b:d9:b5:d5

auto lan4
iface lan4 inet manual
        hwaddress ether 02:e0:96:70:5f:c3

auto wlp1s0
iface wlp1s0 inet manual
        #locally administered mac address that ends with zero for multi SSID mac address generation
        pre-up ip link set wlp1s0 address 02:7a:03:6d:bb:40

auto wlp2s0
iface wlp2s0 inet manual
        pre-up ip link set wlp2s0 address 02:b1:77:35:c7:e0

auto wan
iface wan inet dhcp
        pre-up /etc/network/mcdebian-set-wan-mac-address
        pre-up iptables-restore < /etc/iptables.up.rules

iface wan inet6 auto
        pre-up ip6tables-restore < /etc/ip6tables.up.rules
        up sleep 5
        #The below line shouldn't be required with McDebian IPv6 NAT and the McDebian dhcpd6 server setup
        #up dhclient -1 -6 -cf /etc/dhcp/dhclient6.conf -lf /var/lib/dhcp/dhclient6.wan.leases -v wan || true

auto br0
iface br0 inet static
        bridge_hw 02:2d:50:bd:ca:13
        bridge_ports lan1 lan2 lan3 lan4 wlp1s0 wlp2s0
        address 192.168.1.1
        netmask 255.255.255.0
        network 192.168.1.0
        broadcast 192.168.1.255
        post-up /etc/network/mcdebian-wrt1900acV1-wrt3200-wlan

iface br0 inet6 static
        address fc00::1
        netmask 64
Chadster766 commented 6 years ago

One change that is not obvious is "pre-up /etc/network/mcdebian-wrt1900acV1-wrt3200-wlan" has been changed to "post-up /etc/network/mcdebian-wrt1900acV1-wrt3200-wlan".

ValCher1961 commented 6 years ago

What is file - mcdebian-wrt1900acV1-wrt3200-wlan?

ValCher1961 commented 6 years ago

i.e. changing it can get different SSID configurations during system boot?

Chadster766 commented 6 years ago

It displays the model number and hardware version in the journal, checks if the model is not a WRT3200ACM which causes it to bring up eth0 and standardizes the wireless config for the WRT1900AC V1 which has an extra PCIE device.

#!/bin/sh

MODEL_NUMBER=`strings /dev/mtd3 | grep 'modelNumber='`
HARDWARE_VERSION=`strings /dev/mtd3 | grep 'hw_revision='`
logger "mcdebian: $MODEL_NUMBER $HARDWARE_VERSION"

if  strings /dev/mtd3 | grep -w 'modelNumber=WRT3200ACM' >> /dev/null
then
        logger "mcdebian: WRT3200ACM Detected"
else
        logger "mcdebian: WRT3200ACM Not Detected"
        ip link set eth0 up
fi

if  strings /dev/mtd3 | grep -w 'modelNumber=WRT1900AC' >> /dev/null  &&  strings /dev/mtd3 | grep 'hw_revision=1' >>  /dev/null
then
        logger "mcdebian: WRT1900AC V1 Detected"
        sed -i 's/wlp1s0/wlp3s0/g' /etc/hostapd/wlp1s0.conf
else
        sed -i 's/wlp3s0/wlp1s0/g' /etc/hostapd/wlp1s0.conf
fi
Chadster766 commented 6 years ago

The below website is great for creating random mac addresses:

https://www.hellion.org.uk/cgi-bin/randmac.pl

ValCher1961 commented 6 years ago

It is hard to say that it is better to define the SSID configuration before or after the bridge assembly. Only a comparison can give an answer. I'm inclined to the task before assembling the bridge, but...

Chadster766 commented 6 years ago

With it pre-up the script was run four times during boot but with it post-up its run only once.

ValCher1961 commented 6 years ago

Yes, pre-up is better and leave.

jimmyw commented 6 years ago

I tried this version out, and it did not work any good for me on a WRT1900AC V1, ethernet was dead (Might be an udev enumeration problem as i just changed the kernel and extracted the kernel modules), but most of all, the fan started spinning, and fail to rest.

Reason i tried to update, was that 4.9.31 have issues failing wifi when i have extensive package load applications running, like a torrent client.

@Chadster766 Where do you get the kernel sources from? Can you provide the .config for this build also? so i can try building a kernel myself? What toolchain do you use to cross-compile your kernels? A small wiki explaining how to compile your own kernel would be highly appreciated!

4.14.6 was not added to the repo.

/Jimmy

Chadster766 commented 6 years ago

@jimmyw McDebian 4.14.6 Beta is a full installation not an update.

You need to apply the McDebian 4.16.6 firmware and use the McDebian 4.14.6 rootfs.

This beta is not compatible with the previous McDebian rootfs.

The fan control has to follow my previous fancontrol script because the Debian Stretch fancontrol package doesn't work properly. If you need the fancontrol script and systemd fancontrol service let me know and I can post here for you.

Thanks for beta testing I look forward to any observations you may have :smiley:

Redferne commented 6 years ago

@Chadster766 Can you please share your kernel .config and any magic patches that you have applied. I will most likely need to build my own kernel with raid support and iptables options for Firehol/QoS. Really looking forward to upgrade to Stretch. Your last Jessie build has been rock solid on my WRT3200ACM for months!

Chadster766 commented 6 years ago

Hi @Redferne,

I will see if I can publish this information along with this new McDebian Stretch release this week.

villesinisalo commented 6 years ago

Installed on 1900AC V2, working fine. WLAN speeds good. Great work!

andrius-pra commented 6 years ago

Installed to 1200AC V2. WAN doesn't work but I still can connect from LAN via ssh

logs from "systemctl status networking.service":

Loaded: loaded (/lib/systemd/system/networking.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2016-11-03 17:18:38 UTC; 2min 44s ago
Docs: man:interfaces(5)
  Process: 3745 ExecStart=/sbin/ifup -a --read-environment (code=exited, status=1/FAILURE)
  Process: 1604 ExecStartPre=/bin/sh -c [ "$CONFIGURE_INTERFACES" != "no" ] && [ -n "$(ifquery --read-environment --list --exclude=lo)" ] && udevadm settle (code=exited, status=0/SUCCESS)
 Main PID: 3745 (code=exited, status=1/FAILURE)

Nov 03 17:18:32 MCDEBIAN ifup[3745]: No working leases in persistent database - sleeping.
Nov 03 17:18:38 MCDEBIAN ifup[3745]: can't add wlp1s0 to bridge br0: Operation not supported
Nov 03 17:18:38 MCDEBIAN ifup[3745]: can't add wlp2s0 to bridge br0: Operation not supported
Nov 03 17:18:38 MCDEBIAN ifup[3745]: Waiting for br0 to get ready (MAXWAIT is 32 seconds).
Nov 03 17:18:38 MCDEBIAN ifup[3745]: RTNETLINK answers: File exists
Nov 03 17:18:38 MCDEBIAN ifup[3745]: ifup: failed to bring up br0
Nov 03 17:18:38 MCDEBIAN systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Nov 03 17:18:38 MCDEBIAN systemd[1]: Failed to start Raise network interfaces.
Nov 03 17:18:38 MCDEBIAN systemd[1]: networking.service: Unit entered failed state.
Nov 03 17:18:38 MCDEBIAN systemd[1]: networking.service: Failed with result 'exit-code'.

more logs are here

Chadster766 commented 6 years ago

The logs don't really explain what is causing your issue. Did you create a new USB Key using the McDebian 4.14.6 rootfs?

francispereira commented 6 years ago

Kernel McDebian-Stretch-WRT1900AC-V1-FW_VER1_kernel_4.14.6.img does not boot on a WRT-1900ac v1 after device shutdown (or power cycled). Works across reboots as long as it's not power cycled. Logs starting from kernel being written to post shutdown below

***Chadster766 remove to shorten the length of this post
Chadster766 commented 6 years ago

Thanks for testing 4.16.4 :smiley:

What do you have your kernel sizes set to?

printenv priKernSize
printenv priKernSize
francispereira commented 6 years ago
Marvell>> printenv pri_kern_size
pri_kern_size=0x400000
Marvell>> printenv alt_kern_size
alt_kern_size=0x400000
Chadster766 commented 6 years ago

In the Wiki for the WRT1900AC V1 it need to be at set to 0x405000.

https://github.com/Chadster766/McDebian/wiki/Z.X.1-McDebian-Update-4.7.5#the-router-must-be-running-mcdebian-v4416-in-order-to-apply-the-v475-update

francispereira commented 6 years ago

@Chadster766 0x405000 also falls short since it corresponds to 4.214784MiB and 4.14.6 is 4.3 MiB.

Here's what I had to do before writing the kernel to get it working on a WRT1900ac v1:

setenv pri_kern_size 0x500000
setenv alt_kern_size 0x500000

setenv flash_pri_image 'tftp ${default_load_addr} ${firmware_name}; nand erase ${pri_kern_addr} ${pri_kern_size};nand write ${default_load_addr} ${pri_kern_addr} ${filesize};'
setenv flash_alt_image 'tftp ${default_load_addr} ${firmware_name}; nand erase ${alt_kern_addr} ${alt_kern_size};nand write ${default_load_addr} ${alt_kern_addr} ${filesize};'

saveenv
reset 
andrius-pra commented 6 years ago

The logs don't really explain what is causing your issue. Did you create a new USB Key using the McDebian 4.14.6 rootfs?

yes, I'm using 4.14.6 rootfs. I get working WAN interface when I have executed few times "ifdown wan" and then "ifup wan" commands.

root@MCDEBIAN:~# /sbin/ifdown wan
Removed stale PID file
Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/
Listening on LPF/wan/60:38:e0:0c:3b:13
Sending on   LPF/wan/60:38:e0:0c:3b:13
Sending on   Socket/fallback
DHCPRELEASE on wan to 78.61.255.254 port 67
send_packet: Network is unreachable
send_packet: please consult README file regarding broadcast address.
dhclient.c:2733: Failed to send 300 byte long packet over fallback interface.

root@MCDEBIAN:~# /sbin/ifup wan
Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/
Listening on LPF/wan/60:38:e0:0c:3b:13
Sending on   LPF/wan/60:38:e0:0c:3b:13
Sending on   Socket/fallback
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 5
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 12
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 14
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 12
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 8
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 10
No DHCPOFFERS received.
No working leases in persistent database - sleeping.
root@MCDEBIAN:~# /sbin/ifup wan
ifup: interface wan already configured
root@MCDEBIAN:~# /sbin/ifdown wan
Killed old client process
Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/wan/60:38:e0:0c:3b:13
Sending on   LPF/wan/60:38:e0:0c:3b:13
Sending on   Socket/fallback
DHCPRELEASE on wan to 78.61.255.254 port 67
send_packet: Network is unreachable
send_packet: please consult README file regarding broadcast address.
dhclient.c:2733: Failed to send 300 byte long packet over fallback interface.
root@MCDEBIAN:~# /sbin/ifup wan
Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/wan/60:38:e0:0c:3b:13
Sending on   LPF/wan/60:38:e0:0c:3b:13
Sending on   Socket/fallback
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 5
DHCPDISCOVER on wan to 255.255.255.255 port 67 interval 6
DHCPREQUEST of 78.61.217.195 on wan to 255.255.255.255 port 67
DHCPOFFER of 78.61.217.195 from 78.61.255.254
DHCPACK of 78.61.217.195 from 78.61.255.254
bound to 78.61.217.195 -- renewal in 688 seconds.
francispereira commented 6 years ago

fancontrol does not work on the WRT1900ac v1. I have lm-sensors setup as documented here https://github.com/Chadster766/McDebian/wiki/B.-Thermal-Protection but pwmconfig still says /usr/sbin/pwmconfig: There are no fan-capable sensor modules installed

Chadster766 commented 6 years ago

@francispereira yes Debian Stretch package for fancontrol is broken so you need to go back to our first version of WRT1900AC V1 fancontrol script.

WRT1900AC V1 Only:

cat <<'EOF' >> /etc/systemd/system/fancontrol.service
[Unit]
Description=WRT1900AC V1 Fan Control
After=networking.service

[Service]
Type=simple
ExecStart=/usr/local/sbin/fancontrol
ExecStop=/usr/bin/pkill fancontrol
PrivateTmp=true
NonBlocking=yes

[Install]
WantedBy=multi-user.target
EOF

WRT1900AC V1 Only:

cat <<'EOF' >> /usr/local/sbin/fancontrol
#!/bin/sh

START=80        #start fan
STOP=75         #stop fan

echo 24 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio24/direction

sleep 5

while true ; do

        K=`cat /sys/class/gpio/gpio24/value`

        for TEMP in `cut -c 1-2 /sys/class/thermal/thermal_zone0/temp`; do
                if [ $TEMP -ge $START ]; then
                        if [ $K -eq 0 ]; then
                                DATE=`date`;
                                echo "$DATE: On Fan" >> /root/overheat.log
                                echo `sensors|grep +` >> /root/overheat.log
                                echo 1 > /sys/class/gpio/gpio24/value;
                                break;
                        fi
                fi
        done

        for TEMP in `cut -c 1-2 /sys/class/thermal/thermal_zone0/temp`; do
        if [ $TEMP -le $STOP ]; then
                if [ $K -eq 1 ]; then
                        DATE=`date`;
                        echo "$DATE: Off Fan" >> /root/overheat.log
                        echo `sensors|grep +` >> /root/overheat.log
                        echo 0 > /sys/class/gpio/gpio24/value;
                        break;
                fi
        fi
        done
        sleep 5
done
EOF

chmod +x /usr/local/sbin/fancontrol

Chadster766 commented 6 years ago

@andrius-pra please post your /etc/network/interfaces file.

andrius-pra commented 6 years ago
root@MCDEBIAN:~# cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
# Include files from /etc/network/interfaces.d:
source-directory /etc/network/interfaces.d

auto lo
iface lo inet loopback

#auto eth0 -- Do not uncomment it will cause major startup delays
iface eth0 inet manual

auto eth1
iface eth1 inet manual

auto lan1
iface lan1 inet manual
        #locally administered mac address
        hwaddress ether 02:3b:45:92:19:06

auto lan2
iface lan2 inet manual
        hwaddress ether 02:4a:dc:6f:cd:7d

auto lan3
iface lan3 inet manual
        hwaddress ether 02:3d:2b:d9:b5:d5

auto lan4
iface lan4 inet manual
        hwaddress ether 02:e0:96:70:5f:c3

auto wlp1s0
iface wlp1s0 inet manual
        #locally administered mac address that ends with zero for multi SSID mac address generation
        pre-up ip link set wlp1s0 address 02:7a:03:6d:bb:40

auto wlp2s0
iface wlp2s0 inet manual
        pre-up ip link set wlp2s0 address 02:b1:77:35:c7:e0

auto wan
iface wan inet dhcp
        pre-up /etc/network/mcdebian-set-wan-mac-address
        pre-up iptables-restore < /etc/iptables.up.rules

iface wan inet6 auto
        pre-up ip6tables-restore < /etc/ip6tables.up.rules
        up sleep 5
        #The below line shouldn't be required with McDebian IPv6 NAT and the McDebian dhcpd6 server setup
        #up dhclient -1 -6 -cf /etc/dhcp/dhclient6.conf -lf /var/lib/dhcp/dhclient6.wan.leases -v wan || true

auto br0
iface br0 inet static
        bridge_hw 02:2d:50:bd:ca:13
        bridge_ports lan1 lan2 lan3 lan4 wlp1s0 wlp2s0
        address 192.168.1.1
        netmask 255.255.255.0
        network 192.168.1.0
        broadcast 192.168.1.255
        post-up /etc/network/mcdebian-wrt1900acV1-wrt3200-wlan

iface br0 inet6 static
        address fc00::1
        netmask 64
root@MCDEBIAN:~#
Chadster766 commented 6 years ago

Please post output of the below commands:

ip link ip addr ip route ifconfig

andrius-pra commented 6 years ago
root@MCDEBIAN:~# ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 532
    link/ether 60:38:e0:0c:3b:13 brd ff:ff:ff:ff:ff:ff
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 532
    link/ether 2a:eb:c2:40:98:e6 brd ff:ff:ff:ff:ff:ff
4: lan4@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
    link/ether 02:e0:96:70:5f:c3 brd ff:ff:ff:ff:ff:ff
5: lan3@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
    link/ether 02:3d:2b:d9:b5:d5 brd ff:ff:ff:ff:ff:ff
6: lan2@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
    link/ether 02:4a:dc:6f:cd:7d brd ff:ff:ff:ff:ff:ff
7: lan1@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br0 state UP mode DEFAULT group default qlen 1000
    link/ether 02:3b:45:92:19:06 brd ff:ff:ff:ff:ff:ff
8: br0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether 02:2d:50:bd:ca:13 brd ff:ff:ff:ff:ff:ff
9: wan@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
    link/ether 60:38:e0:0c:3b:13 brd ff:ff:ff:ff:ff:ff
10: wlp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br0 state UP mode DEFAULT group default qlen 1000
    link/ether 02:7a:03:6d:bb:40 brd ff:ff:ff:ff:ff:ff
11: wlp2s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br0 state UP mode DEFAULT group default qlen 1000
    link/ether 02:b1:77:35:c7:e0 brd ff:ff:ff:ff:ff:ff
root@MCDEBIAN:~# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 532
    link/ether 60:38:e0:0c:3b:13 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::6238:e0ff:fe0c:3b13/64 scope link
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 532
    link/ether 2a:eb:c2:40:98:e6 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::28eb:c2ff:fe40:98e6/64 scope link
       valid_lft forever preferred_lft forever
4: lan4@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN group default qlen 1000
    link/ether 02:e0:96:70:5f:c3 brd ff:ff:ff:ff:ff:ff
5: lan3@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN group default qlen 1000
    link/ether 02:3d:2b:d9:b5:d5 brd ff:ff:ff:ff:ff:ff
6: lan2@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN group default qlen 1000
    link/ether 02:4a:dc:6f:cd:7d brd ff:ff:ff:ff:ff:ff
7: lan1@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br0 state UP group default qlen 1000
    link/ether 02:3b:45:92:19:06 brd ff:ff:ff:ff:ff:ff
8: br0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 02:2d:50:bd:ca:13 brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.1/24 brd 192.168.1.255 scope global br0
       valid_lft forever preferred_lft forever
    inet6 fc00::1/64 scope global
       valid_lft forever preferred_lft forever
    inet6 fe80::2d:50ff:febd:ca13/64 scope link
       valid_lft forever preferred_lft forever
9: wan@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
    link/ether 60:38:e0:0c:3b:13 brd ff:ff:ff:ff:ff:ff
    inet 78.61.217.195/18 brd 78.61.255.255 scope global wan
       valid_lft forever preferred_lft forever
    inet6 fe80::6238:e0ff:fe0c:3b13/64 scope link
       valid_lft forever preferred_lft forever
10: wlp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br0 state UP group default qlen 1000
    link/ether 02:7a:03:6d:bb:40 brd ff:ff:ff:ff:ff:ff
11: wlp2s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br0 state UP group default qlen 1000
    link/ether 02:b1:77:35:c7:e0 brd ff:ff:ff:ff:ff:ff
root@MCDEBIAN:~# ip route
default via 78.61.255.254 dev wan
78.61.192.0/18 dev wan proto kernel scope link src 78.61.217.195
192.168.1.0/24 dev br0 proto kernel scope link src 192.168.1.1
root@MCDEBIAN:~# ifconfig
br0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.1.1  netmask 255.255.255.0  broadcast 192.168.1.255
        inet6 fc00::1  prefixlen 64  scopeid 0x0<global>
        inet6 fe80::2d:50ff:febd:ca13  prefixlen 64  scopeid 0x20<link>
        ether 02:2d:50:bd:ca:13  txqueuelen 1000  (Ethernet)
        RX packets 91568  bytes 43903910 (41.8 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 120186  bytes 129915506 (123.8 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet6 fe80::6238:e0ff:fe0c:3b13  prefixlen 64  scopeid 0x20<link>
        ether 60:38:e0:0c:3b:13  txqueuelen 532  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 7  bytes 746 (746.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device interrupt 36

eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet6 fe80::28eb:c2ff:fe40:98e6  prefixlen 64  scopeid 0x20<link>
        ether 2a:eb:c2:40:98:e6  txqueuelen 532  (Ethernet)
        RX packets 173273  bytes 139253990 (132.8 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 139623  bytes 83938278 (80.0 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
        device interrupt 37

lan1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 02:3b:45:92:19:06  txqueuelen 1000  (Ethernet)
        RX packets 25058  bytes 5163102 (4.9 MiB)
        RX errors 0  dropped 17  overruns 0  frame 0
        TX packets 37365  bytes 37069020 (35.3 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lan2: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 02:4a:dc:6f:cd:7d  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lan3: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 02:3d:2b:d9:b5:d5  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lan4: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 02:e0:96:70:5f:c3  txqueuelen 1000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 25  bytes 1628 (1.5 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 25  bytes 1628 (1.5 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wan: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 78.61.217.195  netmask 255.255.192.0  broadcast 78.61.255.255
        inet6 fe80::6238:e0ff:fe0c:3b13  prefixlen 64  scopeid 0x20<link>
        ether 60:38:e0:0c:3b:13  txqueuelen 1000  (Ethernet)
        RX packets 148215  bytes 130278882 (124.2 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 102251  bytes 45751584 (43.6 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlp1s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 02:7a:03:6d:bb:40  txqueuelen 1000  (Ethernet)
        RX packets 66466  bytes 39665370 (37.8 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 86168  bytes 95090560 (90.6 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlp2s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether 02:b1:77:35:c7:e0  txqueuelen 1000  (Ethernet)
        RX packets 56  bytes 7498 (7.3 KiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 3336  bytes 580814 (567.2 KiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
Chadster766 commented 6 years ago

@andrius-pra one more command output please:

journalctl | grep mcdebian

andrius-pra commented 6 years ago
root@MCDEBIAN:~# journalctl | grep mcdebian
Nov 03 17:16:46 MCDEBIAN root[3435]: mcdebian: modelNumber=WRT1200AC-EU hw_revision=1
Nov 03 17:16:46 MCDEBIAN root[3445]: mcdebian: WRT3200ACM Not Detected
Chadster766 commented 6 years ago

@andrius-pra everything looks good.

Once you get the initial IP Address from the ISP does it disconnect during subsequent IP renews or are you good from then on?

andrius-pra commented 6 years ago

It works well until next reboot.

Chadster766 commented 6 years ago

@andrius-pra I wonder if you have one of those modems that starts with 192.168.x.x IP Address upon boot and then once connected to the ISP goes into bridge mode. Try adding "up sleep 30" to the wan IPv4 "/etc/network/interfaces" file.

andrius-pra commented 6 years ago

It also doesn't work with "up sleep 30". I'm using ZTE GPON ONT similar to this.

Chadster766 commented 6 years ago

@andrius-pra,

@francispereira and I were working on a AP configuration for 4.14.6. He discovered a DHCP problem on the wireless and a /etc/network/interfaces wireless config mistake for the WRT1900AC V1 which has a 3rd PCI device making it's config different that all other WRT models.

Doing a tcpdump of dhcp transmission on the br0 interface will show some devices have a hit or miss when trying to get IP Addresses on this version.

Chadster766 commented 6 years ago

I've found to many bugs and omissions in kernel 4.14.x.

Unless there are objections I will publish a downgrade for McDebian firmware and Stretch rootfs to go from beta 4.16.6 to beta 4.9.78. and it will be an upgrade for current McDebian Jessie production release.

The wireless driver and firmware will be updated to the latest mwlwifi commit.