mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2025-12-10 07:44:50 +01:00
self-diagnostics: substitute possible slashes in report names
This commit is contained in:
parent
2dac7741d4
commit
237f30c3f7
10 changed files with 48 additions and 48 deletions
|
|
@ -1,7 +1,7 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=self-diagnostics
|
||||
PKG_VERSION:=1.0.2
|
||||
PKG_VERSION:=1.0.3
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_LICENSE:=GPL-2.0-only
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ Options:
|
|||
It also has an uci file to configure the various parameters:
|
||||
|
||||
```bash
|
||||
# cat /etc/config/self-diagnostics
|
||||
# cat /etc/config/self-diagnostics
|
||||
config globals 'globals'
|
||||
option extended_spec_dir '/etc/self-diagnostics/spec'
|
||||
option exec_timeout '5'
|
||||
|
|
@ -117,7 +117,7 @@ Extension Module(s):
|
|||
### Run and collect logs
|
||||
|
||||
```bash
|
||||
# self-diagnostics
|
||||
# self-diagnostics
|
||||
/tmp/self-diagnostics-report-EX600-Y.0721140081.tar.gz
|
||||
```
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ log()
|
|||
{
|
||||
log_file="${REPORT_DIR}/execution.log"
|
||||
if [ "$VERBOSE" -eq 1 ]; then
|
||||
logger -t $0 "$*"
|
||||
logger -t $0 "$*"
|
||||
fi
|
||||
echo "[$(date +%Y:%m:%d-%H:%M:%S)] $*" >> ${log_file}
|
||||
}
|
||||
|
|
@ -77,7 +77,7 @@ config_load()
|
|||
[ -n "${temp}" ] && \
|
||||
REPORT_NAME="$(eval echo ${temp})"
|
||||
|
||||
REPORT_NAME="${REPORT_NAME// /_}"
|
||||
REPORT_NAME="${REPORT_NAME//[ \/]/_}"
|
||||
|
||||
temp="$(uci -q get self-diagnostics.globals.compression_level)"
|
||||
[ -n "${temp}" ] && \
|
||||
|
|
|
|||
|
|
@ -7,15 +7,15 @@
|
|||
},
|
||||
{
|
||||
"description": "Installed Packages",
|
||||
"cmd": "opkg list-installed"
|
||||
"cmd": "opkg list-installed"
|
||||
},
|
||||
{
|
||||
"description": "Database",
|
||||
"cmd": "db export"
|
||||
"cmd": "db export"
|
||||
},
|
||||
{
|
||||
"description": "Configuration",
|
||||
"cmd": "uci export"
|
||||
"cmd": "uci export"
|
||||
},
|
||||
{
|
||||
"description": "Runtime Configuration",
|
||||
|
|
@ -23,7 +23,7 @@
|
|||
},
|
||||
{
|
||||
"description": "Firmware Environment",
|
||||
"cmd": "fw_printenv"
|
||||
}
|
||||
"cmd": "fw_printenv"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
{
|
||||
"type": "file",
|
||||
"file": "/etc/config/ieee1905"
|
||||
}
|
||||
}
|
||||
],
|
||||
"exec" : [
|
||||
{
|
||||
|
|
@ -34,7 +34,7 @@
|
|||
{
|
||||
"description": "IEEE1905 Others",
|
||||
"cmd": "ubus call ieee1905 others"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "IEEE1905 Topology",
|
||||
"cmd": "ubus call ieee1905.topology dump"
|
||||
|
|
@ -42,7 +42,7 @@
|
|||
{
|
||||
"description": "MAP Agent Info",
|
||||
"cmd": "ubus call map.agent info"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "MAP Agent Status",
|
||||
"cmd": "ubus call map.agent status"
|
||||
|
|
@ -50,7 +50,7 @@
|
|||
{
|
||||
"description": "MAP Agent Backhaul Info",
|
||||
"cmd": "ubus call map.agent backhaul_info"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "MAP Controller Status",
|
||||
"cmd": "ubus call map.controller status"
|
||||
|
|
@ -66,6 +66,6 @@
|
|||
{
|
||||
"description": "Data Elements Dump",
|
||||
"cmd": "ubus call wifi.dataelements.collector refresh; sleep 2; ubus call wifi.dataelements.collector dump2"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
{
|
||||
"description": "Linux Network Interface Config",
|
||||
"cmd": "ifconfig -a"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "IPv4 Routes",
|
||||
"cmd": "ip -d r"
|
||||
|
|
@ -60,7 +60,7 @@
|
|||
{
|
||||
"description": "Bridge FDB",
|
||||
"cmd": "bridge fdb"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "TCP listened ports",
|
||||
"cmd": "netstat -tlnp"
|
||||
|
|
|
|||
|
|
@ -3,65 +3,65 @@
|
|||
"exec" : [
|
||||
{
|
||||
"description": "Firmware banks",
|
||||
"cmd": "ubus call fwbank dump"
|
||||
},
|
||||
"cmd": "ubus call fwbank dump"
|
||||
},
|
||||
{
|
||||
"description": "System Info",
|
||||
"cmd": "ubus call system info"
|
||||
},
|
||||
{
|
||||
"description": "Board Info",
|
||||
"cmd": "ubus call system board"
|
||||
"cmd": "ubus call system board"
|
||||
},
|
||||
{
|
||||
"description": "Running Processes",
|
||||
"cmd": "top -b -n 1"
|
||||
"cmd": "top -b -n 1"
|
||||
},
|
||||
{
|
||||
"description": "Kernel Parameters",
|
||||
"cmd": "sysctl -A 2>/dev/null"
|
||||
},
|
||||
"cmd": "sysctl -A 2>/dev/null"
|
||||
},
|
||||
{
|
||||
"description": "System Log",
|
||||
"cmd": "timeout 5 logread -l 1000"
|
||||
"cmd": "timeout 5 logread -l 1000"
|
||||
},
|
||||
{
|
||||
"description": "Driver Message",
|
||||
"cmd": "timeout 5 dmesg"
|
||||
"cmd": "timeout 5 dmesg"
|
||||
},
|
||||
{
|
||||
"description": "PCI Devices",
|
||||
"cmd": "lspci -k"
|
||||
"cmd": "lspci -k"
|
||||
},
|
||||
{
|
||||
"description": "Installed Modules",
|
||||
"cmd": "lsmod"
|
||||
"cmd": "lsmod"
|
||||
},
|
||||
{
|
||||
"description": "CPU Info",
|
||||
"cmd": "cat /proc/cpuinfo"
|
||||
"cmd": "cat /proc/cpuinfo"
|
||||
},
|
||||
{
|
||||
"description": "Memory Info",
|
||||
"cmd": "cat /proc/meminfo"
|
||||
"cmd": "cat /proc/meminfo"
|
||||
},
|
||||
{
|
||||
"description": "Slab Info",
|
||||
"cmd": "cat /proc/slabinfo"
|
||||
"cmd": "cat /proc/slabinfo"
|
||||
},
|
||||
{
|
||||
"description": "eMMC Partition/Volume Info",
|
||||
"cmd": "fdisk -l",
|
||||
"dependency" : {
|
||||
"file": "/sbin/fdisk"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"description": "NAND Partition/Volume Info",
|
||||
"cmd": "ubinfo --all",
|
||||
"dependency" : {
|
||||
"file": "/usr/sbin/ubinfo"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,13 +4,13 @@
|
|||
{
|
||||
"type": "file",
|
||||
"file": "/etc/config/cwmp"
|
||||
}
|
||||
}
|
||||
],
|
||||
"exec" : [
|
||||
{
|
||||
"description": "TR-181 DM MAP",
|
||||
"cmd": "uci -c /etc/bbfdm/dmmap export"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "TR-181 Parameters via BBFDM",
|
||||
"cmd": "bbfdmd -c get Device."
|
||||
|
|
@ -18,7 +18,7 @@
|
|||
{
|
||||
"description": "TR-181 Parameters via CWMP",
|
||||
"cmd": "icwmpd -c get Device."
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "TR-069 status",
|
||||
"cmd": "ubus call tr069 status"
|
||||
|
|
@ -31,17 +31,17 @@
|
|||
"type": "file",
|
||||
"file": "/var/log/icwmpd.log"
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
{
|
||||
"description": "TR-181 Parameters via USP",
|
||||
"cmd": "obuspa -c get Device.",
|
||||
"timeout": 10
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "USP Agent Database",
|
||||
"cmd": "obuspa -f $(uci -q get obuspa.global.db_file) -c show database"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "USP Logs",
|
||||
"cmd": "cat /var/log/obuspa.log",
|
||||
|
|
@ -50,7 +50,7 @@
|
|||
"type": "file",
|
||||
"file": "/var/log/obuspa.log"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
{
|
||||
"type": "file",
|
||||
"file": "/etc/config/asterisk"
|
||||
}
|
||||
}
|
||||
],
|
||||
"exec" : [
|
||||
{
|
||||
|
|
@ -14,7 +14,7 @@
|
|||
{
|
||||
"description": "Endpoint Count",
|
||||
"cmd": "ubus call endpt count"
|
||||
},
|
||||
},
|
||||
{
|
||||
"description": "Voice Status",
|
||||
"cmd": "ubus call voice.asterisk status"
|
||||
|
|
@ -27,7 +27,7 @@
|
|||
"type": "file",
|
||||
"file": "/etc/config/dect"
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
{
|
||||
"description": "DECT Handsets",
|
||||
|
|
@ -37,7 +37,7 @@
|
|||
"type": "file",
|
||||
"file": "/etc/config/dect"
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
{
|
||||
"type": "file",
|
||||
"file": "/sys/class/ieee80211"
|
||||
}
|
||||
}
|
||||
],
|
||||
"exec" : [
|
||||
{
|
||||
|
|
@ -26,6 +26,6 @@
|
|||
{
|
||||
"description": "iwinfo interface details",
|
||||
"cmd": "/usr/bin/iwinfo"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue