8.7.2. Viewing Accumulated Usage Data

Use the oo-admin-usage or oo-admin-ctl-usage command to view resource usage reports per user. Usage reports include how long a user has been using a gear and any additional storage. Red Hat recommends using the oo-admin-usage command for listing a single user's usage data, because it contains more detailed information. Use the oo-admin-ctl-usage command to list all users' basic usage data at one time.
On the broker host, view resource usage per user with the following command, replacing username with the desired value:
# oo-admin-usage -l username

Example 8.6. Viewing a User's Resource Usage

# oo-admin-usage -l user
Usage for user
------------------------------------------
#1
 Usage Type: GEAR_USAGE (small)
    Gear ID: 519262ef6892df43f7000001 (racecar)
   Duration: 3 hours and 19 minutes (2013-05-14 12:14:45 - PRESENT)

#2
 Usage Type: ADDTL_FS_GB (3)
    Gear ID: 5192624e6892dfcb3f00000e (foo)
   Duration: 15 seconds (2013-05-14 12:16:33 - 2013-05-14 12:16:48)

#3
 Usage Type: ADDTL_FS_GB (2)
    Gear ID: 5192624e6892dfcb3f00000e (foo)
   Duration: 3 hours and 17 minutes (2013-05-14 12:16:48 - PRESENT)
The following table provides more information on the output of this command.
Field Description
Usage Type
GEAR_USAGE is related to how long a gear has been in use with the gear size in parentheses.
ADDTL_FS_GB is related to how long additional storage has been in use on a gear with the number of GBs in parentheses.
Gear ID Gear ID indicates the UUID of the relevant gear with the associated application name in parentheses.
Duration Duration indicates the start and end time of the gear (or start time and PRESENT if still in use).
On the broker host, view resource usage for all users with:
# oo-admin-ctl-usage --list

Example 8.7. Viewing Resource Usage for All Users

# oo-admin-ctl-usage --list
Errors/Warnings will be logged to terminal
2013-05-14 15:48:54 -0400 INFO::
---------- STARTED ----------

User: username1
	Gear: 518bcaa26892dfcb74000001, UsageType: GEAR_USAGE, Usage: 23.32543548687111
	Gear: 518bcb876892dfcb74000017, UsageType: GEAR_USAGE, Usage: 23.32543548687111
	Gear: 519254d36892df8f9000000b, UsageType: ADDTL_FS_GB, Usage: 0.05429166666666666
	Gear: 519254d36892df8f9000000b, UsageType: GEAR_USAGE, Usage: 0.08019000000000001
	Gear: 519258d46892df156600001f, UsageType: GEAR_USAGE, Usage: 4.287655764648889
User: username2
	Gear: 5192624e6892dfcb3f00000e, UsageType: ADDTL_FS_GB, Usage: 0.0042325
	Gear: 5192624e6892dfcb3f00000e, UsageType: ADDTL_FS_GB, Usage: 3.5350574313155554
	Gear: 519262ef6892df43f7000001, UsageType: GEAR_USAGE, Usage: 3.5691388202044445
2013-05-14 15:48:54 -0400 INFO::
---------- ENDED, #Errors: 0, #Warnings: 0 ----------
The following table provides more information on the output of this command.
Field Description
User User names the user accumulating the resource usage.
Gear Gear indicates the UUID of the relevant gear.
UsageType
GEAR_USAGE is related to how long a gear has been in use.
ADDTL_FS_GB is related to how long additional storage has been in use on a gear.
Usage Usage lists the duration of the gear (in hours).