aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [redhat] Add a 'cantboot' presetJake Hunsaker2019-03-191-0/+9
| | | | | | | | | | | | | | | Adds a 'cantboot' preset to enable a small number of plugins that may be useful when troubleshooting a situation in which normal system startup is failing. Longer term, it would be beneficial if this preset could be automatically loaded if sos detects that it is running in a system that has been booted to rescue/emergency mode. Resolves: #1522 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [pacemaker] Collect full status outputJake Hunsaker2019-03-191-1/+1
| | | | | | | | | Changes the 'pcs status' collection to display full status results. Resolves: #1521 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [cockpit] Add new pluginJake Hunsaker2019-03-191-0/+30
| | | | | | | | | | Adds a new plugin to collect information about Cockpit, a browser-based system configuration and management tool. Resolves: #1491 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [pcp] Collect summary data for the current dayJake Hunsaker2019-03-191-1/+11
| | | | | | | | | | Adds collection of a pmstat summary output using 5 minute intervals for the current day, and makes a root symlink to it in the archive. Resolves: #1520 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [logs] Debian: Add Journal support and stop full tarball of /var/logBryan Quigley2019-03-191-12/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These changes are only on the Debian/Ubuntu bit of logs Persistent systemd journaling (/var/log/journal exists) use that instead of collecting any kern/syslog/auth from /var/log. We also implement a log_days similar to the RH bit, but we default to 7 days instead of 3. --all-logs removes the day limit and gets it all Rsyslog style (assumed if /var/log/journal doesn't exist default run: collect all 4 of syslog[.1] and kern.log[.1] (Same as previous behavior plus auth.log). --all-logs: collect syslog*, kern.log*, and auth.log* The notable change for --all-logs is it used to just collect all of /var/log which causes MANY issues. Before this change using --all-logs on systems with persistent journal we would collect duplicate log files as such: * Collect all of syslog*/kern*/auth* * Collect the entire journal via /var/log/journal * Collect the last two boots of journal via running journalctl command Even with this change we still collect the journal last/current boot with whatever is copied by journal since log_days. Resolves: #1519 Signed-off-by: Bryan Quigley <bryan.quigley@canonical.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [podman] Collect port mappingsJake Hunsaker2019-03-191-0/+1
| | | | | | | | | Adds collection of port mappings for podman containers. Resolves: #1518 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [tuned] Collect verify outputJake Hunsaker2019-03-191-1/+2
| | | | | | | | | | Adds collection of 'tuned-adm verify' to allow for quick and easy reference as to if tunables have been changed on a system using tuned. Resolves: #1513 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [pacemaker] Collect stonith history and watchdogsJake Hunsaker2019-03-191-0/+2
| | | | | | | | | | Adds collection of stonith fencing history and a list of configured watchdogs. Resolves: #1512 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [vdo] Get status output individually, and collect stats outputJake Hunsaker2019-03-191-1/+7
| | | | | | | | | | | Updates the vdo plugin to grab status information for each individual volume rather than dumping everything into a single output. Additionally collect vdostats output. Resolves: #1510 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [redhat] Update policy to identify RHEL 8Jake Hunsaker2019-03-191-0/+2
| | | | | | | | | | Now that RHEL 8 Beta is out, update the redhat policy dist_version to be able to properly set the version. Resolves: #1509 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [hardware] collect Extended Display Identification DataPavel Moravec2019-03-191-1/+2
| | | | | | | | Collect /sys/class/drm/*/edid . Resolves: #1507 Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
* [networking] Extend ethtool command setPatrick Talbert2019-03-191-1/+7
| | | | | | | | | | | | | | | | | | | | Update the list of ethtool commands to include: ethtool -e (EEPROM dump) ethtool -P (permanent MAC address) ethtool -l (channel/queue settings) ethtool --phy-statistics ethtool --show-priv-flags ethtool --show-eee All of the above are helpful in understanding the state of modern NICs. And -P is nice to have as otherwise there is no reliable way to see the permanent MAC of team ports. Resolves: #1503 Signed-off-by: Patrick Talbert <ptalbert@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [peripety] Add new pluginJake Hunsaker2019-03-191-0/+42
| | | | | | | | | Adds a new plugin for the storage event monitoring daemon peripety. Resolves: #1502 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [mysql] Enable mysql for OSP container envMartin Schuppert2019-03-191-1/+2
| | | | | | | | | | | | | In containerized OSP env we now do not have no mysql packages installed outside the containers. Therefore the mysql plugin does not auto run. This adds the openstack-selinux package to the RH package list of the mysql plugin like on the OSP plugins. Resolves: #1501 Signed-off-by: Martin Schuppert <mschuppert@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [stratis] Add new pluginJake Hunsaker2019-03-191-0/+33
| | | | | | | | | Adds a new plugin for the stratis storage manager Resolves: #1495 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [kubernetes] Fix 'describe' option enablement and functionJake Hunsaker2019-03-191-13/+13
| | | | | | | | | | | | | | | | | | The 'describe' option logic was incorrectly nested behind the 'all' option logic - so users couldn't successfully use the 'describe' option unless they also specified 'all'. Fixes the alignment so that 'describe' can be used properly and separately. Additionally fixes an issue where the syntax for getting resources for a specified namespace only worked for pods, and otherwise generated an error. Resolves: #1494 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [sosreport] Clear nested threadpool threads on timeoutJake Hunsaker2019-03-191-1/+1
| | | | | | | | | | | | | | | | | | | | | We nest ThreadPoolExecutors to run plugins to enable whole-plugin timeouts, with the timeout being handled by the nested threadpool. However, calling shutdown() on the nested thread is incorrect in the event of a plugin timeout, as it only cancels pending jobs, not currently running jobs that the timed-out plugin is. Instead, call _threads.clear() to forcibly cancel the running job, thus allowing the thread the return to the higher level threadpool and allow other plugins to run via that thread. This still allows data captured up to the point of the timeout to be written to the sosreport. Fixes: #1446 Resolves: #1492 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [sosreport] raise SystemExit out of list handlersBryn M. Reeves2019-03-191-4/+3
| | | | | | | | | | | | | | | Since the temporary directories have already been set up by the time we process the --list-* handling (plugins, profiles, presets), we still need to follow the _cleanup() path at exit. To avoid a duplicate _cleanup() and resulting File Not Found exception, raise SystemExit out of these paths, which takes us through the normal exception handling in SoSReport.execute() and is consistent with all other paths through the command. Resolves: #1594. Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [insights] fix handling of configs tupleBryn M. Reeves2019-03-191-16/+12
| | | | | | | | | | | The configs member is now a tuple: we can't just slam it into a add_copy_specs() list or a do_file_sub() call and have it work. Split out the a_c_s() and pass the tuple alone (it looks less ugly than having a cons inside the list), and loop over the elements in postproc to handle the possible file locations. Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [fibrechannel] add fc_vports attribute collectionJohn Pittman2019-03-191-1/+2
| | | | | | | | | | | | Present in the /sys/class/ directory is a fourth fc directory called fc_vports. Collect attribute info for ports in this directory as they are useful in troubleshoting fabric config issues. Resolves: #1490 Signed-off-by: John Pittman <jpittman@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [scsi] collect scsi_host sysfs host valuesJohn Pittman2019-03-191-0/+5
| | | | | | | | The scsi_host attributes can be very important when identifying LLD/shost level issues. Add host value collection via udevadm. Signed-off-by: John Pittman <jpittman@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [block] collect queue values for block devicesJohn Pittman2019-03-191-0/+2
| | | | | | | | | The queue values for block devices are very important for performance, alignment, and I/O size issues. Add these values by default. Signed-off-by: John Pittman <jpittman@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [insights] update package names and pathsAshish Humbe2019-03-191-5/+13
| | | | | | | Resolves: #1426 Signed-off-by: Ashish Humbe <ahumbe@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [subscription_manager] Add syspurpose and rct collectionJake Hunsaker2019-03-191-1/+6
| | | | | | | | | | | | Adds syspurpose output collection which is a new tool to assist with subscription manager on RHEL systems. Also adds rct output for default product certificates. Resolves: #1489 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [firewalld] Collect direct rules, overall state and logging settingPatrick Talbert2019-03-191-1/+9
| | | | | | | | | | | | | Direct Rules are an increasingly common way to control the firewall, but current sos plugin output does not get these. Update the plugin to grab firwall-cmd output about Direct Rules, and also pick up the 'state' output and newer logging settings. Resolves: #1486 Signed-off-by: Patrick Talbert <ptalbert@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [policies] Fix default xz versionPierre Equoy2019-03-191-1/+1
| | | | | | | | | | | | | | | | | | | While running some tests using sosreport in a snap, I ran into the following issue: Creating compressed archive... [archive:TarFileArchive] An error occurred compressing the archive: unorderable types: int() >= str() This is because the `xz_version` variable might be set to a list containing one integer, but it was later compared to a list of strings, raising an exception. Resolves: #1485 Signed-off-by: Pierre Equoy <pierre.equoy@canonical.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [services/upstart] Cleanup and move commands to right pluginBryan Quigley2019-03-192-7/+3
| | | | | | | | | | Remove /sbin/ for service command so it runs on ubuntu. Move initctl command to upstart plugin Resolves: #1484 Signed-off-by: Bryan Quigley <bryan.quigley@canonical.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openstack_instack] more indentation fixesBryn M. Reeves2019-03-191-12/+12
| | | | | | | The outer loop was also double-indented (my local version of pycodestyle did not pick this up, nor did my eyes...). Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [ipvs] Gather additional ipvsadm outputPatrick Talbert2019-03-191-1/+6
| | | | | | | | | | Collect further ipvsadm details and always do so with the -n numeric option. Resolves: #1483 Signed-off-by: Patrick Talbert <ptalbert@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openstack_instack] re-format innermost loopBryn M. Reeves2019-03-191-10/+10
| | | | | | | Re-format the indentation and structure of the innermost loop in the failed deployments capture. Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openstack_instack] pass lists to add_cmd_output()Bryn M. Reeves2019-03-191-3/+4
| | | | Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openstack_instack] Support for multiple stacksJoe Talerico2019-03-191-22/+26
| | | | | | | The OpenStack undercloud can support > 1 stack. This patch will iterate through all the possible stacks deployed on the undercloud. Signed-off-by: Joe Talerico <rook@redhat.com>
* [presets] Create preset directory if it does not existJake Hunsaker2019-03-191-0/+3
| | | | | | | | | | | When attempting to add a preset when /var/lib/sos/presets does not exist, the attempt will fail. Now, if the directory does not exist, sos will attempt to create it. Resolves: #1480 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [man] Update manpage for presetsJake Hunsaker2019-03-191-0/+33
| | | | | | | | | | | | | The manpage for sosreport was previously missing documentation for the new preset feature in 3.6. This updates the manpage to include entries for add-preset, del-preset, list-presets, and the --desc options. Resolves: #1479 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [smartcard] collect info about smart card readers via openscPavel Moravec2019-03-181-3/+10
| | | | | | | | | Inspect smart card reader information using opensc command pkcs11-tool and collect its configuration. Resolves: #1478 Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
* [juju] Add detection when juju is installed as a snap.Eric Desrochers2019-03-181-1/+1
| | | | | | | | | | | Conventional DEB package extract juju binary in /usr/bin/juju, but SNAP extract juju binary in /snap/bin/juju. Fixes: #1475 Resolves: #1476 Signed-off-by: Eric Desrochers eric.desrochers@canonical.com Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [etcd] Include journalJuan-Luis de Sousa-Valadas Castaño2019-03-181-0/+1
| | | | | | | Resolves: #1474 Signed-off-by: Juan-Luis de Sousa-Valadas <jdesousa@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [plugins] Decrease log verbosity when do_file_sub failed on missing filePavel Moravec2019-03-181-2/+8
| | | | | | | | | In case do_file_sub fails to apply a substitution on a non-existing file, don't log it as an error log to stdout. Resolves: #1471 Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
* [openvswitch] Capture additional datapath flowsAndreas Karis2019-03-181-0/+2
| | | | | | | | | | Capture additional datapath flows for the OVS netdev datapath with: ovs-appctl dpctl/dump-flows Resolves: #1468 Signed-off-by: Andreas Karis <akaris@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [ipsec] Remove IPSec plugin in favor of OpenSwanRobb Manes2019-03-181-42/+0
| | | | | | | | | | | | | | Red Hat distributions have not used the ipsec-tools and racoon packages since RHEL5, and all of this information is collected in the OpenSwan module via the same paths. Similarly, Debian distributions have not provided this since wheezy, and the same data is collected in OpenSwan. Resolves: #1465 Signed-off-by: Robb Manes <rmanes@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openswan] fix option list styleBryn M. Reeves2019-03-181-3/+4
| | | | Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openswan] Forbid collection of secrets and certdbRobb Manes2019-03-181-1/+6
| | | | | | | | | | | | | | When collecting IPSec data, currently nothing prevents the collection of keys or the cert.db files. Ensure we don't collect this information as it is private. Thanks to Robert Bost (@bostrt) for discovering this and Matt Rogers (@mrogers950) for double checking what we should ignore. Resolves: #1463 Signed-off-by: Robb Manes <rmanes@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [utilities] Remove the __path__ attribute comparison with empty stringSourabh Jain2019-03-181-1/+1
| | | | | | | | | | | | | | | This patch removes an unnecessary comparison on package's __path__ attribute with an empty string in get_modules method. When we pass an empty path to _find_plugins_from_list function it returns None. The NoneType is not an iterable entity, so this will leads to runtime error when we extend the plugins list with None value. Resolves: #1463 Signed-off-by: Sourabh Jain <sourabhjain@linux.ibm.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [sosreport] use mode='w' when writing plugin exceptionsFilip Krska2019-03-181-1/+1
| | | | | | | | | | Use append mode when writing to plugin exception files: otherwise, if multiple exceptions occur within one plugin (e.g. in separate execution phases), the later ones will overwrite the earlier. Resolves: #1461 Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [archive] add mode argument to Archive.add_string()Filip Krska2019-03-181-3/+3
| | | | | | | | | Add mode (e.g. to allow append) support to add_string() function. Related: #1461 Signed-off-by: Filip Krska <fkrska@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [ovirt] collect `engine-config -d` when availableDan Kenigsberg2019-03-181-2/+6
| | | | | | | | | | Newer versions of ovirt-engine can produce a short and readable diff from the "factory defaults". Resolves: #1460 Signed-off-by: Dan Kenigsberg <danken@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [openstack_novajoin] Novajoin logs and confDavid Vallee Delisle2019-03-181-0/+40
| | | | | | | Resolves: #1459 Signed-off-by: David Vallee Delisle <dvd@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [networking] call ethtool for proper vlan device namesPavel Moravec2019-03-181-42/+25
| | | | | | | | | | Dont rely on device names from "ip -o link" output where the names contain also physical device name. Rather get the list of device names from listing /sys/class/net/ directory. Resolves: #1458 Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
* [logging] Always cleanup temp directoryJake Hunsaker2019-03-181-0/+1
| | | | | | | | | | | | | | | | When running `sosreport -l`, or the more specific --list-* options, sos still creates a temp directory and log files, however we were not cleaning those up - so over time we could have a multitude of sos temp directories littering the filesystem. Now always cleanup the temp directory after execution. Only exception to this would be if we hit an OSError during execution _and_ the debug option is specified. Resolves: #1456 Signed-off-by: Jake Hunsaker <jhunsake@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
* [filesys] Use the correct interface when calling dumpe2fsXuewei Zhang2019-03-181-1/+1
| | | | | | | | | | dumpe2fs takes one parameter indicating the device to be dumped. Closes: #1452 Resolves: #1453 Signed-off-by: Xuewei Zhang <xueweiz@google.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>