Commit 23b98153 authored by Julian Bigge's avatar Julian Bigge


parent 7ba73f0f
Pipeline #54095 passed with stage
in 2 minutes and 44 seconds
......@@ -2,6 +2,9 @@
master: [![pipeline status](](
develop: [![pipeline status](](
Sccuot is a commandline tool to retrieve usage and resource information of a ownCloud instance specifically written for the NRW Sync&Share Project. The tool consists a
library, an optional daemon and the cli client application.
## Requirements ##
The following packages are required for sccuot:
......@@ -18,14 +21,6 @@ To build sccuot from source, the project first has to be configured with `CMake`
mkdir build && cd build
### Configuring sccuot for pre C++11-ABI systems (RHEL 6/7 / CentOS 6/7) ###
Building on these systems requires sccuot to be build with non-default C++-ABI. To do so, configure sccuot like the following:
cmake -DUSE_OLD_CXX_ABI=On ..
### Configuring sccuot for static linking ###
Sccuot consists of the sccuot library and client executable. However, sccuot can also be configured to be statically linked,
in which case the client executable has no runtime dependency to the sccuot library. To do so, configure sccuot like this:
......@@ -34,6 +29,14 @@ in which case the client executable has no runtime dependency to the sccuot libr
cmake -DSTATIC_LIB=On ..
### Configure sccuot to build daemon ###
Sccuot can also be build to include a daemon process (sccuotd) which can be contacted via a unix domain or tcp socket. If
you wish to build the daemon you have to include:
cmake -DDAEMON=On ..
### Building ###
After sccuot is configured it has to be build:
......@@ -48,5 +51,49 @@ To install sccuot on your system, use
# make install
This is not necessary if you just use the statically linked client application. In the other case, the library and header files must
be detectable by the system.
This is not necessary if you just use the statically linked client application.
## Usage ##
Sccuot can be used the acquire the following metrics:
* the overall used disc space of the instance: `used_space`
* the used disc space per individual user: `used_space_user`
* the number of user files: `count_files`
* the number of specific file types: `count_file_type`
* you can provide a comma-seperated list of file extensions as parameters
* the number of users: `count_users`
* the number of shares: `count_shares`
* the number of federated shares: `count_ext_shares`
* the number of created share links: `count_links`
* the number of shared files: `count_shared_files`
* the number of shared directories: `count_shared_dirs`
* the quota usage per individual user in percent: `quota_users`
* the number of active users in the last 24 hours, week, month and quarter of the year: `count_active_users`
* you can provide either `daily`, `weekly`, `monthly` or `quarter` as parameter
You can have a look at all available options for sccuot at any time using `sccuot --help`.
Sccuot gets the data directly from the database used also by the ownCloud instance, so login credentials for the database are required. The corresponding cli options are:
-s [ --server ] arg (=localhost) hostname to connect to
--port arg (=3306) port to connect to
-u [ --user ] arg (=root) username to connect to database server with
-p [ --passwd ] arg user's database password
-d [ --db ] arg (=owncloud) identifier of the database to open
Provided the login credentials, you can use one of the above mentioned metric templates. To provide addiotional parameters to the `count_file_type` and `count_active_users` template, you can use `--param`.
### Output format ###
Per default, sccout will output the result of the query in a human readable form. However you can also use the `--format` option to let sccuot output the results in the desired format. Currently supported output formats are:
* CSV: `csv`
* JSON: `json`
### Unit translation ###
Sccuot will output any file sizes in bytes per default. You can override this behaviour by providing the `--unit` command line option. Possible values are:
* `b`
* `kb`
* `mb`
* `gb`
* `tb`
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment