Zeile 1: |
Zeile 1: |
| + | ===Finanzamt klaeren=== |
| + | * 0365/639-1336 Fr.Pforr FA Gera (Verein,Schulden) |
| + | * 0365/639-1303 Fr.Kühnel bzw. Fr. Schulz (Verein,Gemeinützigkeit) |
| + | ** offensichtlich liegt kein Antrag vor ?!?! (Telefonat 2009mar02) |
| + | * 03641/378432 FA Jena / Frau Zimmermann |
| + | * Steuernummer: 162/142/08370 |
| + | |
| + | ===Literatur und formulierungshinweise=== |
| + | http://www.itespresso.de/news/netzwerke/news20061127064.aspx |
| + | |
| + | ===Monitor Rechner: Welche Bildschirmdiagonale mit welchem Hoehen/Seitenverhaeltnis hat welche Flaeche=== |
| + | <source lang="bash"> |
| + | #!/bin/sh |
| + | |
| + | func_inch2cm () |
| + | { |
| + | awk -v VAR_INCH="$1" 'BEGIN{ |
| + | print VAR_INCH*2.54 |
| + | }' |
| + | } |
| + | |
| + | func_area () |
| + | { |
| + | awk -v X=$1 -v Y=$2 'BEGIN{ |
| + | print X*Y |
| + | }' | cut -d'.' -f1 |
| + | } |
| + | |
| + | func_diag2xy () |
| + | { |
| + | local DIAG="$1" # e.g.: 22" |
| + | local RATE="$2" # e.g.: 16:10 or 4:3 |
| + | local RATE_X="${RATE%:*}" |
| + | local RATE_Y="${RATE#*:}" |
| + | |
| + | # 19² = (4x)² + (3x)² |
| + | # 19² = 16x² + 9x² |
| + | # 19² = 25x² |
| + | # 19 = 5x |
| + | # 19/5 = x |
| + | # x = 3.8 |
| + | |
| + | awk -v DIAG=$DIAG -v RATE_X=$RATE_X -v RATE_Y=$RATE_Y 'BEGIN{ |
| + | X=(DIAG/sqrt((RATE_X*RATE_X)+(RATE_Y*RATE_Y))) |
| + | print X*RATE_X":"X*RATE_Y |
| + | }' |
| + | } |
| + | |
| + | echo "<html><head><title>Monitor-Rechner</title></head><body>" |
| + | echo "<table cellspacing=2 cellpadding=2 border=1>" |
| + | echo "<tr><td> Zoll\Verhältnis </td><td align=center> 4:3 </td><td align=center> 16:9 </td><td align=center> 16:10 </td></tr>" |
| + | |
| + | for DIAG in 13 14 15 16 17 18 19 20 21 22 23 24 25 26; do { |
| + | |
| + | echo "<tr><td align=center><a title='$( func_inch2cm $DIAG ) cm'> $DIAG </a></td>" |
| + | |
| + | for RATE in "4:3" "16:9" "16:10"; do { |
| + | |
| + | XY="$( func_diag2xy $DIAG $RATE )" |
| + | X="$( func_inch2cm ${XY%:*} )" |
| + | Y="$( func_inch2cm ${XY#*:} )" |
| + | |
| + | echo "<td align=right><a title='X/Y.inch=$XY;X.cm=$X;Y.cm=$Y'> $(func_area $X $Y) cm<sup>2</a></sup></td>" |
| + | } done |
| + | |
| + | echo "</tr>" |
| + | |
| + | } done |
| + | |
| + | echo "</table></body></html>" |
| + | |
| + | </source> |
| + | |
| + | ===GIT Tutorial=== |
| + | * Grundlage: http://www.online-tutorials.net/programmierung/git/tutorials-t-3-263.html |
| + | <pre> |
| + | mkdir code |
| + | cd code |
| + | git-init # erzeugt einen .git-Ordner zur Verwaltung |
| + | vi .git/config # es sollte eine Sektion [user] mit name+email angelegt werden |
| + | # nun ein paar neue Dateien anlegen: |
| + | |
| + | wget http://weimarnetz.de/freifunk/firmware/current-tarball.tar |
| + | tar xvf current-tarball.tar |
| + | rm current-tarball.tar |
| + | |
| + | git-add . # alles fuers einchecken vormerken |
| + | git-commit -a -m "kommentar" # endgueltiges einchecken |
| + | git-log # changelog aller checkins anzeigen |
| + | git-show # Unterschied zwischen aktueller und vorletzer Version |
| + | </pre> |
| + | |
| + | ===Policy Based Routing - bestimmten IP-Bereich ueber VPN-Server ins Internet leiten=== |
| + | * Ziele: |
| + | ** das interne "Kabelnetz" soll direkt ins Internet |
| + | ** alles, was durch die Luft kommt, soll über den Rootserver in Berlin geleitet werden (WLAN-DHCP, OLSR-Nachbarn) |
| + | * Fallen: |
| + | ** das interne Netz sollte direkt erreichbar bleiben |
| + | ** interne Dienste wie olsr und dns dürfen nicht über den Rootserver geleitet werden |
| + | * auf dem Internet-Einspeiser, der per VPN mit dem Root-Server verbunden ist: |
| + | * root-server ip, ist der VPN-nachbar: |
| + | ** VPN_NEIGH="$( _ipsystem do | grep ^WIFIVPNSERVERADR= | cut -d = -f 2)" |
| + | ** die Variablen $LANNET/$LANPRE kommen vom '. /tmp/loader' (bzw. aus /tmp/NETPARAM) |
| + | ** anstatt 10.63.0.0/16 koennte man auf $WIFINET/$WIFIPRE einsetzen |
| + | <pre> |
| + | echo "50 weimarnetz_anonym" >>/etc/iproute2/rt_tables |
| + | ip rule add from 10.63.0.0/16 prio 30002 table weimarnetz_anonym |
| + | ip rule add to 10.63.0.0/16 prio 30001 lookup main |
| + | ip rule add from $LANNET/$LANPRE prio 30000 table main |
| + | ip route add default via $VPN_NEIGH dev tap0 table weimarnetz_anonym |
| + | ip route flush cache |
| + | </pre> |
| + | * Die Regel mit prio 30002 leitet alles, was aus dem IP-Bereich vom Weimarnetz über den Rootserver |
| + | * Die Regel mit prio 30001 leitet alles, was in den Bereich des Weimarnetz geht über die normale Routingtabelle |
| + | * Die Regel mit prio 30000 leitet das interne, kabelgebundene Netz über die normale Routingtabelle |
| + | * Beispiel auf Andis Router: |
| + | ** IP Rules |
| + | <pre> |
| + | root@BraeuSys:~ ip rule show |
| + | 0: from all lookup local |
| + | 32763: from all to 10.63.0.0/16 lookup main |
| + | 32764: from 10.63.52.32/27 lookup main |
| + | 32765: from 10.63.0.0/16 lookup weimarnetz_anonym |
| + | 32766: from all lookup main |
| + | 32767: from all lookup default |
| + | </pre> |
| + | ** IP Routen |
| + | <pre> |
| + | root@BraeuSys:~ ip route show table weimarnetz_anonym |
| + | default via 10.63.52.30 dev tap0 |
| + | </pre> |
| + | ** Traceroute |
| + | <pre> |
| + | root@wifimac0016b6b74c52:~ traceroute heise.de |
| + | traceroute to heise.de (193.99.144.80), 30 hops max beginning with hop 1, 40 byte packets |
| + | 1 BraeuSys.olsr (10.63.52.1) 12.563 ms 7.25 ms 3.421 ms |
| + | 2 mid7.weimarnetz.olsr (10.63.52.30) 74 ms 59.897 ms 58.993 ms |
| + | </pre> |
| + | |
| + | * auf dem Rootserver muss dann maskiert werden, damit als Quelle nicht 10.0.0.0/8 in den Paketen steht: |
| + | <pre> |
| + | iptables -t nat -I POSTROUTING -s 10.0.0.0/8 -d ! 10.0.0.0/8 -o venet0 -j SNAT --to-source 87.118.106.19 |
| + | oder einfacher |
| + | iptables -t nat -I POSTROUTING -s 10.63.0.0/16 ! -d 10.63.0.0/16 -j MASQUERADE |
| + | </pre> |
| + | |
| + | ===Router mit 8mb problemlos over-the-air flashen=== |
| + | <pre> |
| + | ssh router |
| + | |
| + | URL="http://download.berlin.freifunk.net/ipkg/_se505/openwrt-se505-freifunk-1.6.36-de.bin" |
| + | FILE="/etc/init.d/S01firmware_burn" |
| + | |
| + | wget -qO /www/fw.trx "$URL" |
| + | echo >$FILE -e "#!/bin/sh\n[ -e /www/fw.trx ] && /usr/sbin/firmware-burn /www/fw.trx" |
| + | chmod +x $FILE |
| + | reboot |
| + | </pre> |
| + | |
| + | ===RouterFehler Knoten6=== |
| + | <pre> |
| + | [ -n "$( nvram get lan_gateway )" ] && fkt_masq_internet_traffic_over_lan_device |
| + | ;; |
| + | esac |
| + | |
| + | |
| + | fkt_no_nat_for_wifi_clients |
| + | root@schubert19:~# /etc/local.fw-fff\+ masq |
| + | Jan 09 12:59:43 | [up 4421.87s 831488 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.info] check_if_this_node_offers_inet() local default-gateway found, only 4 hops away 8-) |
| + | Jan 09 12:59:43 | [up 4422.13s 942080 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) working |
| + | Jan 09 12:59:44 | [up 4422.57s 942080 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) detected alien LAN-gateway, trying to fetch DHCP-address |
| + | Jan 09 12:59:46 | [up 4424.59s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) using alienip '192.168.178.31' to reach gateway |
| + | Jan 09 12:59:46 | [up 4424.96s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) local alien-address gateway |
| + | Jan 09 12:59:46 | [up 4425.23s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) adding 192.168.178.31/24 on br0:aliennet |
| + | Jan 09 12:59:47 | [up 4425.56s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) adding default route |
| + | Jan 09 12:59:47 | [up 4425.88s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) success adding default route |
| + | Usage: /etc/init.d/S52vpn_fff+ (start|stop|restart (--force)|status) |
| + | /etc/local.fw-fff+: 36: func_packetfilter_show: not found |
| + | Jan 09 12:59:48 | [up 4426.63s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (masq_internet_traffic_over_lan_device) done |
| + | Jan 09 12:59:48 | [up 4426.96s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (fkt_no_nat_for_wifi_clients) Removing rules |
| + | iptables: No chain/target/match by that name |
| + | Jan 09 12:59:48 | [up 4427.26s 925696 bytes free] TERM:xterm /etc/local.fw-fff+ [daemon.debug] localfw_log() (fkt_nat_for_roaming_wifi_clients) Installing masquerading |
| + | root@schubert19:~# ip r |
| + | |
| + | |
| + | Jan 9 12:07:51 | daemon.info fff+ TERM:vt102 /etc/init.d/S52vpn_fff+ check_if_this_node_offers_inet(): local default-gateway found, only 4 hops away 8-) |
| + | Jan 9 12:07:53 | daemon.debug fff+ TERM:vt102 /etc/init.d/S52vpn_fff+ func_vpn_start(): no local default gateway - abort |
| + | |
| + | root@schubert19:~# fkt_check_if_this_node_offers_inet |
| + | Jan 09 13:03:27 | [up 4646.21s 1314816 bytes free] TERM:xterm -ash [daemon.debug] check_if_this_node_offers_inet() PHYDEV: 'br0' METRIC: '' N: '' D: '192.168.178.1' |
| + | Jan 09 13:03:28 | [up 4646.93s 1282048 bytes free] TERM:xterm -ash [daemon.info] check_if_this_node_offers_inet() found local default-gateway over device 'br0' = 'lan' |
| + | lan |
| + | |
| + | </pre> |
| + | |
| + | ===Uptime-Statistik-Netzweit=== |
| + | [[Fries43-Sandkasten]] |
| + | |
| + | ==Grillparty auf Balkon vorbereiten== |
| + | # Getränke aus eigener Kasse bezahlen |
| + | # Wurst bringt Herr Bittorf mit |
| + | # Cocktails vorbereiten |
| + | # GoGo-Girls leasen |
| + | |
| + | ===Stoffsammlung openWRT: hacking new devices=== |
| + | |
| + | ==== Level1 / LevelOne / WAP-3101 ==== |
| + | * http://global.level1.com/product_d.php?id=683 |
| + | * http://www.level1.tw/level1/datasheet/WAP-3101_SPEC_V1.0.pdf |
| + | * Ceiling Mount Wireless Access Point |
| + | * PoE 802.3af |
| + | * 108 Mbps |
| + | * pictures: http://intercity-vpn.de/files/level1-wap-3101/ |
| + | |
| + | <pre> |
| + | bastian@bastian-laptop:~/levelone-wap-3101$ hexdump -C "WAP-3101(1.0.30(ETSI))_2009-1-21.img" | head -n4 |
| + | 00000000 41 50 35 31 2d 33 36 36 30 0a 19 85 20 03 00 00 |AP51-3660... ...| |
| + | 00000010 00 0c f0 60 dc 98 19 85 e0 01 00 00 00 2b 3e 42 |...`.........+>B| |
| + | 00000020 24 27 00 00 00 01 00 00 00 00 00 00 00 02 49 70 |$'............Ip| |
| + | 00000030 09 4b 03 04 00 00 69 30 e7 7c 55 66 83 ff 62 69 |.K....i0.|Uf..bi| |
| + | |
| + | bastian@bastian-laptop:~/levelone-wap-3101$ ls -l "WAP-3101(1.0.30(ETSI))_2009-1-21.img" |
| + | -rw-r--r-- 1 bastian bastian 3670026 2009-01-16 13:16 WAP-3101(1.0.30(ETSI))_2009-1-21.img |
| + | |
| + | root@Buero-bittorfBUFFI-MESH:~ _net mac2vendor 00:11:6B:EA:0E:E5 |
| + | May 07 11:25:47 ' [up 173345s 2220032 bytes free] TERM:xterm -ash [daemon.debug] net_mac2vendor() not cached yet, working for '00:11:6B:EA:0E:E5' |
| + | May 07 11:25:48 ' [up 173346s 2220032 bytes free] TERM:xterm -ash [daemon.debug] net_mac2vendor() sanitized '00:11:6B:EA:0E:E5' to '00116b' |
| + | Digital Data Communications Asia Co.,Ltd |
| + | 8F,No.41,Lane 221,Kang-Chien RD.,Nei-Hu Dis., |
| + | Taipei City 114 |
| + | TAIWAN, REPUBLIC OF CHINA |
| + | </pre> |
| + | |
| + | <pre> |
| + | # ls -l /lib/ |
| + | lrwxrwxrwx 1 0 0 19 libc.so.0 -> libuClibc-0.9.26.so |
| + | -rw-r--r-- 1 0 0 7684 libdl.so.0 |
| + | lrwxrwxrwx 1 0 0 18 libcrypt.so.0 -> libcrypt-0.9.26.so |
| + | -rwxr-xr-x 1 0 0 148892 libnetsnmphelpers.so.10 |
| + | -rw-r--r-- 1 0 0 296356 libuClibc-0.9.26.so |
| + | drwxr-xr-x 1 0 0 0 modules |
| + | lrwxrwxrwx 1 0 0 19 ld-uClibc.so.0 -> ld-uClibc-0.9.26.so |
| + | -rw-r--r-- 1 0 0 2184 libnsl.so.0 |
| + | -rwxr-xr-x 1 0 0 28829 libiw.so.26 |
| + | -rwxr-xr-x 1 0 0 514376 libnetsnmp.so.10 |
| + | -rw-r--r-- 1 0 0 100775 libpthread.so.0 |
| + | -rwxr-xr-x 1 0 0 159852 libnetsnmpagent.so.10 |
| + | -rwxr-xr-x 1 0 0 416172 libnetsnmpmibs.so.10 |
| + | -rw-r--r-- 1 0 0 13320 libcrypt-0.9.26.so |
| + | -rwxr-xr-x 1 0 0 20760 ld-uClibc-0.9.26.so |
| + | -rw-r--r-- 1 0 0 29988 libm.so.0 |
| + | # ls -l /bin |
| + | -rwxr-xr-x 1 0 0 505748 busybox |
| + | -rwxr-xr-x 1 0 0 13488 radartool |
| + | -rwxr-xr-x 1 0 0 13680 athstats |
| + | -rwxr-xr-x 1 0 0 9612 athdebug |
| + | lrwxrwxrwx 1 0 0 7 umount -> busybox |
| + | -rwxr-xr-x 1 0 0 17596 wlanstats |
| + | -rwxr-xr-x 1 0 0 9628 wlandebug |
| + | -rwxr-xr-x 1 0 0 17596 80211stats |
| + | -rwxr-xr-x 1 0 0 9628 80211debug |
| + | lrwxrwxrwx 1 0 0 7 uname -> busybox |
| + | lrwxrwxrwx 1 0 0 7 sleep -> busybox |
| + | lrwxrwxrwx 1 0 0 7 rmdir -> busybox |
| + | lrwxrwxrwx 1 0 0 7 mount -> busybox |
| + | lrwxrwxrwx 1 0 0 7 mknod -> busybox |
| + | lrwxrwxrwx 1 0 0 7 mkdir -> busybox |
| + | lrwxrwxrwx 1 0 0 7 login -> busybox |
| + | lrwxrwxrwx 1 0 0 7 fgrep -> busybox |
| + | lrwxrwxrwx 1 0 0 7 egrep -> busybox |
| + | lrwxrwxrwx 1 0 0 7 dmesg -> busybox |
| + | lrwxrwxrwx 1 0 0 7 chmod -> busybox |
| + | -rwxr-xr-x 1 0 0 21808 wlanconfig |
| + | lrwxrwxrwx 1 0 0 7 ping -> busybox |
| + | lrwxrwxrwx 1 0 0 7 kill -> busybox |
| + | lrwxrwxrwx 1 0 0 7 grep -> busybox |
| + | lrwxrwxrwx 1 0 0 7 echo -> busybox |
| + | lrwxrwxrwx 1 0 0 7 date -> busybox |
| + | lrwxrwxrwx 1 0 0 7 sed -> busybox |
| + | lrwxrwxrwx 1 0 0 7 pwd -> busybox |
| + | lrwxrwxrwx 1 0 0 7 cat -> busybox |
| + | lrwxrwxrwx 1 0 0 7 ash -> busybox |
| + | lrwxrwxrwx 1 0 0 7 vi -> busybox |
| + | lrwxrwxrwx 1 0 0 7 sh -> busybox |
| + | lrwxrwxrwx 1 0 0 7 rm -> busybox |
| + | lrwxrwxrwx 1 0 0 7 ps -> busybox |
| + | lrwxrwxrwx 1 0 0 7 mv -> busybox |
| + | lrwxrwxrwx 1 0 0 7 ls -> busybox |
| + | lrwxrwxrwx 1 0 0 7 ln -> busybox |
| + | lrwxrwxrwx 1 0 0 7 df -> busybox |
| + | lrwxrwxrwx 1 0 0 7 cp -> busybox |
| + | # ls -l /sbin |
| + | lrwxrwxrwx 1 0 0 14 udhcpc -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 reboot -> ../bin/busybox |
| + | -rwxr-xr-x 1 0 0 13600 iwpriv |
| + | -rwxr-xr-x 1 0 0 22000 iwlist |
| + | lrwxrwxrwx 1 0 0 14 insmod -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 logread -> ../bin/busybox |
| + | -rwxr-xr-x 1 0 0 25888 iwconfig |
| + | lrwxrwxrwx 1 0 0 14 vconfig -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 ifconfig -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 watchdog -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 syslogd -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 modprobe -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 route -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 rmmod -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 lsmod -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 klogd -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 brctl -> ../bin/busybox |
| + | lrwxrwxrwx 1 0 0 14 init -> ../bin/busybox |
| + | # ls -l /usr/sbin/ |
| + | -rwxr-xr-x 1 0 0 14236 snmptrap |
| + | -rwxr-xr-x 1 0 0 23 cfg_set |
| + | -rwxr-xr-x 1 0 0 34792 cfg_mgr |
| + | -rwxr-xr-x 1 0 0 18 cfg_get |
| + | -rwxr-xr-x 1 0 0 27 cfg_fac |
| + | -rwxr-xr-x 1 0 0 348157 wpa_supplicant |
| + | -rwxr-xr-x 1 0 0 16768 mysniffer |
| + | -rwxr-xr-x 1 0 0 16880 peerstat |
| + | lrwxrwxrwx 1 0 0 17 udhcpd -> ../../bin/busybox |
| + | -rwxr-xr-x 1 0 0 24636 mbssid |
| + | lrwxrwxrwx 1 0 0 17 chroot -> ../../bin/busybox |
| + | -rwxr-xr-x 1 0 0 18932 locator |
| + | -rwxr-xr-x 1 0 0 10168 htpasswd |
| + | -rwxr-xr-x 1 0 0 14552 cfg_test |
| + | -rwxr-xr-x 1 0 0 14 cfg_save |
| + | -rwxr-xr-x 1 0 0 26624 ntpclient |
| + | -rwxr-xr-x 1 0 0 70176 mini_httpd |
| + | -rwxr-xr-x 1 0 0 265168 hostapd |
| + | -rwxr-xr-x 1 0 0 13688 stacserv |
| + | lrwxrwxrwx 1 0 0 17 telnetd -> ../../bin/busybox |
| + | -rwxr-xr-x 1 0 0 26760 snmpd |
| + | lrwxrwxrwx 1 0 0 17 crond -> ../../bin/busybox |
| + | -rwxr-xr-x 1 0 0 26263 wpp |
| + | -rwxr-xr-x 1 0 0 78412 rc |
| + | |
| + | # mini_httpd --help |
| + | HAVE_SENDFILE |
| + | HAVE_LINUX_SENDFILE |
| + | usage: mini_httpd [-C configfile] [-D] [-p port] [-d dir] [-dd data_dir] [-c cgipat] [-u user] [-h hostname] [-r] [-v] [-l logfile] [-i pidfile] [-T charset] [-P P3P] [-M maxage] |
| + | |
| + | </pre> |
| + | |
| + | |
| + | <pre> |
| + | root@Buero-bittorfBUFFI-MESH:~ telnet 192.168.1.1 |
| + | |
| + | Entering character mode |
| + | Escape character is '^]'. |
| + | |
| + | |
| + | (none) login: admin |
| + | Password: |
| + | |
| + | |
| + | BusyBox v1.00-pre10 (2009.01.16-02:32+0000) Built-in shell (ash) |
| + | Enter 'help' for a list of built-in commands. |
| + | |
| + | # help |
| + | |
| + | Built-in commands: |
| + | ------------------- |
| + | . : alias bg break cd chdir continue eval exec exit export false |
| + | fg getopts hash help jobs kill let local pwd read readonly return |
| + | set shift times trap true type ulimit umask unalias unset wait |
| + | |
| + | |
| + | # cat /proc/meminfo |
| + | total: used: free: shared: buffers: cached: |
| + | Mem: 14815232 10428416 4386816 0 0 5554176 |
| + | Swap: 0 0 0 |
| + | MemTotal: 14468 kB |
| + | MemFree: 4284 kB |
| + | MemShared: 0 kB |
| + | Buffers: 0 kB |
| + | Cached: 5424 kB |
| + | SwapCached: 0 kB |
| + | Active: 1936 kB |
| + | Inactive: 4700 kB |
| + | HighTotal: 0 kB |
| + | HighFree: 0 kB |
| + | LowTotal: 14468 kB |
| + | LowFree: 4284 kB |
| + | SwapTotal: 0 kB |
| + | SwapFree: 0 kB |
| + | # cat /proc/cpuinfo |
| + | system type : Atheros AR531X_COBRA |
| + | processor : 0 |
| + | cpu model : unknown V6.4 |
| + | BogoMIPS : 183.50 |
| + | wait instruction : no |
| + | microsecond timers : yes |
| + | tlb_entries : 16 |
| + | extra interrupt vector : yes |
| + | hardware watchpoint : no |
| + | VCED exceptions : not available |
| + | VCEI exceptions : not available |
| + | # cat /proc/mtd |
| + | dev: size erasesize name |
| + | mtd0: 00400000 00010000 "spiflash" |
| + | mtd1: 00030000 00010000 "RedBoot" |
| + | mtd2: 002f0000 00010000 "rootfs" |
| + | mtd3: 000a0000 00010000 "vmlinux.bin.l7" |
| + | mtd4: 00020000 00010000 "cfg" |
| + | mtd5: 0000f000 00010000 "FIS directory" |
| + | mtd6: 00001000 00010000 "RedBoot config" |
| + | # cat /proc/version |
| + | Linux version 2.4.25-LSDK-5.3.1.46 (root@localhost.localdomain) (gcc version 3.3.3) #1 Fri Jan 16 10:26:45 CST 2009 |
| + | # cat /proc/bus/ |
| + | # ls -l /proc/bus |
| + | # dmesg |
| + | # ifconfig |
| + | ath1 Link encap:Ethernet HWaddr 00:11:6B:EA:0E:E5 |
| + | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| + | RX packets:1541 errors:0 dropped:0 overruns:0 frame:0 |
| + | TX packets:1696 errors:0 dropped:0 overruns:0 carrier:0 |
| + | collisions:0 txqueuelen:0 |
| + | RX bytes:996666 (973.3 KiB) TX bytes:375866 (367.0 KiB) |
| + | |
| + | br0 Link encap:Ethernet HWaddr 00:11:6B:EA:0E:E5 |
| + | inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0 |
| + | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| + | RX packets:2234 errors:0 dropped:0 overruns:0 frame:0 |
| + | TX packets:1165 errors:0 dropped:0 overruns:0 carrier:0 |
| + | collisions:0 txqueuelen:0 |
| + | RX bytes:328866 (321.1 KiB) TX bytes:205144 (200.3 KiB) |
| + | |
| + | eth0 Link encap:Ethernet HWaddr 00:11:6B:EA:0E:E5 |
| + | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| + | RX packets:1864 errors:0 dropped:0 overruns:0 frame:0 |
| + | TX packets:1377 errors:0 dropped:0 overruns:0 carrier:0 |
| + | collisions:0 txqueuelen:1000 |
| + | RX bytes:332884 (325.0 KiB) TX bytes:0 (0.0 B) |
| + | |
| + | lo Link encap:Local Loopback |
| + | inet addr:127.0.0.1 Mask:255.0.0.0 |
| + | UP LOOPBACK RUNNING MTU:16436 Metric:1 |
| + | RX packets:2335 errors:0 dropped:0 overruns:0 frame:0 |
| + | TX packets:2335 errors:0 dropped:0 overruns:0 carrier:0 |
| + | collisions:0 txqueuelen:0 |
| + | RX bytes:129889 (126.8 KiB) TX bytes:129889 (126.8 KiB) |
| + | |
| + | wifi0 Link encap:Ethernet HWaddr 00:11:6B:EA:0E:E5 |
| + | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| + | RX packets:1672 errors:0 dropped:0 overruns:0 frame:6438 |
| + | TX packets:1768 errors:22 dropped:0 overruns:0 carrier:0 |
| + | collisions:0 txqueuelen:199 |
| + | RX bytes:1037899 (1013.5 KiB) TX bytes:419223 (409.3 KiB) |
| + | Interrupt:3 Memory:b0000000-b00ffffc |
| + | </pre> |
| + | |
| + | ====Vendor / Model==== |
| + | ** one product, different vendors, different housings |
| + | ** Lucent Technologies / Agere Systems Orinoco "Residential Gateway" Model RG-1000 |
| + | ** Apple Airport Base Station = Graphite Airport Base Station |
| + | ** HP 802.11b Wireless LAN Small Business Access Point = HP HP-P1981A |
| + | ** Compaq WL310 AP |
| + | ** Dell Truemobile 1150 "RG 1000" |
| + | ** AP-500, AP-1000 |
| + | ** Avaya wireless RG-1 |
| + | |
| + | ====known IP's / factory defaults==== |
| + | |
| + | * 10.0.1.1/24 |
| + | * 10.0.0.1/24 |
| + | * 192.42.249.13/24 |
| + | * 153.69.254.254/24 |
| + | * 192.168.1.1/24 |
| + | |
| + | ====Chips==== |
| + | ** AMD: Elan SC400-33AC Embedded x86 Processor / 96170 |
| + | ** ETHERNET, 10 mbit: 10baseT AMD PCnet ISA II (AM 79C961 AKC) ISA bridge (http://cateee.net/lkddb/web-lkddb/LANCE.html) |
| + | ** RAM: 4096 KB |
| + | *** 2 x VG26V18165CJ SAO46U - 6 |
| + | *** 1,048,576 x 16 - Bit CMOS Dynamic RAM |
| + | *** Vanguard International Semiconductor |
| + | ** FLASH: 512 kb |
| + | *** 2 x IS61C256AH - 15J ; Q140561P 9942 |
| + | *** 32,768 word by 8-bit static RAM |
| + | ** MODEM: ? [http://xmodem.org/chipsets/conexant/conexant_rc56d.html | Conexant rc56d] |
| + | ** ISDN: Hermstedt Mr.Happy v1.3 |
| + | ** miniPCI-Steckplatz: shipped with "Orinoco Silver" |
| + | ** Power: 9 Volt DC @ 1100 mA |
| + | |
| + | ====Keywords on PCB==== |
| + | ** HomePOINT EVT 5.0 |
| + | ** RG-1000 V 3.65 |
| + | ** ISDN-PCB: Motorola Coldfire MCF5204PU25B |
| + | |
| + | ====Keywords in Firmware==== |
| + | ** <tt>tr -dc '[:print:]' <fw.bin</tt> |
| + | ** Copyright 1991 thru 2000 by Doug Karl and The Ohio State University |
| + | ** KarlBridge V3.79 Copyright 1991 thru 2000 KarlNet, Inc. |
| + | ** Apple Network [...] Base Station V3.79 SN-xxxxxxxxxxxxxxxxxxxxxxxx |
| + | |
| + | ====Links==== |
| + | ** http://www.youtube.com/watch?v=aUVuWmcO6Bo (Interview in TV with Doug Karl) |
| + | ** http://www.murgatroid.com/rg1000/rg1000.htm |
| + | ** http://www.icir.org/fenner/airport/ |
| + | ** http://vilos.com/rg1000/ |
| + | ** http://gicl.cs.drexel.edu/people/sevy/airport/ |
| + | ** http://www.e-bulles.be/bubble/RC-1000 |
| + | ** http://bulles.topgame.be/bubble/Rg_Install |
| + | ** http://seattlewireless.net/moin.cgi/OrinocoRg1000 |
| + | ** http://ftp.escom.bg/Linux/wireless/rg1000/ |
| + | ** http://www.seattlewireless.net/index.cgi/AirportLinux |
| + | ** http://www.mspin.net/~jjhuff/airport_linux/ |
| + | ** http://www.ambrisko.com/doug/airport/ |
| + | ** http://www.mail-archive.com/ltsp-discuss@lists.sourceforge.net/msg01536.html |
| + | ** http://www.plasma-online.de/english/upgrade/tweak/fixes/fix_apple_airport.html |
| + | ** http://www.slac.stanford.edu/~strauman/pers/airport/ |
| + | |
| + | ===Freie Seiten? / Trafficmessung inklusive=== |
| + | |
| + | * mal schauen, wieviel datenverkehr da so drueber geht?! |
| + | |
| + | <pre> |
| + | ebay.de |
| + | google.de |
| + | google.com |
| + | gmx.de |
| + | de.wikipedia.org |
| + | web.de |
| + | yahoo.de |
| + | yahoo.com |
| + | weimarnetz.de |
| + | youtube.com |
| + | myspace |
| + | studivz |
| + | xing.com |
| + | youporn |
| + | </pre> |
| + | |
| + | ===Viele Dateien mit convert bearbeiten=== |
| + | <pre> |
| + | find /bilder/verzeichnis -type f >/tmp/filelist.txt |
| + | awk '{print "File: \""$0"\"";system("convert -rotate \"+180\" \""$0"\" ps:jpg")}' /tmp/filelist.txt |
| + | |
| + | oder (geht nicht!) |
| + | |
| + | awk '{print "File: \""$0"\"";system("convert -rotate \"+180\" ps:jpg \""$0"\"")}' /tmp/filelist.txt |
| + | </pre> |
| + | |
| + | ===Ablage=== |
| + | *[[Code-Schnipsel_POST-Daten_mit_netcat]] |
| + | *[[Code-Schnipsel_QUERY_STRING_eval_fff]] |
| + | *[[Code-Schnipsel_Layer7]] |
| + | *[[Firmwareentwicklung-Experimente]] |
| + | *[[SvenOlaTuecke-Mail2007jul18-dyngw_und_cron.minutely_iproute2]] |
| + | *[[SvenOlaTuecke-Mail2007aug12-mrate_und_rate_problem]] |
| + | *[[SvenOlaTuecke-Mail2007aug13-probe-request_und_wldog]] |
| + | *[[Sidd_aka_svenno_Mail2007aug15-tshirts_02caffeebabe]] |
| + | *[[SvenOlaTuecke-Mail2007sep12-sendeleistung,einheiten,wl,wifi,broadcom]] |
| + | |
| + | ===Flickr=== |
| + | * Elektra: http://www.flickr.com/photos/rportrr/243944335/sizes/o/ |
| + | * Kloschi, Alexander Klosch, Paidros: http://www.flickr.com/photos/rportrr/243230308/sizes/o/ |
| + | * Kloschi, Cven: http://www.flickr.com/photos/rportrr/243229300/sizes/o/ |
| + | * Kloschi, abgefrackt: http://www.flickr.com/photos/rportrr/243944300/sizes/o/ |
| + | * Bastian, WCW 2006, Berlin, C-Base: http://www.flickr.com/photos/73737099@N00/117250898/sizes/o/ |
| + | * Offline Horst, Horst Krause, Berlin WCW 2006: http://www.flickr.com/photos/73737099@N00/117251075/sizes/o/ |
| + | * Freifunk-Ufo, Leipzig: http://www.flickr.com/photos/8479197@N05/518554165/sizes/o/ |
| + | * Kloschi mit lauter staunenden Leuten: http://www.flickr.com/photos/tlauriau/292505965/sizes/o/ |
| + | * Cven mit lauter staunenden Kindern: http://www.flickr.com/photos/tlauriau/292511284/sizes/o/ |
| + | |
| + | ===Kot-Ablage=== |
| + | <pre> |
| + | root@ex_eow:/etc/init.d# /usr/sbin/wl -i eth2 status |
| + | |
| + | SSID: "weimar.freifunk.net" |
| + | Mode: Ad Hoc RSSI: -61 dBm noise: -97 dBm Channel: 5 |
| + | BSSID: 02:CA:FF:EE:BA:BE Capability: None |
| + | Supported Rates: [ 1(b) 2(b) 5.5(b) 6 9 11(b) 12 18 24 36 48 54 ] |
| + | |
| + | root@ex_eow:/etc/init.d# /usr/sbin/wl -i eth2 status | sed 's/: /=/g' | sed 's/=/=\"/g' | sed 's/\"\"/\"/g' | sed 's/$/\"/g' | sed 's/ \"/\"/g' |
| + | |
| + | SSID="weimar.freifunk.net"" |
| + | Mode="Ad Hoc RSSI="-63 dBm noise="-97 dBm Channel="5" |
| + | BSSID="02:CA:FF:EE:BA:BE Capability="None" |
| + | Supported Rates="[ 1(b) 2(b) 5.5(b) 6 9 11(b) 12 18 24 36 48 54 ]" |
| + | |
| + | Fehlt noch: |
| + | * alle Vorkommen von '[[:space:]]Buchstaben' durch '"Buchstaben' ersetzen |
| + | * alle Vorkommen von 1 oder mehreren Leerzeichen + " durch " ersetzen |
| + | </pre> |
| + | |
| + | ===Kot-Ablage2=== |
| + | <pre> |
| + | ALLE Router listen lassen |
| + | wget -O - http://127.0.0.1:2006 | sed -e '/./{H;$!d;}' -e 'x;/Table: Routes/!d;' | grep HOST | grep -v \.254 | grep -v \.253 | awk '{print $1}' | sort -n |
| + | </pre> |
| + | |
| + | <pre> |
| + | pppoecd-Einwahl: |
| + | |
| + | eval $(netparam);USER="$(nvram get pppoe_username)";PASS="$(nvram get pppoe_passwd)" |
| + | pppoecd $WANDEV -u $USER -p $PASS |
| + | </pre> |
| + | |
| + | ===Kot-Ablage3=== |
| + | * [[poormens_desktop_search_engine.sh]] |
| + | |
| + | ===Kot-Ablage4=== |
| + | * Netzknotennummer mit alter Firmware, emails zusammensammeln |
| + | <pre> |
| + | LIST="$(wget -O - http://127.0.0.1:2006 | grep 255\.255\.255\.240 | awk -F. '{print $3}' | sort | uniq)" |
| + | for NN in $LIST; do wget -O - http://10.63.$NN.1/cgi-bin-contact.html | awk '/E-Mail:/ {print}';done |
| + | </pre> |
| + | |
| + | ===Kot-Ablage5=== |
| + | * alle aktiven Router zaehlen: |
| + | <pre> |
| + | wget -O - http://127.0.0.1:2006 | sed -e '/./{H;$!d;}' -e 'x;/Table: Routes/!d;' | grep "/32" | grep -v ".254/32" | grep -v ".253/32" | grep -v ".33/32" | grep -v ".97/32" | sort | wc -l |
| + | # |
| + | </pre> |
| + | |
| + | =Bulle Mario in Weimar= |
| + | * [[Mario Bueckert und Mario Bueckert als Bulle bzw. Kuh Bueckert|Bulle Mario Bueckert]] |
| + | |
| + | ===IPK-Kompatible Paketliste auf dem Root-Server erzeugen lassen=== |
| + | |
| + | <pre> |
| + | OUT="Packages"; >$OUT; for FILE in $(ls -1 *.ipk); do echo -en "$FILE: "; tar xzf "$FILE" ./control.tar.gz; tar xzf control.tar.gz ./control; cat >>$OUT control; stat --printf "Size: %s\nFilename: %n\n\n" $FILE >>$OUT; rm -f control control.tar.gz; echo "ok"; done |
| + | </pre> |
| + | |
| + | ===Fachbücher bestellen=== |
| + | * [http://www.buchhandlung-rockenstein.de Fachliteratur (O'Reilly etc) online bestellen im Buchgeschäft Schleusingen] |
| + | * [http://www.buchhandlung-schleusingen.de Kinderbücher bestellen im Buchgeschäft Rockenstein] |
| + | * Suchmaschinenfänger 8-) |
| + | |
| + | ===Eigenes IPK automatisch erzeugen lassen=== |
| + | <pre> |
| + | #!/bin/sh |
| + | |
| + | URL="http://pgl.yoyo.org/as/serverlist.php?showintro=0;hostformat=hosts" |
| + | IPKG_NAME="fff-adblock-list" |
| + | IPKG_VERSION="0.1.0" |
| + | IPKG_CPU="mipsel" |
| + | |
| + | echo "2.0" >"debian-binary" |
| + | |
| + | cat >control <<EOF |
| + | Package: $IPKG_NAME |
| + | Priority: optional |
| + | Version: $IPKG_VERSION |
| + | Architecture: $IPKG_CPU |
| + | Maintainer: Bastian Bittorf <bittorf@bluebottle.com> |
| + | Depends: iptables-mod-filter |
| + | Section: networking |
| + | Description: installs actual adblock-hosts-list (build: $(date +%Y_%m_%d)) |
| + | Source: $URL |
| + | EOF |
| + | |
| + | tar cvzf control.tar.gz ./control |
| + | |
| + | mkdir tmp |
| + | wget -qO - "$URL" | sed -n '/127\.0\.0\.1/p' | sed 's/127\.0\.0\.1 //' >tmp/hosts.drop |
| + | tar cvzf data.tar.gz tmp/ |
| + | |
| + | tar cvzf ${IPKG_NAME}_${IPKG_VERSION}_${IPKG_CPU}.ipk ./debian-binary ./control.tar.gz ./data.tar.gz |
| + | |
| + | rm -fR tmp/ |
| + | rm data.tar.gz |
| + | rm control |
| + | rm control.tar.gz |
| + | rm debian-binary |
| + | |
| + | </pre> |
| + | |
| + | ===get_mac_from_random_node.sh=== |
| + | <pre> |
| + | #!/bin/sh |
| + | |
| + | fkt_prepare () { |
| + | FFF_NET=10 |
| + | FFF_CITY=63 |
| + | |
| + | STATUS_PAGE="/tmp/temp_status_page.txt" |
| + | } |
| + | |
| + | fkt_calc_node_from_ip () { # SENS: calculate nodenumber from IP-address |
| + | # ARG1: ip-address |
| + | local IP="$1" |
| + | local OKT3="$(echo $IP | sed 's/[0-9]*\.[0-9]*\.\([0-9]*\)\.[0-9]*/\1/g')" |
| + | local OKT4="$(echo $IP | sed 's/[0-9]*\.[0-9]*\.[0-9]*\.\([0-9]*\)/\1/g')" |
| + | |
| + | if [ -z "$(echo $IP | sed "/^$FFF_NET\.$FFF_CITY\./!d")" ]; then # ip is not from mesh e.g. 192.168.1.2 |
| + | echo "0" |
| + | return |
| + | fi |
| + | |
| + | if [ "$OKT4" -gt "-1" ] && [ "$OKT4" -lt "64" ]; then echo $OKT3 |
| + | elif [ "$OKT4" -gt "63" ] && [ "$OKT4" -lt "128" ]; then echo $(( $OKT3 + 255)) |
| + | elif [ "$OKT4" -gt "127" ] && [ "$OKT4" -lt "192" ]; then echo $(( $OKT3 + 510)) |
| + | elif [ "$OKT4" -gt "191" ] && [ "$OKT4" -lt "256" ]; then echo $(( $OKT3 + 765)) |
| + | fi |
| + | } |
| + | |
| + | fkt_wget () { |
| + | local C=0 # counter (raising) for maximal seconds |
| + | local MAX=15 # maximal running time in seconds |
| + | local URL="$1" |
| + | local PID_WGET="" |
| + | local PID_LINE="" |
| + | local PID_LINE_NOW="" |
| + | |
| + | wget -qO - "$URL" 2>/dev/null & |
| + | PID_WGET="$(pidof wget | sed 's/ /\n/g' | sed '$!d')" # list of all wget-pid's, insert newlines, print last line |
| + | PID_LINE="$(cat /proc/$PID_WGET/cmdline 2>/dev/null)" # exact line of ps-output |
| + | |
| + | while [ -e "/proc/$PID_WGET" ]; do # wget-process in tasklist? |
| + | sleep 1 |
| + | let C+=1 |
| + | |
| + | PID_LINE_NOW="$(cat /proc/$PID_WGET/cmdline 2>/dev/null)" |
| + | |
| + | if [ $C -gt $MAX ]; then # maximal execution time reached |
| + | if [ "$PID_LINE" = "$PID_LINE_NOW" ] ; then # is this really the started process? |
| + | |
| + | logger "wgetting \"$URL\" - killing pid $PID_WGET after $C seconds" |
| + | kill $PID_WGET 2>/dev/null >/dev/null |
| + | return |
| + | else # this is another process |
| + | logger "wgetting \"$URL\" - ready after $C seconds (\"$PID_LINE"\" != \"$PID_LINE_NOW"\")" |
| + | return |
| + | fi |
| + | fi |
| + | done |
| + | |
| + | logger "wgetting \"$URL\" - ready after $C seconds" |
| + | } |
| + | |
| + | fkt_get_random_node () { |
| + | local OLSR_INFO="wget -qO - http://127.0.0.1:2006" |
| + | local OLSR_TOPO="sed -e '/./{H;$!d;}' -e 'x;/Table: Topology/!d;'" |
| + | local OLSR_NODE="sed -e '/^[0-9]/!d' -e 's/^\([0-9.]*\) *.*/\1/g'" |
| + | |
| + | local ALL_NODES="$( $OLSR_INFO | sed -e '/./{H;$!d;}' -e 'x;/Table: Topology/!d;' | sed -e '/^[0-9]/!d' -e 's/^\([0-9.]*\) *.*/\1\n/g' | sort | uniq )" |
| + | local COUNT_ALL="$( echo -en "$ALL_NODES" | wc -l )" |
| + | |
| + | local RAND_SEED="$( dd if=/dev/urandom bs=2 count=1 2>&- | hexdump | if read line; then echo 0x${line#* }; fi )" |
| + | local RAND_NUMB="$(( $RAND_SEED % $COUNT_ALL ))" |
| + | |
| + | RAND_NODE="$( echo -en "$ALL_NODES" | sed "${RAND_NUMB}q;d" )" # IP-address from random node |
| + | RAND_NODE_ESCAPED="$( echo "$RAND_NODE" | sed 's/\./\\./g' )" |
| + | |
| + | test -z "$RAND_NODE" && fkt_get_random_node # maybe not necessary |
| + | } |
| + | |
| + | fkt_get_status () { |
| + | fkt_wget "http://$IP/cgi-bin-status.html" >$STATUS_PAGE 2>/dev/null |
| + | |
| + | local MAC="$(sed -e '/^MAC/!d' -e 's/^MAC: \(.*\)<\/TD>/\1/g' $STATUS_PAGE)" |
| + | local TYP="$(sed -e '/^<TD>Boardtype:/!d' -e 's/^<TD>Boardtype: \(.*\), Boardnum: \(.*\)<\/TD>/\1-\2/g' $STATUS_PAGE)" |
| + | local DEF="$(sed -e '/^<TD>default via/!d' -e 's/.*html">\(.*\)<\/A>.*/\1/g' $STATUS_PAGE)" |
| + | local FFF="$(sed '/.*[0-9]\.[0-9]\.[0-9]*<\/TD>/!d;s/.*\([0-9]\.[0-9]\.[0-9]*\)<\/TD>/\1/g;q' $STATUS_PAGE)" |
| + | |
| + | if [ "$(echo $MAC | sed 's/..:..:..:..:..:../ok/g')" != "ok" ]; then |
| + | if [ "$OLD_MAC" != "00:00:00:00:00:00" ]; then # old mac already in database |
| + | NEW_MAC="$OLD_MAC" |
| + | else |
| + | NEW_MAC="00:00:00:00:00:00" # standard-value |
| + | fi |
| + | else |
| + | NEW_MAC="$MAC" |
| + | fi |
| + | |
| + | if [ -z "$TYP" ]; then |
| + | if [ "$OLD_TYP" != "router" ]; then |
| + | NEW_TYP="$OLD_TYP" |
| + | else |
| + | NEW_TYP="router" |
| + | fi |
| + | else |
| + | if [ "$(fkt_calc_node_from_ip "$TYP")" = "0" ] || [ "$(fkt_calc_node_from_ip "$TYP")" = "$(fkt_calc_node_from_ip "$IP")" ]; then |
| + | NEW_TYP="INTERNET" |
| + | else |
| + | NEW_TYP="$TYP" |
| + | fi |
| + | fi |
| + | |
| + | if [ -z "$DEF" ]; then |
| + | if [ "$OLD_DEF" != "gateway" ]; then |
| + | NEW_DEF="$OLD_DEF" |
| + | else |
| + | NEW_DEF="gateway" |
| + | fi |
| + | else |
| + | NEW_DEF="$DEF" |
| + | fi |
| + | |
| + | if [ -z "$FFF" ]; then |
| + | if [ "$OLD_FFF" != "0.1.2" ]; then |
| + | NEW_FFF="$OLD_FFF" |
| + | else |
| + | NEW_FFF="0.1.2" |
| + | fi |
| + | else |
| + | NEW_FFF="$FFF" |
| + | fi |
| + | |
| + | rm $STATUS_PAGE |
| + | } |
| + | |
| + | case $1 in |
| + | start) |
| + | fkt_prepare |
| + | fkt_get_random_node |
| + | IP=$RAND_NODE |
| + | fkt_get_status |
| + | |
| + | test -z "$NEW_MAC" && NEW_MAC="00:00:00:00:00:00" |
| + | echo "$( fkt_calc_node_from_ip $IP) $NEW_MAC" |
| + | ;; |
| + | *) |
| + | echo "Usage: $0 start" |
| + | ;; |
| + | esac |
| + | </pre> |
| + | |
| + | ===NVRAM klaeren und saeubern / aus CFE wiederherstellen ohne Reboot=== |
| + | |
| + | <pre> |
| + | # Vorbereitung: Daten aus Original-CFE extrahieren: |
| + | strings /dev/mtdblock/0 | awk '{m=match($1,"=");if(substr($1,m+1,1)=="%")exit;if(m>0)print "nvram set "$1";"}' >/tmp/cfe_original.txt |
| + | |
| + | # Vorbereitung: Unnuetzen Mist loeschen: |
| + | nvram show | grep -v il0macaddr | grep -v et0macaddr | grep -v ff_dsskey | grep -v ff_pw | grep -v ff_reset | awk '{m=match($0,"="); print "nvram unset \""substr($0,1,m-1)"\""}' >/tmp/delete_nvram.txt |
| + | |
| + | # Vorbereitung: cron.minutely umbennen |
| + | mv /usr/sbin/cron.minutely /usr/sbin/cron.minutely_old |
| + | |
| + | # Loeschen und '''schnell''' neuerzeugen (Schnelleinstellung durchlaufen lassen, sofort wenn das Skript durchgelaufen ist, sonst bricht die WLAN-Verbindung ab...) |
| + | sh /tmp/delete_nvram.txt; sh /tmp/cfe_original.txt; nvram set boot_wait=on; mv /usr/sbin/cron.minutely_old /usr/sbin/cron.minutely |
| + | |
| + | # Fertig! |
| + | </pre> |
| + | |
| + | ===Zwang-Interface Aufteilung=== |
| + | *Skizze (haesslich!): |
| + | <pre> |
| + | ~~|~~ |
| + | | |
| + | ___________________________|_______ |
| + | | ("bridge interfaces") | | | | z.b: Linksys WRT-54-GL |
| + | | =lan_ifnames \___/ | lan_ifnames=vlan0 |
| + | | 5fach-Switch =wl0_ifname | lan_ifname=br0 |
| + | | / \ =wifi_ifname| wl0_ifname/wifi_ifname=eth1 |
| + | | / \ | wan_ifname=vlan1 |
| + | |=lan_ifname =wan_ifname | |
| + | |("bridge name") | z.b. Dell Truemobil 2300 |
| + | | ________ __ | lan_ifnames=eth0 |
| + | | | | | | | | | | lan_ifname=br0 |
| + | |_4xEthernet___1xEthernet_________| wl0_ifname/wifi_ifname=eth2 |
| + | wan_ifname=eth1 |
| + | </pre> |
| + | |
| + | |
| + | ===Interface Bestimmung=== |
| + | <pre> |
| + | A=$(nvram get lan_ifnames) |
| + | B=$(nvram get lan_ifname) |
| + | C=$(nvram get wl0_ifname) |
| + | D=$(nvram get wifi_ifname) |
| + | E=$(nvram get wan_ifname) |
| + | F=$(nvram get boardtype) |
| + | G=$(nvram get boardnum) |
| + | H=$(nvram get et0phyaddr) |
| + | I=$(nvram get vlan0ports) |
| + | J=$(nvram get vlan1ports) |
| + | echo $H-$F-$G : \"$A\" \"$B\" \"$C\" \"$D\" \"$E\" \"$I\" \"$J\"; |
| + | </pre> |
| + | |
| + | ===Interface-Tabelle=== |
| + | <pre> |
| + | Knotennummer Geraet Ausgabe |
| + | 36/166 SE505+8mb 30-0x0101- : "vlan0" "br0" "eth1" "eth1" "vlan1" "0 1 2 3 5*" "4 5" |
| + | 16 Linksys ? 30-0x0101-42 : "vlan0" "br0" "eth1" "eth1" "vlan1" "1 2 3 4 5*" "0 5" |
| + | 54/240 Linksys-WRT54G 30-0x0708-42 : "vlan0" "br0" "eth1" "eth1" "vlan1" "1 2 3 4 5*" "0 5" |
| + | 104 Linksys-WRT54GL 30-0x0467-42 : "vlan0" "br0" "eth1" "eth1" "vlan1" "3 2 1 0 5*" "4 5" |
| + | 518 Asus500gPremium 30-0x042f-45 : "vlan0" "br0" "eth2" "eth2" "vlan1" "1 2 3 4 5*" "0 5" |
| + | 513 Dell2300 30-bcm94710ap-44 : "eth0" "br0" "eth2" "eth2" "eth1" "" "" |
| + | 519 Asus_WL_HDD 0-bcm94710dev-asusX : "" "br0" "eth2" "eth2" "none" "" "" |
| + | |
| + | 517 WAP_v10 -bcm94710dev-2 : "" "br0" "eth2" "eth2" "none" |
| + | 766 Allnet 0277 -bcm94710dev-42 : "vlan2" "br0" "eth2" "eth2" "vlan1" |
| + | 520 Asus500g(old) 30-bcm94710dev-asusX : "" "br0" "eth2" "eth2" "vlan1" |
| + | 128 WAP ?? ?? |
| + | </pre> |
| + | |
| + | ===Asus500g premium - webcam=== |
| + | <pre> |
| + | ipkg install kmod-usb-uhci (?) |
| + | ipkg install kmod-usb2 |
| + | = kmod-usb-core |
| + | = kmod-usb2 |
| + | (insmod usbcore) |
| + | (insmod ehci-hcd) |
| + | ipkg install libpthread (?) |
| + | ipkg install kmod-videodev |
| + | ipkg install philips-webcam (weimarnetz-repo) |
| + | ipkg install http://ftp.iasi.roedu.net/mirrors/openwrt.org/backports/rc5/motion_3.2.6-1_mipsel.ipk |
| + | ipkg install http://naaa.de/programme/motion/libjpeg_6b-1_mipsel.ipk |
| + | |
| + | ipkg install lsusb |
| + | ipkg install kmod-usb-storage |
| + | ipkg install kmod-vfat |
| + | (mount -t usbfs none /proc/bus/usb) ??? |
| + | |
| + | '''/etc/init.d/S90webcam''': |
| + | <pre> |
| + | insmod videodev |
| + | insmod pwc leds=0,0 |
| + | insmod pwcx |
| + | </pre> |
| + | |
| + | '''/etc/motion.conf''': |
| + | http://www.lavrsen.dk/twiki/bin/view/Motion/ConfigFileOptions |
| + | </pre> |
| + | |
| + | <pre> |
| + | daemon on |
| + | quiet on |
| + | |
| + | videodevice /dev/v4l/video0 |
| + | width 640 |
| + | height 480 |
| + | |
| + | target_dir /mnt/usbstick |
| + | jpeg_filename %Y/%m/%d/%H_20-40/%M.%S.cam |
| + | |
| + | snapshot_filename %Y/%m/%d/%H_20-40/%M.%S.snap |
| + | snapshot_interval 60 |
| + | |
| + | text_left "Bastian TV" |
| + | locate on # draw box around moved object |
| + | |
| + | low_cpu 1 # only 1 picture per second when no moving |
| + | framerate 2 # maximum per second |
| + | |
| + | webcam_port 8080 |
| + | webcam_localhost off |
| + | webcam_motion 1 # only 1 frame per second when no motion |
| + | </pre> |
| + | |
| ===Notizen=== | | ===Notizen=== |
| *CFE erstellen online: http://lonewolf.hacker-nin.com/wrt/cfe/ | | *CFE erstellen online: http://lonewolf.hacker-nin.com/wrt/cfe/ |
| *Geschichte von OLSR: https://www.open-mesh.net/optimized-link-state-routing-deamon/olsr-story.txt/view | | *Geschichte von OLSR: https://www.open-mesh.net/optimized-link-state-routing-deamon/olsr-story.txt/view |
| + | *http://mailman.ccsds.org/pipermail/sis-scps-interest/2006-November/000373.html |
| | | |
| ===TrafficShaping / QoS / Eselbremse deluxe=== | | ===TrafficShaping / QoS / Eselbremse deluxe=== |
Zeile 65: |
Zeile 1.011: |
| ** Buffalo Airstation WLA-g54c mit MiniPCI | | ** Buffalo Airstation WLA-g54c mit MiniPCI |
| ** Broadcom 5 Ghz Karte | | ** Broadcom 5 Ghz Karte |
| + | *** Dell Truemobile 1400 mit BCM-4309 - MiniPCI -> genau das gleiche wie BCM-4306 oder Dell 1450/1470 |
| ** Asus/Yakumo: http://www.pollin.de/shop/detail.php?pg=Ng==&a=MjgxOTgyOTk=&ts=0 | | ** Asus/Yakumo: http://www.pollin.de/shop/detail.php?pg=Ng==&a=MjgxOTgyOTk=&ts=0 |
| + | * Film: |
| + | ** very bad things |
| + | ** greek wedding |
| + | ** you kill me |
| + | ** out of rosenheim |
| | | |
| ===Machen!=== | | ===Machen!=== |