Chaos Computer Club Lëtzebuerg

“Chaos in the world brings uneasiness, but it also allows the opportunity for creativity and growth.” -- Tom Barret

User Tools

Site Tools


freifunk:config

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

freifunk:config [2019/12/04 21:57] (current)
fantawams created
Line 1: Line 1:
 +FIXME **This page is not fully translated, yet. Please help completing the translation.**\\ //(remove this paragraph once the translation is finished)//
 +
 +===== Freifunk Lëtzebuerg konfiguréieren =====
 +{{ :​projects:​freifunk:​freifunk-motto2k18.jpg?​400 |}}
 +<note important>​Des Säit ass nach ënner Beaarbechtung an/oder veraalt</​note>​
 +==== Basics bei der Terminal konfig ====
 +//Elei eng kleng Kuerzfaassung vun dem wichtegen, weider Detailer kënnen am [[https://​github.com/​freifunk-gluon/​gluon/​wiki/​Commandline-administration|gluon wiki]] nogesicht gin.//
 +
 +Sollt nach keen SSH Passwuert / Key hannerluecht si, kann een duerch laangt drécken vum Knäppchen ob der Récksäit vum Router derfir suergen dass den Config Mode geboot geet.
 +No dem Booten ass (wie bei der Ersteinrichtung) iwwert den Webfrontend matt der IP 192.168.1.1 erreechbar.
 +Do kann en bei Expertenastellungen e Passwuert oder den SSH Key hannerleeën.
 +
 +===== Nokucke weieng gluon Versioun installéiert ass =====
 +
 +<​code>​Gluon version (example: "​v2017.1.5"​)
 +cat /​lib/​gluon/​gluon-version
 +Build version (example: "​2016.1.5-stable-2016-06.05"​)
 +cat /​lib/​gluon/​release
 +</​code>​
 +===== Autoupdater Branch wieslen =====
 +<​code>​
 +uci set autoupdater.settings.enabled=1
 +uci set autoupdater.settings.branch=stable
 +uci commit autoupdater
 +</​code>​
 +===== Router Firmware aktualiséieren (autoupdater) =====
 +
 +<​code>​ autoupdater -f </​code>​
 +
 +===== Router Firmware aktualiséieren (manuell) =====
 +====  Wann den Node internet zougang huet ====
 +<​code>​
 +cd /tmp/
 +echo 3 > /​proc/​sys/​vm/​drop_caches
 +wget [FIRMWAREURL]
 +echo 3 > /​proc/​sys/​vm/​drop_caches
 +sysupgrade [NAMEOFFIRMWAREFILE]
 +</​code>​
 +
 +
 +==== Ouni direkten Internet Zougang -> SCP ====
 +Di passend Firmware eroflueden an vum der Lokaler Maschinn mëttels SCP ob den FFLUX AP erop lueden.
 +<​code>​
 +scp {Dateiname} root@[IPv6]:/​tmp/​
 +</​code>​
 +Duerno iwwer SSH login ob den FFLUX AP aloggen.
 +<​code>​
 +cd /tmp/
 +echo 3 > /​proc/​sys/​vm/​drop_caches
 +sysupgrade [NAMEOFFIRMWAREFILE]
 +</​code>​
 +
 +===== Am Config-Modus neistarten =====
 +<​code>​
 +uci set gluon-setup-mode.@setup_mode[0].enabled=1
 +uci commit gluon-setup-mode
 +reboot
 +</​code>​
 +
 +===== Add SSH key ==== 
 +
 +<​code>​
 +cat ~/​.ssh/​your_public_rsa_key.pub | ssh root@$ROUTER_IP 'cat >> /​etc/​dropbear/​authorized_keys'​
 +</​code>​
 +
 +===== Node Informatioun =====
 +
 +**Lokalisatiouns Parmeter**
 +
 +<​code>​
 +uci set gluon-node-info.@location[0].latitude=53.834470
 +uci set gluon-node-info.@location[0].longitude=10.702518
 +uci set gluon-node-info.@location[0].altitude=11.51
 +uci set gluon-node-info.@location[0].share_location=1
 +uci commit gluon-node-info
 +</​code>​
 +
 +**Astellungen nokucken** ​
 +<​code> ​
 +uci show gluon-node-info ​
 +
 +gluon-node-info.@location[0]=location
 +gluon-node-info.@location[0].share_location=1
 +gluon-node-info.@location[0].latitude=53.834470
 +gluon-node-info.@location[0].longitude=10.702518
 +gluon-node-info.@location[0].altitude=11.51
 +</​code>​
 +
 +===== Hostname / Nodenumm =====
 +**Hostname änneren**
 +
 +<​code>​
 +$ pretty-hostname newhostname-with-utf8-support
 +...
 +root@newhostname-with-utf8-support:​~# ​
 +</​code>​
 +
 +**Hostname nokucken**
 +
 +<​code>​
 +$ pretty-hostname
 +....
 +hostname-with-utf8-support
 +</​code>​
 +
 +===== Kontakt Donnéeën androen =====
 +<​code>​
 +uci get gluon-node-info.@owner[0] || uci add gluon-node-info owner
 +uci set gluon-node-info.@owner[0].contact=example@example.com
 +uci commit gluon-node-info
 +</​code>​
 +**Astellungen nokucken**
 +<​code>​
 +uci show gluon-node-info
 +....
 +gluon-node-info.@owner[0]=owner
 +gluon-node-info.@owner[0].contact=example@example.com
 +</​code>​
 +
 +===== Bandbreet begrenzen =====
 +<​code>​
 +uci set simple-tc.mesh_vpn.limit_egress=800 ​   # upload 0.8 Mbit/s
 +uci set simple-tc.mesh_vpn.limit_ingress=5000 ​ # download 5.0 Mbit/s
 +uci set simple-tc.mesh_vpn.enabled=1
 +uci commit simple-tc
 +/​etc/​init.d/​fastd restart
 +</​code>​
 +
 +===== Mesh on LAN =====
 +Aktivéieren ​
 +<​code>​
 +uci set network.mesh_lan.auto=1
 +for ifname in $(cat /​lib/​gluon/​core/​sysconfig/​lan_ifname);​ do
 +  uci del_list network.client.ifname=$ifname
 +done
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +Desaktivéieren ​
 +<​code>​
 +uci set network.mesh_lan.auto=0
 +for ifname in $(cat /​lib/​gluon/​core/​sysconfig/​lan_ifname);​ do
 +  uci del_list network.client.ifname=$ifname
 +done
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +
 +===== Mesh on WAN =====
 +Aktivéieren
 +<​code>​
 +uci set network.mesh_wan.disabled=0
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +Desaktivéieren
 +<​code>​
 +uci set network.mesh_wan.disabled=1
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +<note important>​
 +  - If you now connect your WAN port to your Home Router too and don't configure some additional VLAN, the whole mesh traffic will also be pushed into your local network, which might cause problems.
 +  - Be sure to have VPN disabled, otherwise this connection would build up another fastd tunnel inside the Freifunk net.
 +</​note>​
 +witch to legacy mode (without VXLAN)
 +<​code>​
 +uci set network.mesh_wan.legacy='​1'​
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +===== IBSS/Ad-Hoc Mesh (Gluon >​=2016.1.x) ====
 +=== Wann den Router nëmmen 2.4GHz oder 5GHz kann ===
 +Desaktivéieren
 +<​code>​
 +uci set wireless.ibss_radio0.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +
 +Aktivéieren
 +<​code>​
 +uci set wireless.ibss_radio0.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +
 +=== Wann den Router 2.4GHz an 5GHz kann ===
 +Desaktivéieren
 +<​code>​
 +uci set wireless.ibss_radio0.disabled=1
 +uci set wireless.ibss_radio1.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +
 +Aktivéieren
 +<​code>​
 +uci set wireless.ibss_radio0.disabled=0
 +uci set wireless.ibss_radio1.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +===== 802.11s Mesh Netzwierk =====
 +=== Wann den Router nëmmen 2.4GHz oder 5GHz kann ===
 +Desaktivéieren
 +<​code>​
 +uci set wireless.mesh_radio0.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +
 +Aktivéieren
 +<​code>​
 +uci set wireless.mesh_radio0.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +=== Wann den Router 2.4GHz an 5GHz kann ===
 +Desaktivéieren
 +<​code>​
 +uci set wireless.mesh_radio0.disabled=1
 +uci set wireless.mesh_radio1.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +
 +Aktivéieren
 +<​code>​
 +uci set wireless.mesh_radio0.disabled=0
 +uci set wireless.mesh_radio1.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +===== Mesh only Router =====
 +An verschidden Fäll ass et noudwendeg, dass den Router keng Clients akzepteiert an just dovir do ass, vir ze meshen.
 +=== Erausfannen weivill Frequenzen den Router kann ===
 +<​code>​
 +uci show wireless
 +</​code>​
 +No radio device sichen
 +=== Wann den Router nëmmen 2.4GHz oder nëmmen 5GHz kann ===
 +deactiveieren
 +<​code>​
 +uci set wireless.client_radio0.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +activeieren
 +<​code>​
 +uci set wireless.client_radio0.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +
 +=== Wann den Router 2.4GHz an 5GHz kann ===
 +deactiveieren
 +<​code>​
 +uci set wireless.client_radio0.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +<​code>​
 +uci set wireless.client_radio1.disabled=1
 +uci commit wireless
 +wifi
 +</​code>​
 +activeieren
 +<​code>​
 +uci set wireless.client_radio0.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +<​code>​
 +uci set wireless.client_radio1.disabled=0
 +uci commit wireless
 +wifi
 +</​code>​
 +===== nokucken op weiengem Port en Kabel Ugeschloss ass =====
 +<​code>​swconfig dev switch0 show | grep '​link:'</​code>​
 +
 +===== weivill clients sinn um Router verbonnen =====
 +<​code>​
 +grep -cEo "​\[.*W.*\]+"​ /​sys/​kernel/​debug/​batman_adv/​bat0/​transtable_local
 +</​code>​
 +
 +===== Offloader =====
 +Bei Offloader muss net nëmmen den Offloader agestallt ginn, mee och nach all FreiFunk node, den iwwert hien meshen soll.
 +\\
 +Um Offloader muss een den Mesh on LAN aschalten.
 +<​code>​
 +uci set network.mesh_lan.auto=1
 +for ifname in $(cat /​lib/​gluon/​core/​sysconfig/​lan_ifname);​ do
 +  uci del_list network.client.ifname=$ifname
 +done
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +
 +Un all Nodes vir dei den Offloader den VPN rechnen soll, muss een den Mesh ON WAN aschalten.
 +<​code>​
 +uci set network.mesh_wan.disabled=0
 +uci commit network
 +/​etc/​init.d/​network restart
 +</​code>​
 +===== Original Router Firmware zereck flashen =====
 +An speziellen Fäll kann et vir kommen, dass en muss déi original Router Firmware erëm zeréck flashen well oder muss.
 +
 +==== Iwwert SSH ====
 +Folgendes muss en dovir hunn:
 +  * original Router Firmware, fënnt en normalerweis um Website vum Hiersteller ​
 +  * ssh Zougang
 +  * 10 Minutten Zäit
 +
 +Vir d'​eischte den FreiFunk node booten loossen an en Uplink ginn. Iwert Kabel oder WLAN ass onrelevant.
 +Duerno testen op een ssh Zougang och huet.
 +
 +Als Beispill huelen mir elo den TP-Link WR940n V4.\\
 +Wann een elo d'​Firmware vum Hiersteller um Laptop huet, muss kontrolléiert ginn ob am Numm boot steet. \\
 +//​wr940nv4_eu_3_16_9_up_**boot**(160620).bin//​\\
 +Dat muss erausgeholl ginn, dovir gëtt folgend Kommandozeil geholl. Wann dat net dran steet, kann den nächsten Schrëtt iwwersprongen ginn.
 +<​code>​ dd if=wr940nv4_eu_3_16_9_up_boot\(160620\).bin of=wr940nv4_eu__stripped.bin skip=257 bs=512
 + </​code>​
 +Resultat ass eng nei Datei **wr940nv4_eu__stripped.bin**\\
 +
 +Des Datei kennt elo mat scp ob eisen Node.
 +<​code>​ scp {Dateiname} root@[IPv6]:/​tmp/​ </​code>​
 +
 +Elo erëm iwwert ssh um node aloggen an sech mat cd an den tmp folder setzen.
 +<​code>​ ssh root@[IPV6] </​code>​
 +<​code>​ cd /tmp/ </​code>​
 +
 +Dann muss den cache eidel gemaach ginn an d'​Software installéiert ginn.
 +<​code>​
 +echo 3 > /​proc/​sys/​vm/​drop_caches
 +sysupgrade [NAMEOFFIRMWAREFILE]
 +</​code>​
 +Dësen Schrëtt kann och am Webinterface am config-modus gemaach ginn. Dofir einfach Firmware Update maachen an dobäi eis nei erstallten original Firmware benotzen.\\
 +
 +Duerno start den Router erëm mat original Firmware.
 +
 +==== TFTP ====
 +Wann en un dësem Punkt bis ukomm ass, ass den Router gebrickt an et misst en den Router ob maachen, Kabel verleiden vir en ze retten. Mat TFTP muss et awer net esou wäit kommen. Et ass den leschten Schrëtt, éier en sech entscheeden muss tëschen Kabelen verleiden oder neien Router kafen.
 +
 +==== Logs op engem Node liesen ====
 +<​code>​
 +logread
 +</​code>​
 +
 +===== SSH Keys vun dem Team =====
 +Fir Fernwartung:​ hei lo eis Public Keys sou dass jiddereen dei beim Flashen kann hannerleeën (wann gewollt).
 +[[lb:​projects:​freifunk:​publicsshkeys|öffentliche SSH Schlüssel]]
 +
 +===== Sendeleeschtung =====
 +[[https://​github.com/​freifunk-gluon/​gluon/​wiki/​Commandline-administration#​transmit-power-on-ubiquiti-devices|Transit power zb Ubiquiti]]
 +===== MAC Adress Filter =====
 +[[https://​ffmuc.net/​wiki/​p/​Routerkonfiguration_via_SSH#​MAC_Filter]]
 +----
 +
 +Et fënnt en och vill weider Infoen am [[https://​wiki.freifunk.net/​|freifunk.net]] wiki.
  
freifunk/config.txt · Last modified: 2019/12/04 21:57 by fantawams