SUSE / machinery

A systems management toolkit for Linux
GNU General Public License v3.0
158 stars 32 forks source link

Machinery quits with below error when trying to inspect SUSE10SP4 machine #2210

Closed sasiharshav closed 7 years ago

sasiharshav commented 7 years ago

I am trying to collect the description of a SUSE 10 Sp4 VM and the process terminates with below errors:

Machinery experienced an unexpected error. Please file a bug report at: https://github.com/SUSE/machinery/issues/new Execution of "ssh root@192.168.152.128 -o LogLevel\=ERROR LANGUAGE\= LC_ALL\=en_US.utf8 zypper --non-interactive -xq --no-refresh patterns -i" failed with status 2: Unknown option --non-interactive (...).

Error output: Unknown option --non-interactive Unknown option -xq Unknown option --no-refresh Unknown command '_unknown'.

Commands: help Help shell, sh Accept multiple commands at once install, in Install packages or resolvables remove, rm Remove packages or resolvables search, se Search for packages matching a pattern service-list, sl List services, also called installation sources service-add, sa Add a new service service-delete, sd Delete a service service-rename, sr Rename a service refresh, ref Refresh all installation sources patch-check, pchk Check for patches patches, pch List patches list-updates, lu List updates update, up Update packages info, if Show full information for packages patch-info Show full information for patches

Backtrace: /usr/local/share/gems/gems/cheetah-0.5.0/lib/cheetah.rb:641:in check_errors' /usr/local/share/gems/gems/cheetah-0.5.0/lib/cheetah.rb:404:inrun' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/logged_cheetah.rb:23:in run' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/remote_system.rb:97:inrun_command' /usr/local/share/gems/gems/machinery-tool-1.22.2/plugins/patterns/patterns_inspector.rb:60:in inspect_with_zypper' /usr/local/share/gems/gems/machinery-tool-1.22.2/plugins/patterns/patterns_inspector.rb:29:ininspect' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/inspect_task.rb:87:in block in build_description' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/inspect_task.rb:79:ineach' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/inspect_task.rb:79:in build_description' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/inspect_task.rb:21:ininspect_system' /usr/local/share/gems/gems/machinery-tool-1.22.2/lib/cli.rb:768:in block (2 levels) in <class:Cli>' /usr/local/share/gems/gems/gli-2.14.0/lib/gli/command_support.rb:126:incall' /usr/local/share/gems/gems/gli-2.14.0/lib/gli/command_support.rb:126:in execute' /usr/local/share/gems/gems/gli-2.14.0/lib/gli/app_support.rb:296:inblock in call_command' /usr/local/share/gems/gems/gli-2.14.0/lib/gli/app_support.rb:309:in call' /usr/local/share/gems/gems/gli-2.14.0/lib/gli/app_support.rb:309:incall_command' /usr/local/share/gems/gems/gli-2.14.0/lib/gli/app_support.rb:83:in run' /usr/local/share/gems/gems/machinery-tool-1.22.2/bin/machinery:41:in<top (required)>' /usr/local/bin/machinery:23:in load' /usr/local/bin/machinery:23:in

'

thardeck commented 7 years ago

@sasiharshav Thx for your report. The zypper version of SLES10SP4 is too old, so it does not support the parameters we need.

While reproducing the issue I also encountered that the stat command does not support an option we require for the changed files inspections.

What you can do is inspect by excluding the non-working inspectors:

machinery inspect -x 192.168.152.128 -e patterns,repositories,changed-config-files,changed-managed-files

Additionally there is a non supported workaround where you can install a newer zypper version with 32 bit on a 64 bit system, as described here. With this you should be able to inspect patterns and repositories, but this does not changed the problem with the stat command which is required for the changed files inspection.

thardeck commented 7 years ago

Marking as wontfix for now because of the age of SLES10SP4 and an existing work around,