Nextcloud log is flooded with errors

NethServer Version: 7.9.2009 (final)
Module: Nextcloud

hundredts of messages like
/appinfo/app.php is not loaded when \\OCP\\AppFramework\\Bootstrap\\IBootstrap on the application class is used. Migrate everything from app.php to the Application class.

What can I do?

Check updates for the installed Nextcloud apps.
On the same log message line there’s probably a reference to the name of the app(s) throwing the error.

1 Like

there are no apps markd fpr updates.
there alre already over 4000 lines in the logfile.
I extracted the apps from the Logfile:

app:“support”
app:“federation”
app:“lookup_server_connector”
app:“password_policy”
app:“user_ldap”
app:“files”
app:“activity”
app:“admin_audit”
app:“cloud_federation_api”
app:“comments”
app:“dav”
app:“files_trashbin”
app:“files_versions”
app:“text”
app:“firstrunwizard”
app:“nextcloud_announcements”
app:“notifications”
app:“sharebymail”
app:“systemtags”
app:“workflowengine”
app:“accessibility”
app:“federatedfilesharing”
app:“files_pdfviewer”
app:“files_rightclick”
app:“files_videoplayer”
app:“logreader”
app:“photos”
app:“recommendations”
app:“survey_client”
app:“twofactor_backupcodes”
app:“updatenotification”
app:“viewer”
app:“PHP”
app:“no app in context”
app:“core”

If those are debug messages (but maybe they are at the Error level), on /usr/share/nextcloud/config/config.php you can increase the log level to 1 or 2, for instance.

"loglevel" => 2,

Another way to see the log level:

occ log:manage

What nextcloud version?

occ -V
grep "'version'" /usr/share/nextcloud/config/config.php

Here’s more info on the error:

Edit:
You can verify what apps are affected searching for app.php files:

find /usr/share/nextcloud/apps/ -name app.php |sort
2 Likes

loglevel ist 2:

occ log:manage
Enabled logging backend: file
Log level: Warning (2)

Version:

occ -V
Nextcloud 21.0.2

grep “‘version’” /usr/share/nextcloud/config/config.php
‘version’ => ‘21.0.2.1’,

Apps:

find /usr/share/nextcloud/apps/ -name app.php |sort
/usr/share/nextcloud/apps/accessibility/appinfo/app.php
/usr/share/nextcloud/apps/activity/appinfo/app.php
/usr/share/nextcloud/apps/admin_audit/appinfo/app.php
/usr/share/nextcloud/apps/audioplayer_editor/appinfo/app.php
/usr/share/nextcloud/apps/cloud_federation_api/appinfo/app.php
/usr/share/nextcloud/apps/comments/appinfo/app.php
/usr/share/nextcloud/apps/contacts/appinfo/app.php
/usr/share/nextcloud/apps/dav/appinfo/app.php
/usr/share/nextcloud/apps/drawio/appinfo/app.php
/usr/share/nextcloud/apps/encryption/appinfo/app.php
/usr/share/nextcloud/apps/federatedfilesharing/appinfo/app.php
/usr/share/nextcloud/apps/federation/appinfo/app.php
/usr/share/nextcloud/apps/files/appinfo/app.php
/usr/share/nextcloud/apps/files_external/appinfo/app.php
/usr/share/nextcloud/apps/files_pdfviewer/appinfo/app.php
/usr/share/nextcloud/apps/files_rightclick/appinfo/app.php
/usr/share/nextcloud/apps/files_sharing/appinfo/app.php
/usr/share/nextcloud/apps/files_texteditor/appinfo/app.php
/usr/share/nextcloud/apps/files_trashbin/appinfo/app.php
/usr/share/nextcloud/apps/files_versions/appinfo/app.php
/usr/share/nextcloud/apps/files_videoplayer/appinfo/app.php
/usr/share/nextcloud/apps/firstrunwizard/appinfo/app.php
/usr/share/nextcloud/apps/ldap_contacts_backend/appinfo/app.php
/usr/share/nextcloud/apps/logreader/appinfo/app.php
/usr/share/nextcloud/apps/lookup_server_connector/appinfo/app.php
/usr/share/nextcloud/apps/nextcloud_announcements/appinfo/app.php
/usr/share/nextcloud/apps/notifications/appinfo/app.php
/usr/share/nextcloud/apps/password_policy/appinfo/app.php
/usr/share/nextcloud/apps/photos/appinfo/app.php
/usr/share/nextcloud/apps/recommendations/appinfo/app.php
/usr/share/nextcloud/apps/serverinfo/appinfo/app.php
/usr/share/nextcloud/apps/sharebymail/appinfo/app.php
/usr/share/nextcloud/apps/support/appinfo/app.php
/usr/share/nextcloud/apps/survey_client/appinfo/app.php
/usr/share/nextcloud/apps/systemtags/appinfo/app.php
/usr/share/nextcloud/apps/text/appinfo/app.php
/usr/share/nextcloud/apps/theming/appinfo/app.php
/usr/share/nextcloud/apps/twofactor_backupcodes/appinfo/app.php
/usr/share/nextcloud/apps/updatenotification/appinfo/app.php
/usr/share/nextcloud/apps/user_ldap/appinfo/app.php
/usr/share/nextcloud/apps/user_usage_report/appinfo/app.php
/usr/share/nextcloud/apps/viewer/appinfo/app.php

Do you get a list of EXTRA_FILE on the admin settings page?
Can you list the apps version?

occ app:list
occ app:update --all

occ app:list
Enabled:

  • accessibility: 1.7.0
  • activity: 2.14.3
  • admin_audit: 1.11.0
  • audioplayer: 3.1.0
  • audioplayer_editor: 0.3.0
  • calendar: 2.3.0
  • cloud_federation_api: 1.4.0
  • comments: 1.11.0
  • contacts: 3.5.1
  • contactsinteraction: 1.2.0
  • dashboard: 7.1.0
  • dav: 1.17.1
  • drawio: 1.0.1
  • federatedfilesharing: 1.11.0
  • federation: 1.11.0
  • files: 1.16.0
  • files_external: 1.12.0
  • files_pdfviewer: 2.1.0
  • files_rightclick: 1.0.0
  • files_sharing: 1.13.1
  • files_texteditor: 2.14.0
  • files_trashbin: 1.11.0
  • files_versions: 1.14.0
  • files_videoplayer: 1.10.0
  • firstrunwizard: 2.10.0
  • ldap_contacts_backend: 1.0.1
  • logreader: 2.6.0
  • lookup_server_connector: 1.9.0
  • nextcloud_announcements: 1.10.0
  • notifications: 2.9.0
  • oauth2: 1.9.0
  • password_policy: 1.11.0
  • photos: 1.3.0
  • privacy: 1.5.0
  • provisioning_api: 1.11.0
  • recommendations: 1.0.0
  • serverinfo: 1.11.0
  • settings: 1.3.0
  • sharebymail: 1.11.0
  • support: 1.4.0
  • survey_client: 1.9.0
  • systemtags: 1.11.0
  • text: 3.2.0
  • twofactor_backupcodes: 1.10.0
  • updatenotification: 1.11.0
  • user_ldap: 1.11.0
  • user_status: 1.1.1
  • user_usage_report: 1.5.0
  • viewer: 1.5.0
  • weather_status: 1.1.0
  • workflowengine: 2.3.0
    Disabled:
  • bruteforcesettings
  • encryption
  • theming

I don’t see any list on the admin settings page. Where exactly to look at?

Logged in with Nextcloud’s admin user: Admin > Settings > Administration > Overview
Under Security & Setup Warnings (opening the “List of invalid files…” link, if any)

it says:

Eine neue Version ist verfügbar: Nextcloud 21.0.3
Für alle Apps steht eine Aktualisierung zur Verfügung

Für diese Apps gibt es Aktualisierungen

After clicking on open updater :

Do not run the manual updater inside Nextcloud.

ok,
it’s not working anyway :smiley:

Can you locate and post the log from the last nextcloud update (in /var/log/messages) to see if there was some issue during the upgrade?

Probably won’t fix it, but can you run these commands?

occ upgrade
signal-event nethserver-nextcloud-update

To solve the log flooding we might need to manually delete those extra app.php files (or uninstall/reinstall the apps, but some are core apps that can/should not be removed).

I could run these command, but nothing happend.

in the logs i found:

grep nextcloud messages*
messages:Jul 4 22:44:38 home2 scl: Database MariaDB is probably initialized in /var/opt/rh/rh-mariadb105/lib/mysql-nextcloud already, nothing is done.
messages:Jul 4 22:44:38 home2 scl: If this is not the case, make sure the /var/opt/rh/rh-mariadb105/lib/mysql-nextcloud is empty before running mysql-prepare-db-dir.
messages-20210425:Apr 21 04:08:06 home2 collectd[15901]: rrdtool plugin: rrd_update_r (/var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-free.rrd) failed: /var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-free.rrd: illegal attempt to update using time 1618970756 when last update time is 1618970756 (minimum one second step)
messages-20210425:Apr 21 04:08:06 home2 collectd[15901]: rrdtool plugin: rrd_update_r (/var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-reserved.rrd) failed: /var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-reserved.rrd: illegal attempt to update using time 1618970756 when last update time is 1618970756 (minimum one second step)
messages-20210425:Apr 21 04:08:06 home2 collectd[15901]: rrdtool plugin: rrd_update_r (/var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-used.rrd) failed: /var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-used.rrd: illegal attempt to update using time 1618970756 when last update time is 1618970756 (minimum one second step)
messages-20210516:May 14 17:22:59 home2 collectd[3660]: rrdtool plugin: rrd_update_r (/var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-free.rrd) failed: /var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-free.rrd: illegal attempt to update using time 1621005750 when last update time is 1621005750 (minimum one second step)
messages-20210516:May 14 17:22:59 home2 collectd[3660]: rrdtool plugin: rrd_update_r (/var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-reserved.rrd) failed: /var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-reserved.rrd: illegal attempt to update using time 1621005750 when last update time is 1621005750 (minimum one second step)
messages-20210516:May 14 17:22:59 home2 collectd[3660]: rrdtool plugin: rrd_update_r (/var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-used.rrd) failed: /var/lib/collectd/rrd/home2.nemenz.at/df-var-lib-nethserver-nextcloud/df_complex-used.rrd: illegal attempt to update using time 1621005750 when last update time is 1621005750 (minimum one second step)

The scanner is running for long time now but there are no results. just a turning circle

OK. Let’s wait. Maybe it detects many hits (files).

Almost the same scan can be done from the command line with:

occ integrity:check-core
occ app:list | awk 'NF > 1 {gsub(":","",$2); print $2}' | xargs -I{} -r -n1 sh -c 'echo {}; occ integrity:check-app {};'
Result of second command
  - INVALID_HASH:
    - js/files_pdfviewer-main.js:
      - expected: 6a953365de5d539b198c74e479b868e4c26397ca0c7a69d01ae64d28939b295319670030c5680c96dd446701d0f962dd0ace561a5daf3fc252e77ebb7ec9df0d
      - current: 67a03fd7c6f24b3addfe56388c03a77a3dd8b7e4ecc9df3d041c0ede62dcc8ee5e5b5410840fba052d16bd4396aa5331f5137c5b09507b42c1fe6020b2f1ffc0

Result is expected as NethServer applied a patch to fix the pdfviewer.

this was quite a long output. both command are like 1927 lines of text.

from the first (just some random lines:

- settings/js/settings.js:
 - expected: 
- current: >130e7515e2cf6639d52a02765c77a6280433748293cbee0333d5e1a8050f32c251add3a2fc1e72ca15d24a7399df293919368f44c9a8b24e399c0720c8ebc6a0
  • settings/js/certificates.js:
    • expected:
    • current: >26cd9da54a085dbab00dbce05ed621952bc5fbc0fbada96589212b967b22ec29092b75b0898c455d5ca8a199beb654c2b8d97a0242159a7f36f75e55c433ac8a
  • settings/js/log.js:
    - expected:
    • current: e15d7f6c07948ec32c4d662629b631a9bc1fb9031f50bdf66ab6028698d40b46a5d0f9173df4ccf45ed07d9>ce36e063ae8140eac90fa508d40641f26c4de0dc5

and from the 2nd sommand:

text

  • EXTRA_FILE:
    • js/vendors~editor-rich~files-modal.js:
      • expected:
      • current: >0ac20f20170b68f272a8e9bd4cbcdf6ed04cfdf7b8b23dea64c473d6926531f9ab3f615d4b729e5fbf9b04307c09ad8da377d6094146dee40e6c3bb37fbf905c
    • js/vendors~editor-rich~files-modal.js.map:
      • expected:
      • current: db4f5a292d9df83fede2413bb51ba13f799b026d726703004269897a7946a0f5a7b17d8c7d822a016c39831b5ad0cc2285d6b842c573f234a5010d05135612d4
    • appinfo/app.php:
      • expected:
      • current: 31af99d5ed704834b4f683a35dc6527741cb58086dd54037ac5861159f29f8a2648e68466c6355e60044a035b89f613ca803fd6ea7e6f71df1a81cea34839648

Since I can’t upload right now on my nextcloud I’m not sure how to share the whole file with you

You may use a gist or some soft of pastebin.

It looks like all apps have a empty line in expected.

If expected is empty it shall mean the files is unexpected (so doesn’t have a computed hash to compare to). From my point of view they are safe to remove (you can make a copy of them or the whole directory somewhere else if you want to).

Do not erase the one with INVALID_HASH (js/files_pdfviewer-main.js)

For the apps that have InvalidSignatureException or Signature data not found (calendar, drawio, files_texteditor, ldap_contacts_backend) you can keep them as they have probably not implemented the code signing validation (or remove the ones that have a remove option and install them again if they are of use).

2 Likes

thank you after deleting unnecessary files the log looks much better.

There is a new problem since yesterday: I cant access any files nor can I upload any new files