changed scope/position of this function, and reuse it.
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@36300 3c298f89-4303-0410-b956-a3cf2f4a3e73
Range is 1...20 where 1 is fastest protocol speed and 20 is the slowest protocol speed
Like in the Freifunk-Firmware from sven-ola we accept now a per-interface
option 'speed', which should range from 1...20 and is sanitized. when the
value is not in valid range, it defaults to 6 which allows the daemon to
start and behave like in a city-wide mesh. (same default like in freifunk firmware)
The value 'speed' overrides the normal values for emission intervals like
Hello-, Tc-, Mid-, Hna-Interval/ValidityTime or sets them explicitely. this
makes it much easier to play with intervals on several routers:
Instead of changes eight values, we only have to alter 1 value.
The value-calculation is tested since several years.
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@36299 3c298f89-4303-0410-b956-a3cf2f4a3e73
Later we want to reuse that functionality, to avoid code duplication
we make a function with clean entry and return-codes, so we can do e.g.:
get_value_for_entry "$entry" || continue
which is also better readable.
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@36298 3c298f89-4303-0410-b956-a3cf2f4a3e73
for determining all gateways in all routing tables
1) write out the ip-call, never ever abbreviate in scripts
2) avoid forks: sorting/uniq is not needed, if we only append
yet unappended words
3) use an extra function() for this, better readable
4) check for installed ip-command
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@35680 3c298f89-4303-0410-b956-a3cf2f4a3e73
[packages] olsrd: don't try to start smartgw if not all deps are installed
if kmod-ipip is missing, there is no need to invoke an expensive operation.
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@35679 3c298f89-4303-0410-b956-a3cf2f4a3e73
packages: olsrd: use system-logger instead of dumping to stdout,
which is cleaner and also seen if not interactive called. minor
cleanups in some messages, also show function-name in messages.
by using 'logger -s' we can see the message on screen and in logs.
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@35678 3c298f89-4303-0410-b956-a3cf2f4a3e73
This patch add interface name handling for the NonOlsrIf Option in olsrd init script.
e.g. NonOlsrIf=lan and not NonOlsrIf=eth0
Signed-off-by: Patrick Grimm <patrick@lunatiki.de>
git-svn-id: svn://svn.openwrt.org/openwrt/packages@22918 3c298f89-4303-0410-b956-a3cf2f4a3e73
- build arprefresh plugin too
- introduce new 6and4 mode to allow both ipv4 and ipv6 olsrd instances at the same time
- fix incorrect quoting for the Ip6AddrType parameter
- bump package revision
patch from Alina Friedrichsen - thanks!
git-svn-id: svn://svn.openwrt.org/openwrt/packages@13286 3c298f89-4303-0410-b956-a3cf2f4a3e73