• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved 17 -> 18 autoupdate failed: files list file for package 'libopenjp2-7:amd64' is missing final newline

morog

New Pleskian
Plesk attempted an auto-update last night, and failed. The relevant line in the log reads:

Code:
...
(Reading database ... 95%
dpkg: unrecoverable fatal error, aborting:
 files list file for package 'libopenjp2-7:amd64' is missing final newline
E: Sub-process /usr/bin/dpkg returned an error code (2)
(several dozen garbage characters)
Downloading file report-update: 0%
...


After logging into Plesk, I'm greeted with a server error:

Code:
500 Zend_Controller_Response_Exception
Cannot send headers; headers already sent in /opt/psa/admin/plib/modules/revisium-antivirus/hooks/Permissions.php, line 1
Type        Zend_Controller_Response_Exception
Message     Cannot send headers; headers already sent in /opt/psa/admin/plib/modules/revisium-antivirus/hooks/Permissions.php, line 1
File        Abstract.php
Line        323


plesk repair fs -verbose returns:

Code:
There are incorrect permissions on some items: /var/www/vhosts  [ERROR]
    - fsmng failed: dpkg-query: unrecoverable fatal error,
      aborting:
       files list file for package 'libopenjp2-7:amd64' is
      missing final newline
      ERROR:Command '['/usr/bin/dpkg', '-S', '/var/www/vhosts']'
      returned non-zero exit status 2
  Do you want to repair incorrect permissions? [Y/n] y
    Repairing incorrect permissions ............................. [2020-07-20 15:20:32.291] ERR [util_exec] proc_close() failed ['/opt/psa/admin/bin/fsmng' '--set-ac' '/var/www/vhosts'] with exit code [1]
[FAILED]
    - fsmng failed: dpkg-query: unrecoverable fatal error,
      aborting:
       files list file for package 'libopenjp2-7:amd64' is
      missing final newline
      ERROR:Command '['/usr/bin/dpkg', '-S', '/var/www/vhosts']'
      returned non-zero exit status 2


plesk repair installation doesn't repair anything.

plesk version returns:

Code:
Product version: Plesk Obsidian 18.0.28.2
     OS version: Debian 8.11 x86_64
     Build date: 2020/07/03 14:00
       Revision: 3e2c0bdf6dc81e82d4bc5d0b128b12fbfbf5b89f


Database, etc seems to be fine, the actual website is running without issue, but Plesk seems a bit borked.

I'd be grateful for any direction in resolving this.
 
Try to fix it with

# rm /var/lib/dpkg/info/libopenjp2*
# dpkg --configure -a
# apt update
# apt upgrade

After that run Plesk update fix with:

# plesk installer --select-release-current --reinstall-patch --upgrade-installed-components
 
Thanks, Igor. No luck, though — I still get the above 500 Zend_Controller_Response_Exception error after logging in, although the files list file for package 'libopenjp2-7:amd64' is missing final newline error seems to be gone and repair fs can successfully run now.
 
I still get the above 500 Zend_Controller_Response_Exception error
It is related to Revisium Antivirus extension. Try to remove it in CLI:

# plesk bin extension --uninstall revisium-antivirus
 
Back
Top