Michael Prokop [Fri, 5 Mar 2021 16:30:39 +0000 (17:30 +0100)]
Log efibootmgr errors to efibootmgr.error
On non-UEFI systems, we get an ugly error message:
| root@grml ~ # efibootmgr -v >/dev/null
| Could not parse device path: Invalid argument
Instead log stderr output to efibootmgr.error
Michael Prokop [Fri, 5 Mar 2021 16:06:50 +0000 (17:06 +0100)]
Log 'ip route show table' errors to corresponding error file
We are iterating over the defined tables in /etc/iproute2/rt_tables,
though for tables that don't exist, ip reports an ugly error message,
that's a bit confusing during execution within grml-hwinfo:
| root@grml ~ # grep -v '^#' /etc/iproute2/rt_tables
| 255 local
| 254 main
| 253 default
| 0 unspec
| root@grml ~ # ip route show table 253
| Error: ipv4: FIB table does not exist.
| Dump terminated
Instead, store its error message to an according error file.
Michael Prokop [Fri, 5 Mar 2021 16:01:42 +0000 (17:01 +0100)]
Provide information to user if sysdump might be hanging
Sometimes new files show up in the kernel and sysdump
might be hanging while reading them. To make this more
visible to the user and how to track this down, provide
information, if not running with -q/-quiet.
Related to https://github.com/grml/grml-hwinfo/issues/3
Michael Prokop [Fri, 5 Mar 2021 15:13:25 +0000 (16:13 +0100)]
sysdump: rework ignore list code and ignore further files
When getting towards /sys/kernel/tracing, the script is known to hang
at least at the following files:
* /sys/kernel/tracing/trace_pipe
* /sys/kernel/tracing/per_cpu/cpu[0-9]+/trace_pipe
* /sys/kernel/tracing/per_cpu/cpu[0-9]+/trace_pipe_raw
* /sys/kernel/tracing/per_cpu/cpu[0-9]+/snapshot_raw
So we need to extend the list of files to be ignored.
While at it, rework the checks and ignore a bunch of further files, that
can't be read, e.g. due to "Permission denied".
FTR, we sadly can't ignore "/sys/.*/uevent" files globally, as
there are a bunch of files that contain and also provide actual data.
Thanks: Darshaka Patirana for tracking down the /sys/kernel/tracing/* issue
Closes: grml/grml-hwinfo#3
Michael Prokop [Fri, 22 Jan 2021 11:11:57 +0000 (12:11 +0100)]
Release new version 0.15.4
Michael Prokop [Thu, 8 Oct 2020 14:13:13 +0000 (16:13 +0200)]
Store `ip netconf` output in file `ip_netconf`
Thanks: Christian Hofstaedtler
Michael Prokop [Tue, 12 May 2020 14:25:52 +0000 (16:25 +0200)]
Release new version 0.15.3
Michael Prokop [Tue, 12 May 2020 14:25:31 +0000 (16:25 +0200)]
Execute 'wrap-and-sort -a -t -s' on debian/
Michael Prokop [Tue, 12 May 2020 14:24:51 +0000 (16:24 +0200)]
Bump Debian compat version to 12, using debhelper-compat approach
Michael Prokop [Tue, 12 May 2020 14:16:51 +0000 (16:16 +0200)]
Bump Standards-Version to 4.5.0
Michael Prokop [Wed, 13 Nov 2019 20:25:27 +0000 (21:25 +0100)]
Bump Standards-Version to 4.4.1
Michael Prokop [Wed, 13 Nov 2019 20:24:22 +0000 (21:24 +0100)]
Store output of `lscpu -e` in file `lscpu_extended`
Michael Prokop [Thu, 11 Jul 2019 15:25:42 +0000 (17:25 +0200)]
Release new version 0.15.2
Michael Prokop [Mon, 24 Jun 2019 13:16:58 +0000 (15:16 +0200)]
Store cpuid output in file `cpuid`, add cpuid to Recommends
Michael Prokop [Thu, 31 Jan 2019 12:41:58 +0000 (13:41 +0100)]
Release new version 0.15.1
Michael Prokop [Thu, 31 Jan 2019 12:41:42 +0000 (13:41 +0100)]
Bump Standards-Version to 4.3.0
Michael Prokop [Thu, 31 Jan 2019 12:40:24 +0000 (13:40 +0100)]
Record uptime (/proc/uptime in `proc_uptime` and uptime(1) in file `uptime`)
Thanks: Ralf Moll for the suggestion
Michael Prokop [Tue, 15 Jan 2019 09:40:34 +0000 (10:40 +0100)]
Release new version 0.15.0
Michael Prokop [Tue, 15 Jan 2019 09:36:01 +0000 (10:36 +0100)]
Report SecureBoot state via mokutil
Michael Prokop [Tue, 15 Jan 2019 09:28:03 +0000 (10:28 +0100)]
Store "$HOME"/.local/share/xorg/Xorg.0.log (if available) as user_Xorg.0.log
Michael Prokop [Tue, 15 Jan 2019 09:27:48 +0000 (10:27 +0100)]
Log output of verbose lsusb run in file lsusb_verbose
Michael Prokop [Tue, 15 Jan 2019 09:27:23 +0000 (10:27 +0100)]
Provide output of verbose lspci run in file lspci_verbose
Michael Prokop [Tue, 15 Jan 2019 09:26:48 +0000 (10:26 +0100)]
Recommend acpica-tools package and provide acpidump output (as root)
Michael Prokop [Wed, 14 Nov 2018 20:15:57 +0000 (21:15 +0100)]
Release new version 0.14.1
Michael Prokop [Wed, 14 Nov 2018 20:14:03 +0000 (21:14 +0100)]
debian/rules: use /usr/share/dpkg/pkg-info.mk for identifying version number
Fixes lintian warning:
| I: grml-hwinfo source: debian-rules-parses-dpkg-parsechangelog (line 12)
Michael Prokop [Wed, 14 Nov 2018 20:09:13 +0000 (21:09 +0100)]
Bump Standards-Version to 4.2.1
Michael Prokop [Wed, 14 Nov 2018 20:07:16 +0000 (21:07 +0100)]
Merge remote-tracking branch 'origin/github/pr/2'
Darshaka Pathirana [Wed, 14 Nov 2018 17:17:48 +0000 (18:17 +0100)]
sysdump: ignore /sys/kernel/security/apparmor/revision to avoid hanging
Closes: grml/grml-hwinfo#1
Michael Prokop [Wed, 31 Oct 2018 09:18:44 +0000 (10:18 +0100)]
Release new version 0.14.0
Michael Prokop [Wed, 31 Oct 2018 09:17:48 +0000 (10:17 +0100)]
Provide output of `efibootmgr -v` in file efibootmgr
This is useful for documenting the present EFI boot entries.
Thanks: Ralf Moll for the suggestion
Michael Prokop [Fri, 25 May 2018 11:54:04 +0000 (13:54 +0200)]
Release new version 0.13.3
Michael Prokop [Fri, 25 May 2018 11:53:45 +0000 (13:53 +0200)]
Bump Standards-Version to 4.1.4
Michael Prokop [Tue, 27 Mar 2018 13:29:10 +0000 (15:29 +0200)]
Redirect `ip mrule show` errors to ip_mrule.error
`ip mrule show` depends on CONFIG_IP_MROUTE_MULTIPLE_TABLES
for IPv4 and CONFIG_IPV6_MROUTE_MULTIPLE_TABLES for IPv6,
if either is missing then it fails:
% ip -6 mrule show
32767: from all lookup main
% ip -4 mrule show
RTNETLINK answers: Address family not supported by protocol
Dump terminated
% ip mrule show
RTNETLINK answers: Address family not supported by protocol
Dump terminated
% grep MROUTE /boot/config-$(uname -r)
CONFIG_IP_MROUTE=y
# CONFIG_IP_MROUTE_MULTIPLE_TABLES is not set
CONFIG_IPV6_MROUTE=y
CONFIG_IPV6_MROUTE_MULTIPLE_TABLES=y
% uname -r
4.13.13-6-pve
Noticed on a customer system running Proxmox kernel,
reported towards upstream: https://bugzilla.proxmox.com/show_bug.cgi?id=1711
Michael Prokop [Fri, 9 Jun 2017 20:26:38 +0000 (22:26 +0200)]
Release new version 0.13.2
Michael Prokop [Fri, 9 Jun 2017 20:08:03 +0000 (22:08 +0200)]
sysdump: ignore files inside /sys/kernel/debug to avoid hanging
There are several files inside /sys/kernel/debug which aren't
safe for cat-ing, like for example
/sys/kernel/debug/hid/0003:80EE:0021.0001/events So ignore all
files inside /sys/kernel/debug to avoid a hanging sysdump
process.
While at it avoid read on already closed file-handle and redirect
error message to stderr if a file can't be opened/read.
Closes grml/grml#55
Michael Prokop [Fri, 7 Apr 2017 09:52:43 +0000 (11:52 +0200)]
Release new version 0.13.1
Michael Prokop [Fri, 7 Apr 2017 09:51:43 +0000 (11:51 +0200)]
Provide `acpi --everything` output in file `acpi.everything`
Michael Prokop [Fri, 27 Jan 2017 15:15:05 +0000 (16:15 +0100)]
Release new version 0.13.0
Michael Prokop [Fri, 27 Jan 2017 15:14:49 +0000 (16:14 +0100)]
debian/rules: replace deprecated dh_clean -k with dh_prep
Michael Prokop [Fri, 27 Jan 2017 15:13:37 +0000 (16:13 +0100)]
Add debian/source/format with 3.0 (native)
Michael Prokop [Fri, 27 Jan 2017 15:13:11 +0000 (16:13 +0100)]
Bump debian/compat to 9
Michael Prokop [Fri, 27 Jan 2017 15:11:54 +0000 (16:11 +0100)]
Use SSL for Homepage + Vcs-Browser URLs
Michael Prokop [Fri, 27 Jan 2017 15:11:34 +0000 (16:11 +0100)]
Bump Standards-Version to 3.9.8
Michael Prokop [Mon, 14 Dec 2015 12:25:23 +0000 (13:25 +0100)]
Redirect hdparm + sg_inq errors to according .error files
sg_inq might raise:
Both SCSI INQUIRY and fetching ATA information failed on /dev/vda
and hdparm might raise:
HDIO_DRIVE_CMD(identify) failed: Inappropriate ioctl for device
HDIO_GET_IDENTITY failed: Inappropriate ioctl for device
This is annoying when running grml-hwinfo under cron, so
let's redirect this output to their according .error files.
Michael Prokop [Thu, 19 Nov 2015 14:49:00 +0000 (15:49 +0100)]
Release new version 0.12.0
Michael Prokop [Thu, 19 Nov 2015 14:47:07 +0000 (15:47 +0100)]
Don't use working directory when --output-directory option is used
Otherwise when running something like:
/root/system-info/grml-hwinfo --output-directory=/root/system-info/grml-hwinfo-data
via cron this store data to /root/root/system-info/grml-hwinfo-data
(instead of the requested /root/system-info/grml-hwinfo-data) since
/root is the working directory for cron.
Michael Prokop [Thu, 19 Nov 2015 14:20:25 +0000 (15:20 +0100)]
Fix shellcheck issue with quoting
Michael Prokop [Thu, 19 Nov 2015 14:17:37 +0000 (15:17 +0100)]
Improve local disk detection for recent kernel changes
Based on https://github.com/faiproject/fai/blob/master/lib/fai-disk-info
Michael Prokop [Thu, 19 Nov 2015 14:17:19 +0000 (15:17 +0100)]
Support options --force + --quiet for usage with cron
Michael Prokop [Wed, 21 Oct 2015 21:19:50 +0000 (23:19 +0200)]
Release new version 0.11.0
Michael Prokop [Wed, 21 Oct 2015 21:17:13 +0000 (23:17 +0200)]
Bump Standards-Version to 3.9.6
Michael Prokop [Wed, 21 Oct 2015 21:16:15 +0000 (23:16 +0200)]
Save stderr of x86info and discover in *.error instead of *.2
Make those two commands behave as all the other ones
to get consistent behaviour.
Michael Prokop [Wed, 21 Oct 2015 21:14:42 +0000 (23:14 +0200)]
Fix shell scripting issues discovered by shellcheck
Michael Prokop [Wed, 21 Oct 2015 21:03:08 +0000 (23:03 +0200)]
Improve shell quoting (thanks to shellcheck)
Michael Prokop [Wed, 21 Oct 2015 20:42:10 +0000 (22:42 +0200)]
ip: also store table specific route information
Michael Prokop [Tue, 2 Sep 2014 04:05:15 +0000 (21:05 -0700)]
Release new version 0.10.0
Michael Prokop [Tue, 2 Sep 2014 04:04:01 +0000 (21:04 -0700)]
Bump Standards-Version to 3.9.5
Michael Prokop [Tue, 2 Sep 2014 04:02:00 +0000 (21:02 -0700)]
Support i2c-tools's decode-dimms
Michael Prokop [Tue, 2 Sep 2014 03:57:43 +0000 (20:57 -0700)]
Support edac-utils
Michael Prokop [Tue, 2 Sep 2014 03:46:32 +0000 (20:46 -0700)]
Support mcelog
Michael Prokop [Mon, 3 Feb 2014 15:20:45 +0000 (16:20 +0100)]
Release new version 0.9.2
Michael Prokop [Tue, 8 Oct 2013 13:04:42 +0000 (15:04 +0200)]
Support iproute2 as alternative to iproute in Recommends
iproute is a transitional dummy package for iproute2 nowadays
Michael Prokop [Wed, 14 Aug 2013 11:02:36 +0000 (13:02 +0200)]
Release new version 0.9.1
Michael Prokop [Wed, 14 Aug 2013 11:00:11 +0000 (13:00 +0200)]
Use iproute's ip tool to retrieve all its output
Michael Prokop [Tue, 18 Jun 2013 15:21:47 +0000 (17:21 +0200)]
Release new version 0.9.0
Michael Prokop [Tue, 18 Jun 2013 15:18:48 +0000 (17:18 +0200)]
Read /proc/acpi/info only if the file exists, drop calls to acpi_available
Inside e.g. KVM /proc/acpi/info doesn't exist.
Michael Prokop [Tue, 18 Jun 2013 14:44:09 +0000 (16:44 +0200)]
Add support for sg_inq from sg3-utils
Michael Prokop [Tue, 14 May 2013 14:31:25 +0000 (16:31 +0200)]
Support lscpu, lsblk and dmsetup ls --tree
Thanks to Michael Renner for triggering this.
Michael Prokop [Tue, 2 Oct 2012 07:58:21 +0000 (09:58 +0200)]
Release new version 0.8.0
Michael Prokop [Tue, 2 Oct 2012 07:57:47 +0000 (09:57 +0200)]
Bump Standards-Version to 3.9.4
Michael Prokop [Mon, 24 Sep 2012 09:57:05 +0000 (11:57 +0200)]
lsscsi: collect transport information in lsscsi_transport
Example output:
| # lsscsi -t
| [0:0:0:0] disk iqn.2006-01.com.openfiler:tsn.
a5dd60798cd3,t,0x1 /dev/sda
| [1:0:0:0] disk iqn.2006-01.com.openfiler:tsn.
7c1eb1d587d9,t,0x1 /dev/sdb
| [...]
This is useful for getting the mapping between local block device
and iSCSI target names.
Michael Prokop [Thu, 20 Sep 2012 08:49:31 +0000 (10:49 +0200)]
Retrieve information about SCSI devices using lsscsi
Turns out to be very useful when trying to identify where a
specifc block device is coming from, e.g.:
| # lsscsi
| [0:0:0:0] disk OPNFILER VIRTUAL-DISK 0 /dev/sda
Thanks: Christian Hofstaedtler for the hint
Michael Prokop [Thu, 20 Sep 2012 08:48:43 +0000 (10:48 +0200)]
Add support retrieving iSCSI information using iscsiadm from open-iscsi
Michael Prokop [Thu, 16 Aug 2012 08:41:04 +0000 (10:41 +0200)]
Release new version 0.7.0
Michael Prokop [Thu, 16 Aug 2012 08:31:17 +0000 (10:31 +0200)]
Run tar with --auto-compress for better --output-file support
Michael Prokop [Thu, 16 Aug 2012 08:31:13 +0000 (10:31 +0200)]
Improve usage text
Michael Prokop [Thu, 16 Aug 2012 08:22:11 +0000 (10:22 +0200)]
Remove only empty *.error files to see which commands have been executed
Michael Prokop [Thu, 16 Aug 2012 08:22:06 +0000 (10:22 +0200)]
Run lspci -nn for lspci output, do not check for /proc/bus/* for lspnp && lsusb commands but instead just run exectest
Michael Prokop [Thu, 16 Aug 2012 08:19:00 +0000 (10:19 +0200)]
Unify indention
Michael Prokop [Thu, 16 Aug 2012 08:12:29 +0000 (10:12 +0200)]
Fix formating of disk tools output
Michael Prokop [Thu, 16 Aug 2012 08:08:09 +0000 (10:08 +0200)]
Support proxmox/libvirt/openvz/vserver information retrieval
Michael Prokop [Thu, 16 Aug 2012 08:05:40 +0000 (10:05 +0200)]
Rework cmdline option handling, replacing "-df" with "-b" and adding new options
The cmdline option handling totally sucked. While adding new options
like --output-directory and --output-file we have to replace the "-df"
option with "-b"/"--both" because of the way getopt works.
Michael Prokop [Wed, 15 Aug 2012 23:43:25 +0000 (01:43 +0200)]
Redirect dpkg error message for running_kernel
Michael Prokop [Wed, 15 Aug 2012 23:32:57 +0000 (01:32 +0200)]
Release new version 0.6.0
Michael Prokop [Wed, 15 Aug 2012 23:31:58 +0000 (01:31 +0200)]
Get rid of generated files which are empty
Michael Prokop [Wed, 15 Aug 2012 23:23:42 +0000 (01:23 +0200)]
Improve check for running_kernel
Michael Prokop [Wed, 15 Aug 2012 23:19:39 +0000 (01:19 +0200)]
Update Recommends and package description to reflect current state of script
Michael Prokop [Wed, 15 Aug 2012 23:19:05 +0000 (01:19 +0200)]
Drop support for ddcprobe which is deprecated since ages
Michael Prokop [Wed, 15 Aug 2012 23:18:59 +0000 (01:18 +0200)]
List missing tools in file missing_tools
Michael Prokop [Wed, 15 Aug 2012 23:10:16 +0000 (01:10 +0200)]
Drop ${shlibs:Depends} from Depends
Michael Prokop [Wed, 15 Aug 2012 23:09:38 +0000 (01:09 +0200)]
Use Recommends for all packages instead of Suggests
Michael Prokop [Wed, 15 Aug 2012 23:06:05 +0000 (01:06 +0200)]
Drop deprecated pcmcia-utils from Suggests
Michael Prokop [Wed, 15 Aug 2012 23:05:34 +0000 (01:05 +0200)]
Apply wrap-and-sort on Debian package
Michael Prokop [Wed, 15 Aug 2012 23:03:09 +0000 (01:03 +0200)]
Bump Standards-Version to 3.9.3
Michael Prokop [Wed, 15 Aug 2012 23:02:18 +0000 (01:02 +0200)]
Add support for swapon, mdadm, LVM + dmsetup
While ad it make the script use bash in shebang to avoid failing bashism.
Michael Prokop [Fri, 27 Jan 2012 23:04:21 +0000 (00:04 +0100)]
Release new version 0.5.0
Michael Prokop [Fri, 27 Jan 2012 23:03:21 +0000 (00:03 +0100)]
Drop deprecated Conflicts with grml-scripts <= 0.4-15
Michael Prokop [Fri, 27 Jan 2012 23:02:06 +0000 (00:02 +0100)]
debian/rules: provide build-arch+ build-indep
Make lintian happy...
Michael Prokop [Fri, 27 Jan 2012 22:57:27 +0000 (23:57 +0100)]
Adjust version string of script during package build-time
Michael Prokop [Fri, 27 Jan 2012 22:53:46 +0000 (23:53 +0100)]
Support numactl to retrieve NUMA information