Project

General

Profile

Actions

Bug #17893

closed

After migration standard technique packageManagement doesn't work anymore

Added by Alexander Brunhirl almost 4 years ago. Updated almost 4 years ago.

Status:
Rejected
Priority:
N/A
Assignee:
-
Category:
Techniques
Target version:
-
Severity:
Major - prevents use of part of Rudder | no simple workaround
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
To do
Regression:

Description

Hi,

after the rudder 6.0 to 6.1 migration the standard directive "Packages" seems to report errors and don't install the software (e.g. nmap) on SLES12 and CentOS 7 systems.

rudder:~ # rpm -qa nmap
nmap-6.46-3.6.1.x86_64
rudder:~ # rudder agent run -q
Rudder agent 6.1.0.release
Node uuid: 0cc08d81-6e4c-4474-9541-5bc691d511a8
Start execution with config [20200701-111046-598b1f6f]

M| State         Technique                 Component                 Key                Message
E| repaired      Common                    Update                                       Policy or configuration library were updated
E| error         packageManagement         Package                   jq                 Presence of package jq in any version could not be repaired
E| error         packageManagement         Package                   python3-Jinja2     Presence of package python3-Jinja2 in any version could not be repaired
E| error         packageManagement         Package                   sysstat            Presence of package sysstat in any version could not be repaired
E| error         packageManagement         Package                   tmux               Presence of package tmux in any version could not be repaired
E| error         packageManagement         Package                   at                 Presence of package at in any version could not be repaired
E| error         packageManagement         Package                   iotop              Presence of package iotop in any version could not be repaired
E| error         packageManagement         Package                   nmap               Presence of package nmap in any version could not be repaired
E| error         packageManagement         Package                   screen             Presence of package screen in any version could not be repaired

## Summary #####################################################################
200 components verified in 30 directives
   => 200 components in Enforce mode
      -> 140 compliant
      -> 1 repaired
      -> 51 not-applicable
      -> 8 error
Execution time: 7.45s
################################################################################
rudder:~ # zypper rm -y nmap
        [...]
rudder:~ # rpm -qa nmap
rudder:~ # rudder agent run -q
rudder agent run -q
Rudder agent 6.1.0.release
Node uuid: 0cc08d81-6e4c-4474-9541-5bc691d511a8
Start execution with config [20200701-111046-598b1f6f]

M| State         Technique                 Component                 Key                Message
E| error         packageManagement         Package                   jq                 Presence of package jq in any version could not be repaired
E| error         packageManagement         Package                   python3-Jinja2     Presence of package python3-Jinja2 in any version could not be repaired
E| error         packageManagement         Package                   sysstat            Presence of package sysstat in any version could not be repaired
E| error         packageManagement         Package                   tmux               Presence of package tmux in any version could not be repaired
E| error         packageManagement         Package                   at                 Presence of package at in any version could not be repaired
E| error         packageManagement         Package                   iotop              Presence of package iotop in any version could not be repaired
E| error         packageManagement         Package                   nmap               Presence of package nmap in any version could not be repaired
E| error         packageManagement         Package                   screen             Presence of package screen in any version could not be repaired

## Summary #####################################################################
200 components verified in 30 directives
   => 200 components in Enforce mode
      -> 141 compliant
      -> 51 not-applicable
      -> 8 error
Execution time: 7.58s
################################################################################
rudder:~ #
rudder:~ # rpm -qa nmap
rudder:~ # 

Seems to be related to #17875

Best regards,
Alex


Related issues 2 (0 open2 closed)

Related to Rudder - Bug #17875: After migration to 6.1, apt_get fails because of missing `rudder` global parameters ResolvedActions
Related to Rudder - Bug #17873: SLES12 upgrade error 6.0 to 6.1ReleasedAlexis MoussetActions
Actions #1

Updated by Alexander Brunhirl almost 4 years ago

Same with latest available version

E| error         packageManagement         Package                   nmap               Presence of package nmap in latest available version could not be repaired

and specific version ( e.g. 6.46-3.6.1 )

E| error         packageManagement         Package                   nmap               Presence of package nmap in version 6.46-3.6.1 could not be repaired

Actions #2

Updated by Alexander Brunhirl almost 4 years ago

  • Subject changed from After migration standard directive package doesn't work anymore to After migration standard technique packageManagement doesn't work anymore
Actions #3

Updated by François ARMAND almost 4 years ago

What is the output of rudder agent run -i ?

Do you have global parameter rudder defined in rudder?

Actions #4

Updated by Alexander Brunhirl almost 4 years ago

Just collected the data

2020-07-01T10:09:16+00:00 Presence of package iotop in any version could not be repaired
2020-07-01T10:09:16+00:00    error: Method 'package_state_options' failed in some repairs
2020-07-01T10:09:16+00:00    error: Invalid or missing arguments in package_module body 'zypper':  query_installed_ifelapsed = -678 query_updates_ifelapsed = -678
2020-07-01T10:09:16+00:00    error: New package promise failed sanity check.
2020-07-01T10:09:16+00:00    error: Invalid or missing arguments in package_module body 'zypper':  query_installed_ifelapsed = -678 query_updates_ifelapsed = -678
2020-07-01T10:09:16+00:00    error: New package promise failed sanity check.
2020-07-01T10:09:16+00:00    error: Invalid or missing arguments in package_module body 'zypper':  query_installed_ifelapsed = -678 query_updates_ifelapsed = -678
2020-07-01T10:09:16+00:00    error: New package promise failed sanity check.
2020-07-01T10:09:16+00:00    error: Method 'ncf_package' failed in some repairs
   info          packageManagement         None                      nmap               If you tried to install a virtual package, please use in place the concrete package you want to install.
        [...]
E| error         packageManagement         Package                   nmap               Presence of package nmap in any version could not be repaired

Do you have global parameter rudder defined in rudder?

What do you mean with "global parameter rudder "?

Actions #5

Updated by François ARMAND almost 4 years ago

  • Related to Bug #17875: After migration to 6.1, apt_get fails because of missing `rudder` global parameters added
Actions #6

Updated by François ARMAND almost 4 years ago

In global parameter, you should have one with name `rudder` and json value for the missing parameter of packageManagement technique, as shown here: https://issues.rudder.io/attachments/1706

If it is not the case, you seems to be subjected to the same problem as #17875. Somehow, one file was not correctly updated with upgrade. If it's the case, I will close that one as duplicate to keep information colocated in the other ticket.

Actions #7

Updated by Alexander Brunhirl almost 4 years ago

Unfortunatly it's not the case rudder does contain the proper values {"packages":{"installed_cache_expire":60,"updates_cache_expire":240}} but I assume during the upgrade there was an error see #17895

Actions #8

Updated by Alexander Brunhirl almost 4 years ago

  • Status changed from New to In progress

Like Bug #17895, this was a follow up error from Bug #17873.

Follow up error from #17873; hence I closed it.

Workaround:

rudder:~ # cp /opt/rudder/share/package-scripts/rudder-webapp-postinst .
rudder:~ # vi ./rudder-webapp-postinst
rudder:~ # diff -u /opt/rudder/share/package-scripts/rudder-webapp-postinst ./rudder-webapp-postinst
--- /opt/rudder/share/package-scripts/rudder-webapp-postinst    2020-06-16 16:19:16.000000000 +0200
+++ ./rudder-webapp-postinst    2020-07-01 15:44:42.351803455 +0200
@@ -38,7 +38,7 @@
 fi

 if getent group ncf-api-venv >/dev/null; then
-  groupdel --system ncf-api-venv >> ${LOG_FILE}
+  groupdel ncf-api-venv >> ${LOG_FILE}
 fi

 echo " Done" 
rudder:~ # 
rudder:~ # ./rudder-webapp-postinst false apache2
INFO: Creating groups ... Done
INFO: Creating users ... Done
INFO: Removing ncf-api-venv user and group ... Done
INFO: Setting up systemd ...INFO: Restarting rudder-slapd... Done
INFO: Launching script to check if a migration is needed ...
Done
INFO: Re-generate rudder-lang libraries ...
Done
INFO: Make sure Rudder webapp is started... Done
INFO: Make sure Apache HTTPd is started... Done
rudder:~ #

Actions #9

Updated by François ARMAND almost 4 years ago

  • Related to Bug #17873: SLES12 upgrade error 6.0 to 6.1 added
Actions #10

Updated by François ARMAND almost 4 years ago

  • Status changed from In progress to Rejected

I'm closing that one as a follow-up of #17873 and duplicate of #17875

Actions

Also available in: Atom PDF