Chadster766 / McDebian

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

McDebian 4.9.63 #43

Closed Chadster766 closed 6 years ago

Chadster766 commented 6 years ago

McDebian 4.9.63

Updates:

Firmware:

wget --user=mcdebian --password=mcdebian123 http://www.protechs-online.com/downloads/McDebian/firmwares/McDebian-Stretch-Firmwares_4.9.63.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_9_63-base.gz
Chadster766 commented 6 years ago

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.

villesinisalo commented 6 years ago

Hello! I have an 1900ACS. I was previously running 4.9.12. I tried rewriting the whole ext4 root partition from scratch with the supplied root file system and flashing McDebian-Stretch-WRT1900AC-V2-FW_VER1_kernel_4.9.63.img to bank 1 (/dev/mtd4). No luck - the router just refuses to come online to 192.168.1.1 on LAN. I tried to switch banks in case it was booting from /dev/mtd6, but I am pretty sure neither bank booted.

I then restored my root FS from backup and booted 4.9.12 from secondary bank succesfully. While at it, I upgraded through .26 to .31 per the instructions on wiki, and it worked very fine. So I am now running 4.9.31, which is great, but the beta kernel or FS does not seem to be booting on my router.

I don't have a TTL cable, but I will try to pick one up tomorrow, so hopefully I can give more info why.

Chadster766 commented 6 years ago

That would be great.

villesinisalo commented 6 years ago

Heh, good news - take that all back. I got the USB cable and it boots just fine. The reason I could not get SSH to it yesterday was probably a MAC filter in my PC blocking traffic from the router, whose MAC seems to have changed.

I now have access both via serial and SSH, and will try to setup my configuration.

Chadster766 commented 6 years ago

Awesome, keep me in the loop :smile:

villesinisalo commented 6 years ago

Got it working and successfully ported all my Jessie customizations to Stretch! 👍 But ... multicast routing is still not working 😆 I will try to debug it during the weekend - might be a user error because now the kernel is at least accepting multicast routes unlike before (#42)

Chadster766 commented 6 years ago

Thanks for the update.

Multicast routing is a tricky configuration. I've only done it in higher end Cisco IOS routers.

Normally multicast isn't an issue on bridged interfaces.

Did you do some pcaps with tshark (Wireshark) in the router?

Chadster766 commented 6 years ago

McDebian Beta 4.9.65

Updates and Fixes:

I noticed this issue and discovered that both radios were enabled for dual band which shouldn't be because the wireless circuitry is designed to only support one frequency per radio. I changed the DTS file to have the appropriate frequency per radio as per usual :smiley:

Firmware:

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

Root File System Update:

wget --user=mcdebian --password=mcdebian123 http://www.protechs-online.com/downloads/McDebian/rootfs-updates/mcdebian-stretch-rootfs-update-v4.9.65-VER1.gz

Follow standard McDebian update procedures to apply rootfs update.

villesinisalo commented 6 years ago

Thanks! 4.9.65 working fine on my WRT1900ACS with 5 GHz WiFi as before.

Nov 03 19:16:46 wrt kernel: ieee80211 phy0: fw download complete
Nov 03 19:16:46 wrt kernel: ieee80211 phy0: pcmd = dba0c000
Nov 03 19:16:46 wrt kernel: ieee80211 phy0: firmware version: 0x702091a
Nov 03 19:16:46 wrt kernel: ieee80211 phy0: firmware region code: 30
Nov 03 19:16:46 wrt kernel: ieee80211 phy0: 2G disabled, 5G enabled
Nov 03 19:16:46 wrt kernel: ieee80211 phy0: 4 TX antennas, 4 RX antennas
Nov 03 19:16:46 wrt kernel: pci 0000:00:02.0: enabling device (0140 -> 0142)
Nov 03 19:16:46 wrt kernel: ieee80211 phy1: priv->pcmd_buf = deccc000  priv->pphys_cmd_buf = 1eccc000
Nov 03 19:16:46 wrt kernel: ieee80211 phy1: fw download start
Nov 03 19:16:46 wrt kernel: ieee80211 phy1: FwSize = 118776 downloaded Size = 118776 curr_iteration 65511
Nov 03 19:16:47 wrt kernel: ieee80211 phy1: fw download complete
Nov 03 19:16:47 wrt kernel: ieee80211 phy1: pcmd = deccc000
Nov 03 19:16:47 wrt kernel: ieee80211 phy1: firmware version: 0x702091a
Nov 03 19:16:47 wrt kernel: ieee80211 phy1: firmware region code: 30
Nov 03 19:16:48 wrt kernel: ieee80211 phy1: 2G enabled, 5G disabled
Nov 03 19:16:48 wrt kernel: ieee80211 phy1: 4 TX antennas, 4 RX antenna

I tried debugging the multicast issue with tcpdump. I could see the router was receiving the multicast packets on LAN, but not forwarding them to WLAN, as they should have been per my smcroute configuration. Multicast routing does sound really tricky - I tried setting up pimd as well, but it seems to be beyond my skill level.

I prefer to have the LAN and WLAN on different bridges so I can place some more trust on LAN traffic, as WLAN is physically so much easier to breach than LAN. But I will see if I can somehow put them on same bridge and use ebtables to firewall most of the traffic form WLAN to LAN.

villesinisalo commented 6 years ago

One question from beta testing: I think this version names the individual switch ports lan1 through lan4, which is a good addition in case someone needs to configure traffic per individual port. I think they were before just one interface eth0. The wan interface is added, and used to be eth1. wlan0/1 are gone and are now wlp1/2s0. Where is this configured? I am asking because on my device ip link show prints:

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1
2: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 532
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DEFAULT group default qlen 532
4: lan4@eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue master br0 state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
5: lan3@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br0 state UP mode DEFAULT group default qlen 1000
6: lan2@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br0 state UP mode DEFAULT group default qlen 1000
7: lan1@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br0 state UP mode DEFAULT group default qlen 1000
8: wan@eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc dsmark state UP mode DEFAULT group default qlen 1000
10: wlp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br1 state UP mode DEFAULT group default qlen 1000
11: wlp2s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq master br1 state UP mode DEFAULT group default qlen 1000

I find it odd that both the wan and lanX interfaces appear under eth1 (wan@eth1, lan1@eth1)

Chadster766 commented 6 years ago

Yes with the DSA switch the eth1 is the switchport interface that the other 5 interfaces are controlled under. The great thing about this is each port can be configured with VLAN sub-interfaces with different IP Subnets, DHCP Server and firewall configurations. In my final release I will have a script with will assign random MAC Address to each LAN interface so Ethernet connected devices don't always think they are connecting to a different network because the auto generated MAC addresses change on reboot.

The wireless config files are still in the same location /etc/hostapd.

Thanks again for beta testing :smiley:

villesinisalo commented 6 years ago

Cool, but what is eth0 used for then?

Looking forward to the static MAC configs. I currectly assign the strings /dev/mtd3 | grep hw_mac_addr MAC to my LAN bridge as well to force a static MAC towards LAN.

Chadster766 commented 6 years ago

In McDebian I always set the hw_mac_addr on eth0\wan interface which eth0 still is the base interface regardless of ip link appending eth1 to the wan label.

Redferne commented 6 years ago

@villesinisalo

Do you have any magic tips on porting the old jessie customizations (rootfs) to stretch? I fear spending hours doing manual diff of the complete rootfs... 😱

Chadster766 commented 6 years ago

Once I've complete beta testing I will post my updates to the repo.

villesinisalo commented 6 years ago

@Redferne No magic tips. I just made note of the few customizations (firewall rules, services configs, apt-get packages) I had installed, and then re-applied them on the new Stretch root FS. Fs diffing sounds like an overkill - for me restoring a few configuration files from backup was enough.

Chadster766 commented 6 years ago

This beta has been superseded.

https://github.com/Chadster766/McDebian/issues/44