Nextcloud’s occ command (origins from “ownCloud Console”) is Nextcloud’s command-line interface.
You can perform many common server operations with occ, such as installing and upgrading Nextcloud, manage users, encryption, passwords, LDAP setting, and more.
occ is in the nextcloud/ directory; for example /var/www/nextcloud on Raspbian. occ is a PHP script.
You must run it as your HTTP user to ensure that the correct permissions are maintained on your Nextcloud files and directories.