Maintenance Commands

Introduction

There are commands availabe to maintain the Infinite Scale instance. This document gives an overview of the available commands and links to the related services where they are implemented for more details.

  • Calling a service in the examples is made via the single binary.

  • Generic call:
    ocis <service name> arguments options.

  • This changes if some services are available as executable on their own, then it would be:
    <service name> arguments options.
    This could happen if services are developed which are not shipped as part of the single binary.

Changed CLI Commands

CLI commands can get added, changed or removed between versions. See the Changed or Added CLI Commands document for details.

Offline Commands

Compared to online commands that need to be issued during operation of Infinite Scale, offline commands can, and somtimes must only be issued if Infinite Scale is not running.

Common Path Parameter

Infinite Scale offers a variety of offline CLI commands to monitor or repair Infinite Scale installations. Many of these commands have a common mandatory parameter: --basePath (or -p) which needs to point to a storage provider. Example paths are:

$HOME/.ocis/storage/users    # bare metal deployment

/var/lib/ocis/storage/users  # docker deployment

...

These paths can vary depending on your Infinite Scale installation, for more information see the Base Data Directory.

Backup Consistency

Infinite Scale provides a CLI command with which you can inspect the consistency of an Infinite Scale storage.

This command MUST only be issued when Infinite Scale is offline and no services are running. This command will report false positives when issued during normal operation.

Reset Password for IDM Users

If you need to reset the password for the admin or a user in the idm service from the command line, follow the Password Reset for IDM Users.

Revisions Cleanup

Infinite Scale provides a CLI command which allows removing revisions of files in the storage.

Service Health

Infinite Scale provides a CLI command checking the health of a service.

Trash Purge

Infinite Scale provides a CLI command with which you can remove empty folders from the trashbin.

Online Only Commands

Compared to offline commands that can be issued when Infinite Scale is shut down, online commands must be issued when Infinite Scale and the respective service(es) are running.

Auth-Tokens

App Tokens are used to authenticate 3rd party access via https like when using curl (apps) to access an API endpoint. These apps need to authenticate themselves, as no logged in user authenticates the request. To be able to use an app token, one must first create a token via the cli. For details see the description in the auth-app service.

Cleanup Orphaned Shares

When a shared space or directory got deleted, use the following CLI command to cleanup those share orphans. This can’t be done automatically at the moment.

Inspect and Manipulate Node Metadata

Infinite Scale provides a CLI command with which you can inspect and manipulate node metadata.

Use this command with absolute care. It is not intended to play around and should only be used on request and under supervision of ownCloud support.

Inspect and Repair Node Tree Sizes

Infinite Scale provides a CLI command with which you can inspect and repair node tree sizes. This command can be necessary in very rare cases where spaces or files are shown in the Web UI with a size not matching reality. For the repair option Infinite Scale must be shut down.

Use this command with absolute care. It is not intended to play around and should only be used on request and under supervision of ownCloud support. === Manage Expired Uploads

Compared to unfinished uploads which are handled by the system, managing expired uploads can be a necessity as those files can pile up, blocking storage resources and need to be removed by command regularly. See the Manage Unfinished Uploads section at the Storage Users service for details.

Purge Expired Space Trash-Bin Items

This command is about purging old trash-bin items of project spaces (spaces that have been created manually) and personal spaces. See the CLI Commands section at the Storage Users service for details.

In rare circumstances, it can be necessary to initiate indexing manually for a given space a user has access to or all spaces. Though the search service handles exception cases automatically, it can happen that the search service was not able to complete indexing due to a dirty shut-down of the service or because of a bug. Re-indexing should only be run on explicit request and supervision by ownCloud support. See the Manually Trigger Re-Indexing Spaces section at the Search service for details.

Repair and Migrate jsoncs3 Indexes

A CLI command is provided to repair and migrate jsoncs3 indexes. In rare circumstances the data for shares from the "Shared with others" and "Shared with me" index can be corrupted though no data is lost. When using this command, you can recreate that index and migrate it to a new layout which fixes the issue.

Use this command with absolute care. It is not intended to play around and should only be used on request and under supervision of ownCloud support.

Resume Post-Processing

If post-processing fails in one step due to an unforeseen error, current uploads will not be retried automatically. A system administrator can instead run a CLI Command to retry the failed upload.

Roll Back / Roll Forward Decomposedfs Migrations

A CLI command is provided to roll back or roll forward a decomposedfs migration.

Use this command with absolute care. It is not intended to play around and should only be used on request and under supervision of ownCloud support.