Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Last job execution ran 3 months ago. Something seems wrong. #283

Closed
1 task done
LuckierDodge opened this issue Feb 17, 2023 · 4 comments
Closed
1 task done

Comments

@LuckierDodge
Copy link

LuckierDodge commented Feb 17, 2023

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

Background cron job seems to be failing to execute. Noticed a "Last job execution ran 3 months ago. Something seems wrong." warning in Settings->Administration->Basic Settings. Docker logs show the following error every 5 minutes, which I've replicated by running the command directly

root@5890e035c019:/# s6-setuidgid abc php -f /config/www/nextcloud/cron.php
TypeError: OCA\Files_Reader\Hooks::OCA\Files_Reader\{closure}(): Argument #1 ($node) must be of type OCA\Files_Reader\Node, OC\Files\Node\Folder given in /config/www/nextcloud/apps/files_reader/lib/Hooks.php:18
Stack trace:
#0 [internal function]: OCA\Files_Reader\Hooks::OCA\Files_Reader\{closure}()
#1 /config/www/nextcloud/lib/private/Hooks/EmitterTrait.php(106): call_user_func_array()
#2 /config/www/nextcloud/lib/private/Hooks/PublicEmitter.php(40): OC\Hooks\BasicEmitter->emit()
#3 /config/www/nextcloud/lib/private/Files/Node/Root.php(143): OC\Hooks\PublicEmitter->emit()
#4 /config/www/nextcloud/lib/private/Files/Node/Node.php(117): OC\Files\Node\Root->emit()
#5 /config/www/nextcloud/lib/private/Files/Node/Folder.php(387): OC\Files\Node\Node->sendHooks()
#6 /config/www/nextcloud/apps/dav/lib/BackgroundJob/UploadCleanup.php(87): OC\Files\Node\Folder->delete()
#7 /config/www/nextcloud/lib/public/BackgroundJob/Job.php(79): OCA\DAV\BackgroundJob\UploadCleanup->run()
#8 /config/www/nextcloud/lib/public/BackgroundJob/TimedJob.php(95): OCP\BackgroundJob\Job->execute()
#9 /config/www/nextcloud/cron.php(152): OCP\BackgroundJob\TimedJob->execute()
#10 {main}

Expected Behavior

Background jobs are executed by cron every 5 minutes without errors.

Steps To Reproduce

This is a long running instance, so reproduction might be a tad difficult, but:

  1. Create container (see Docker Compose File, below)
  2. Periodically update the container, and run docker exec -it nextcloud updater.phar
  3. Eventually, notice error in nextcloud admin panel
  4. Exec into the container, and run s6-setuidgid abc php -f /config/www/nextcloud/cron.php (taken from the cron file)

Environment

- OS: NixOS 22.05 (Quokka) x86_64
- How docker service was installed: Nix Package

CPU architecture

x86-64

Docker creation

nextcloud:
        image: ghcr.io/linuxserver/nextcloud
        container_name: nextcloud
        environment:
          - PUID=1000
          - PGID=100
          - TZ=America/Detroit
        volumes:
          - /home/luckierdodge/montecarlo-storage/config/nextcloud:/config
          - /home/luckierdodge/montecarlo-storage/data/nextcloud:/data
        ports:
          - 21443:443
        restart: unless-stopped


### Container logs

```bash
s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service 00-legacy: starting
s6-rc: info: service 00-legacy successfully started
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
cont-init: info: running /etc/cont-init.d/01-envfile
cont-init: info: /etc/cont-init.d/01-envfile exited 0
cont-init: info: running /etc/cont-init.d/01-migrations
[migrations] started
[migrations] 01-nginx-site-confs-default: skipped
[migrations] done
cont-init: info: /etc/cont-init.d/01-migrations exited 0
cont-init: info: running /etc/cont-init.d/10-adduser
-------------------------------------
          _         ()
         | |  ___   _    __
         | | / __| | |  /  \
         | | \__ \ | | | () |
         |_| |___/ |_|  \__/
Brought to you by linuxserver.io
-------------------------------------
To support LSIO projects visit:
https://www.linuxserver.io/donate/
-------------------------------------
GID/UID
-------------------------------------
User uid:    1000
User gid:    100
-------------------------------------
cont-init: info: /etc/cont-init.d/10-adduser exited 0
cont-init: info: running /etc/cont-init.d/11-folders
cont-init: info: /etc/cont-init.d/11-folders exited 0
cont-init: info: running /etc/cont-init.d/12-samples
cont-init: info: /etc/cont-init.d/12-samples exited 0
cont-init: info: running /etc/cont-init.d/13-nginx
cont-init: info: /etc/cont-init.d/13-nginx exited 0
cont-init: info: running /etc/cont-init.d/14-php
cont-init: info: /etc/cont-init.d/14-php exited 0
cont-init: info: running /etc/cont-init.d/15-keygen
using keys found in /config/keys
cont-init: info: /etc/cont-init.d/15-keygen exited 0
cont-init: info: running /etc/cont-init.d/20-permissions
cont-init: info: /etc/cont-init.d/20-permissions exited 0
cont-init: info: running /etc/cont-init.d/40-config
cont-init: info: /etc/cont-init.d/40-config exited 0
cont-init: info: running /etc/cont-init.d/50-install
cont-init: info: /etc/cont-init.d/50-install exited 0
cont-init: info: running /etc/cont-init.d/60-memcache
cont-init: info: /etc/cont-init.d/60-memcache exited 0
cont-init: info: running /etc/cont-init.d/70-aliases
cont-init: info: /etc/cont-init.d/70-aliases exited 0
cont-init: info: running /etc/cont-init.d/85-version-checks
**** The following active confs have different version dates than the samples that are shipped. ****
**** This may be due to user customization or an update to the samples. ****
**** You should compare the following files to the samples in the same folder and update them. ****
**** Use the link at the top of the file to view the changelog. ****
/config/nginx/site-confs/default.conf
/config/nginx/nginx.conf
cont-init: info: /etc/cont-init.d/85-version-checks exited 0
cont-init: info: running /etc/cont-init.d/99-custom-files
[custom-init] No custom files found, skipping...
cont-init: info: /etc/cont-init.d/99-custom-files exited 0
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service init-mods: starting
s6-rc: info: service init-mods successfully started
s6-rc: info: service init-mods-package-install: starting
s6-rc: info: service init-mods-package-install successfully started
s6-rc: info: service init-mods-end: starting
s6-rc: info: service init-mods-end successfully started
s6-rc: info: service init-services: starting
s6-rc: info: service init-services successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun cron (no readiness notification)
services-up: info: copying legacy longrun nginx (no readiness notification)
services-up: info: copying legacy longrun php-fpm (no readiness notification)
s6-rc: info: service legacy-services successfully started
s6-rc: info: service 99-ci-service-check: starting
[ls.io-init] done.
s6-rc: info: service 99-ci-service-check successfully started
TypeError: OCA\Files_Reader\Hooks::OCA\Files_Reader\{closure}(): Argument #1 ($node) must be of type OCA\Files_Reader\Node, OC\Files\Node\Folder given in /config/www/nextcloud/apps/files_reader/lib/Hooks.php:18
Stack trace:
#0 [internal function]: OCA\Files_Reader\Hooks::OCA\Files_Reader\{closure}()
#1 /config/www/nextcloud/lib/private/Hooks/EmitterTrait.php(106): call_user_func_array()
#2 /config/www/nextcloud/lib/private/Hooks/PublicEmitter.php(40): OC\Hooks\BasicEmitter->emit()
#3 /config/www/nextcloud/lib/private/Files/Node/Root.php(143): OC\Hooks\PublicEmitter->emit()
#4 /config/www/nextcloud/lib/private/Files/Node/Node.php(117): OC\Files\Node\Root->emit()
#5 /config/www/nextcloud/lib/private/Files/Node/Folder.php(386): OC\Files\Node\Node->sendHooks()
#6 /config/www/nextcloud/apps/dav/lib/BackgroundJob/UploadCleanup.php(87): OC\Files\Node\Folder->delete()
#7 /config/www/nextcloud/lib/public/BackgroundJob/Job.php(79): OCA\DAV\BackgroundJob\UploadCleanup->run()
#8 /config/www/nextcloud/lib/public/BackgroundJob/TimedJob.php(95): OCP\BackgroundJob\Job->execute()
#9 /config/www/nextcloud/cron.php(151): OCP\BackgroundJob\TimedJob->execute()
#10 {main}

(Repeating errors omitted for brevity)

@github-actions
Copy link

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

@LuckierDodge LuckierDodge changed the title [BUG] Last job exectuion ran 3 months ago. Something seems wrong. [BUG] Last job execution ran 3 months ago. Something seems wrong. Feb 17, 2023
@LuckierDodge
Copy link
Author

Unfortunately, this seemingly related issue (very old) was closed without investigation.

@nemchik
Copy link
Member

nemchik commented Feb 17, 2023

This seems to be specific to https://apps.nextcloud.com/apps/files_reader ( Yetangitu/files_reader#1 )

There could be a missing dependency, or the app could be trying to use a php function that does not work in php8. There doesn't seem to be much documentation on the issue, but it's not something we have control over within this repo.

Re: #48 we didn't have enough info to troubleshoot (ex: the logs included here) but it was probably something similar (although maybe not the same app, but likely a compatibility issue with either the version of nextcloud or the version of php).

The two things I could recommend would be to either:

  • uninstall the app (safest option, but you would be without the functionality the app provides - maybe comment on the GitHub issue linked above and see if the dev can address the problem)
  • roll back to a previous version of our image that includes php7.4 (no guarantee this will fix the issue)

I would NOT recommend (and we have no way to support) downgrading nextcloud.

I'm going to close this issue, but if there is new information that could require a change in our container (ex: it is found that we need to supply a particular dependency) please feel free to comment.

@nemchik nemchik closed this as completed Feb 17, 2023
@LuckierDodge
Copy link
Author

Disabling the app fixed the problem, thanks! Didn't even connect "Files_Reader" with the Ebook Reader app.

And no shade intended with the comment about the prior issue, just wanted to make sure it was linked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants