Using OCC How to invoke?

Hi @cajuncoding

I just wanted to add that the app OCC Web was depracted and can lead to problems with long running OCC commands.

https://git.adphi.net/adphi/occweb

On the actual topic: I’m not familiar with Unraid, but found this with a quick search…

@bb77

Thanks for the heads up. Luckily it did work for me as all my scripts ran quickly (couple seconds).

As I mentioned in my message above, I was able to access and run occ but it required a user that can also be used via sudo, and that’s when I kept getting errors for various users I tried saying they “are not a member of sudoers…”, which is not something I found many details on quickly.

I found this thread before I solved that problem.

Of course any insight on that error may help future users.

thanks, you saved my ass!

Thank you for this tip

I I created an account specifically to thank you for the post. As already mentioned, this is the only place on the entire web to find this solution.

1 Like
  • in unraid Nextcloud runs in a docker container

  • You can not use the OCC commands directly in unraid’s terminal, you need to inject them into that docker. To do this, go to the DOCKER page in unraid and remember your nextcloud container name, mine is ‘nextcloud’:

  • use the command docker exec -it [YourNextcloudDockerNameHere] occ [YourOccCommandHere]

  • Let’s say you want to add the missing db tables after installation and your nextcloud container is named ‘nextclou’ in your docker page in unraid, you would enter this in unraid’s terminal: docker exec -it nextcloud occ db:add-missing-indices

That’s all what’s needed to use nextcloud’s occ commands in unraid.

Have fun,
Gekko