If you like BoxMatrix then please contribute Supportdata, Supportdata2, Firmware and/or Hardware (get in touch).
My metamonk@yahoo.com is not reachable by me since years. Please use hippie2000@webnmail.de instead.

0
U

Property:log sink (avmcmd)

From BoxMatrix


BoxMatrix >> Shell-Commands >> log_sink (avmcmd) @ BoxMatrix   -   IRC-Chat   -   Translate: de es fr it nl pl
News Selectors Models Accessories Components Environment Config Commands System Webif Software Develop Lexicon Community Project Media

Startup-Scr Hotplug-Scr BusyBox-Cmds Bash-Cmds AVM-Cmds Chipset-Cmds Linux-Cmds Shared-Libs Kernel-Mods Research

Info
  
Name-Collision - multiple objects in this wiki use the name log_sink!
log_sink (avmcmd) Inter-CPU logging injector daemon for x490 models.
log_sink (process) Process running log_sink
log_sink (watchdog) Watchdog for log_sink

AVM-Command

Goto:   Source  -  Dependencies   -   Model-Matrix   -   Symbols   -   SMW-Browser

Details

log_sink and log_server are a remote logger solution to forward the Scorpion Linux logs to the VR9 Linux
on 3490, 5490, 5491 and 7490 models.

log_sink sends data to a range of internal IPv6 UDP ports via the eth0 interfacee of the Scorpion which connects the VR9.
The data comes from a range of logs on the Scorpion Linux, which are always FIFOs[1] created with mkfifo.
Excerpt from a 7490 fw 7.29 ps on Scorpion:

 112     1 root     S     1436  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 10 /tmp/supportdata_scrpn fe80::2de:adff:febe:efca 4221
  95     1 root     S     1436  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 10 /dev/debug fe80::2de:adff:febe:efca 4202
 103     1 root     S     1436  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 10 /var/log/hostapd.log fe80::2de:adff:febe:efca 4211
 105     1 root     S     1436  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 10 /var/log/wpa_supplicant.log fe80::2de:adff:febe:efca 4212
 107     1 root     S     1436  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 10 /var/log/acfg.trace fe80::2de:adff:febe:efca 4213
 101     1 root     S     1436  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 10 /tmp/wland_hal_remoted.log fe80::2de:adff:febe:efca 4210
  93     1 root     S     1432  1.2   0  0.0 log_sink -s fe80::b8db:adff:fec0:ffee -d -i eth0 -w 15 /var/flash/crash.log fe80::2de:adff:febe:efca 4214

The counterpart daemon runninng on the VR9 Linux is log_server which writes the forwarded data to logs.
There's also a temporary use of log_sink on the VR9 Linux when creating supportdata.wlan or supportdata_argo.wlan.
Excerpt from supportdata.wlan on 7490 fw 7.29 VR9:

log_server -b1024 -t10 -i wasp 4221 /tmp/supportdata_wlan_offload &
mkfifo /tmp/rcmd_scrpn
log_sink -s fe80::2de:adff:febe:efca -i wasp /tmp/rcmd_scrpn fe80::b8db:adff:fec0:ffee 4220 &
...
echo "support" > /tmp/rcmd_scrpn
sleep ...
...
kill -SIGUSR1 "$sink_pid"
kill -SIGUSR1 "$server_pid"
rm /tmp/rcmd_scrpn
...
cat /tmp/supportdata_wlan_offload

rcmd_scrpn is forwarded to rcmd_vr9 in the Scorpion side and interpreted by watch_supportdata_trigger there.

fw 7.29 help:

fritz3:/var/media/ftp $ log_sink -?

Usage: log_sink [OPTION...] File DestIP DestPort

log_sink reads from a file and sends the data to a UDP port (IPv6only)

  -d, --daemon               start daemonized
  -i, --interface=intf       interface name
  -s, --src-ip=IPv6          source ip address
  -v, --verbose              verbose
  -w, --watchdog-timeout=sec watchdog timeout (0)
  -?, --help                 Give this help list
      --usage                Give a short usage message
  -V, --version              Print program version

Mandatory or optional arguments to long options are also mandatory or optional
for any corresponding short options.

Report bugs to j.balke@avm.de.

Source

The names of source files compiled into an executable often help to understand function blocks (and show gaps in the docs).
fw 7.29 source files:

$ strings /usr/bin/log_server | grep -e '\.c$' -e '\.cpp$'

argp-parse.c
argp-help.c  

Dependencies

Daily updated index of all dependencies of this command. Last update: 2024-12-20 07:46 GMT.
A * in the Mod column marks info from Supportdata-Probes, which will always stay incomplete.

Relation Typ Object Mod Firmware Info Origin
Runs as proc log_sink (process) 5* 7.01 - 7.59 Process running log_sink AVM
Registers wdog log_sink (watchdog) 4* 7.01 - 7.59 Watchdog for log_sink AVM
Serving port Port-37064-udp 3* 6.85 - 7.17 TODO AVM
Depends on lib ld.so 8 7.01 - 7.51 Dynamic linker / loader Linux
Depends on lib libbacktrace.so 8 6.98 - 7.51 Crash handler and logger AVM
Depends on lib libc.so 8 6.98 - 7.51 Standard C library Linux
Depends on lib libwdt.so 8 6.98 - 7.51 AVM-Watchdogs management API AVM
7 dependencies for this command

Model-Matrix

Daily updated index of the presence, path and size of this command for each model. Last update: 2024-12-20 05:43 GMT.
Showing all models using this command. Click any column header (click-wait-click) to sort the list by the respective data.
The (main/scrpn/boot/arm/prx/atom/rtl) label in the Model column shows which CPU is meant for Multi-Linux models.
Note that this list is merged from Firmware-Probes of all known AVM firmware for a model, including Recovery.exe and Labor-Files.

Model Firmware Path Size
FRITZ!Box 3490 (main) 7.01 - 7.30 /usr/bin 36.4k - 40.1k
FRITZ!Box 3490 (scrpn) 6.98 - 7.30 /usr/bin 38.5k - 40.1k
FRITZ!Box 5490 (main) 7.01 - 7.29 /usr/bin 36.4k - 40.1k
FRITZ!Box 5490 (scrpn) 6.98 - 7.29 /usr/bin 38.5k - 40.1k
FRITZ!Box 5491 (main) 7.01 - 7.29 /usr/bin 36.4k - 40.1k
FRITZ!Box 5491 (scrpn) 6.98 - 7.29 /usr/bin 38.5k - 40.1k
FRITZ!Box 7490 (main) 6.98 - 7.51 /usr/bin 33.4k - 40.1k
FRITZ!Box 7490 (scrpn) 6.98 - 7.51 /usr/bin 33.4k - 40.1k
8 models use this command

Symbols

Daily updated index of all symbols of this command. Last update: 2024-12-20 07:46 GMT.

Firmware Symbol
6.98 - 7.51 argp_error
6.98 - 7.51 argp_failure
6.98 - 7.51 argp_fmtstream_free
6.98 - 7.51 argp_fmtstream_printf
6.98 - 7.51 argp_help
6.98 - 7.51 argp_make_fmtstream
6.98 - 7.51 argp_parse
6.98 - 7.51 argp_state_help
6.98 - 7.51 argp_usage
6.98 - 7.51 close_log
6.98 - 7.51 logd_get_running
6.98 - 7.51 logd_install_crashhandler
6.98 - 7.51 logd_install_sighandler
6.98 - 7.51 logd_install_watchdog
6.98 - 7.51 main
6.98 - 7.51 open_log
16 symbols for this command

References

SMW-Browser

Information is currently being retrieved from the backend.