** Description changed:

  [ Impact ]
  After an upgrade from ubuntu-advantage-tools 30.1 to ubuntu-pro-client 31.1, 
an old logrotate conffile named ubuntu-advantage-tools is left behind. The old 
file configures the same files as the new conffile: ubuntu-pro-client.
  The result is that when logrotate runs (on a daily timer) it has an error 
because two configurations for the same log files exist. This results in a 
"degraded" system status.
  
- The fix is to use the `rm_conffile` maintscript to remove the old
+ The fix is to use the `mv_conffile` maintscript to remove the old
  ubuntu-advantage-tools logrotate conffile on upgrade.
  
  [ Test Plan ]
  We added a test to the ubuntu-pro-client integration test suite that covers 
this scenario. It upgrades to the new ubuntu-pro-client and then runs logrotate 
and checks that there are no errors. Because this is covered by the integration 
test suite, this bug will be verified as part of the verification process for 
LP: #2048921.
  
  [ Where problems could occur ]
  Touching conffiles is always risky. It could result in the removal of a 
needed config option or in an unnecessary debconf prompt on upgrade. I tested 
that user modifications were preserved on upgrade, but there is always the 
possibility that something could go wrong.
  
  [ Original Description ]
  Logrotate does not start due to misconfigured Ubuntu Pro:
  
  $ sudo systemctl status logrotate | cat
  × logrotate.service - Rotate log files
       Loaded: loaded (/usr/lib/systemd/system/logrotate.service; static)
       Active: failed (Result: exit-code) since Mon 2024-02-26 15:10:44 CET; 9s 
ago
  TriggeredBy: ● logrotate.timer
         Docs: man:logrotate(8)
               man:logrotate.conf(5)
      Process: 85798 ExecStart=/usr/sbin/logrotate /etc/logrotate.conf 
(code=exited, status=1/FAILURE)
     Main PID: 85798 (code=exited, status=1/FAILURE)
          CPU: 69ms
  
  Feb 26 15:10:44 workstation5 systemd[1]: Starting logrotate.service - Rotate 
log files...
  Feb 26 15:10:44 workstation5 logrotate[85798]: error: ubuntu-pro-client:3 
duplicate log entry for /var/log/ubuntu-advantage-license-check.log
  Feb 26 15:10:44 workstation5 logrotate[85798]: error: found error in file 
ubuntu-pro-client, skipping
  Feb 26 15:10:44 workstation5 systemd[1]: logrotate.service: Main process 
exited, code=exited, status=1/FAILURE
  Feb 26 15:10:44 workstation5 systemd[1]: logrotate.service: Failed with 
result 'exit-code'.
  Feb 26 15:10:44 workstation5 systemd[1]: Failed to start logrotate.service - 
Rotate log files.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2055046

Title:
  ubuntu-pro-client:3 duplicate log entry for /var/log/ubuntu-advantage-
  license-check.log

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-advantage-tools/+bug/2055046/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to