Questo contenuto non è disponibile nella lingua selezionata.
Chapter 9. Command Reference
9.1. Broker Administration Commands Copia collegamentoCollegamento copiato negli appunti!
openshift-origin-broker
and openshift-origin-broker-util
RPMs.
9.1.1. oo-accept-broker Copia collegamentoCollegamento copiato negli appunti!
PASS
and exits with return code 0. With the -v
option added, it displays the current checks that are being performed.
Example 9.1. Checking For Errors With oo-accept-broker
9.1.2. oo-accept-systems Copia collegamentoCollegamento copiato negli appunti!
PUBLIC_HOSTNAME
and PUBLIC_IP
configuration settings are globally valid and unique. It also checks the cartridges installed on the nodes and the status of the broker's cache. It is run without options on the broker host.
PASS
and exits with return code 0. With the -v
option added, it displays the current checks that are being performed.
Example 9.2. Checking For Errors With oo-accept-systems
9.1.3. oo-admin-chk Copia collegamentoCollegamento copiato negli appunti!
-v
option added, it displays the current checks that are being performed.
Example 9.3. Checking For MongoDB Consistency with oo-admin-chk
-l
option added, additional levels of checks can be included:
oo-admin-chk -l 1 -v
# oo-admin-chk -l 1 -voo-admin-chk -l 1 -voo-admin-chk -l 1 -v
9.1.4. oo-admin-clear-pending-ops Copia collegamentoCollegamento copiato negli appunti!
oo-admin-clear-pending-ops
removes stuck user operations from the application queue, so that they no longer hold up the queue preventing other operations from proceeding on that application.
oo-admin-clear-pending-ops [options]
oo-admin-clear-pending-ops [options]oo-admin-clear-pending-ops [options]oo-admin-clear-pending-ops [options]
Option | Description |
---|---|
-t , --time n |
Deletes pending operations older than n hours. (Default:
1 )
|
-u , --uuid uuid | Prunes only applications with the given UUID. |
Note
oo-admin-clear-pending-ops
command directly. It is most commonly run automatically by the ose-upgrade
tool as part of the upgrade process described in the OpenShift Enterprise Deployment Guide. This ensures the database is in a consistent state before data migrations happen.
9.1.5. oo-admin-console-cache Copia collegamentoCollegamento copiato negli appunti!
oo-admin-console-cache
command manages the Management Console Rails application's cache.
oo-admin-console-cache [-c | --clear] [-q | --quiet]
oo-admin-console-cache [-c | --clear] [-q | --quiet]
Option | Description |
---|---|
-c , --clear |
Removes all entries from the Management Console Rails application's cache.
|
-q , --quiet | Shows as little output as possible. |
9.1.6. oo-admin-broker-auth Copia collegamentoCollegamento copiato negli appunti!
AUTH_SALT
is changed in /etc/openshift/broker.conf
, restart the broker service and run the oo-admin-broker-auth
command to recreate authentication tokens for all applicable gears.
oo-admin-broker-auth
# oo-admin-broker-auth
9.1.7. oo-admin-broker-cache Copia collegamentoCollegamento copiato negli appunti!
oo-admin-broker-cache --clear
# oo-admin-broker-cache --clear
9.1.8. oo-admin-ctl-app Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-app
# oo-admin-ctl-app
The HAProxy multiplier sets the ratio of how many HAproxy cartridges are enabled for application scaling. Setting the multiplier number to 2
means that for every two gears, one will have HAProxy enabled. Alternatively, you can set the minimum and maximum number of HAProxy cartridges allowed in scaling.
oo-admin-ctl-app
command with the --multiplier
option.
oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2
# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2# oo-admin-ctl-app -l username -a appname --cartridge haproxy-1.4 -c set-multiplier --multiplier 2
9.1.9. oo-admin-ctl-authorization Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-authorization -c expire
# oo-admin-ctl-authorization -c expire
oo-admin-ctl-authorization -c revoke_all
# oo-admin-ctl-authorization -c revoke_all
9.1.10. oo-admin-ctl-district Copia collegamentoCollegamento copiato negli appunti!
9.1.11. oo-admin-ctl-domain Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-domain
# oo-admin-ctl-domain
9.1.12. oo-admin-ctl-region Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-region
command is used to create, list, or destroy regions and add or remove zones within a given region.
9.1.13. oo-admin-ctl-team Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-team
tool manages global teams and is invoked with a set of commands using the -c
or --command
option:
oo-admin-ctl-team -c command [options]
oo-admin-ctl-team -c command [options]oo-admin-ctl-team -c command [options]oo-admin-ctl-team -c command [options]oo-admin-ctl-team -c command [options]oo-admin-ctl-team -c command [options]
Command | Description |
---|---|
list |
Lists all teams.
|
create |
Creates a new team. Requires either both the
--name and --maps-to options, or both the --groups and --config-file options. For example:
oo-admin-ctl-team create --name team_name --maps-to group_name
Alternatively:
oo-admin-ctl-team create --groups group_name_1,group_name_2 --config-file file_name
|
update | Updates an existing team LDAP correspondance. Requires both the --name and --maps-to options. |
delete | Deletes a team. Requires the --name option. |
show | Displays a team and its members. Requires either the --name or --maps-to option. |
sync | Syncs global teams with the LDAP groups. Requires the --config-file option. |
sync-to-file | Generates a sync file for review. No changes are made to the teams and their members. Requires the --out-file and --config-file options. |
sync-from-file | Syncs from a file. Requires the --in-file option. |
Option | Description |
---|---|
--broker path |
Specifies the path to the broker.
|
--create-new-users | Creates new users in OpenShift if they do not exist. |
--remove-old-users | Removes members from a team that are no longer in the group. |
9.1.14. oo-admin-ctl-usage Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-usage
displays usage data for all users. The output includes user names, gears, usage type and duration.
oo-admin-ctl-usage --list [--enable-logger]
oo-admin-ctl-usage --list [--enable-logger]
Option | Description |
---|---|
--list |
List usage data.
|
--enable-logger | Print error and warning messages to the log file instead of to the terminal. |
--list
option.
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). |
9.1.15. oo-admin-ctl-user Copia collegamentoCollegamento copiato negli appunti!
Option | Description |
---|---|
-l, --login Username |
Login name for an OpenShift Enterprise user account. Required unless
-f is used.
|
-f, --logins-file File_Name |
File containing one login name per line. Required unless
-l is used.
|
-c, --create |
Create user account(s) for the specified login name(s) if they do not already exist.
|
--setmaxdomains Number |
Set the maximum number of domains a user is allowed to use.
|
--setmaxgears Number |
Set the maximum number of gears a user is allowed to use.
|
--setmaxteams Number | Set the maximum number of teams a user is allowed to create. |
--allowviewglobalteams true|false | Add or remove the capability for a user to search and view any global team. |
--allowprivatesslcertificates true|false | Add or remove the capability for a user to add private SSL certificates. |
--addgearsize Gear_Size | Add a gear size to the capabilities for a user. |
--removegearsize Gear_Size | Remove a gear size from the capabilities for a user. |
--allowha true|false | Allow or disallow the high-availability applications capability for a user. |
-q, --quiet | Suppress non-error output. |
-h, --help | Show usage information. |
oo-admin-ctl-user
command:
- See Section 2.4, “Enabling Support for High-Availability Applications” for more information on the high-availability applications capability.
- See Section 3.1, “Creating a User” for more information on creating users.
- See Section 4.1, “Setting the Maximum Number of Teams for Specific Users” and Section 4.2.2, “Enabling Global Team Visibility” for more information on team options.
- See Section 6.1, “Adding or Modifying Gear Profiles” for more information on modifying gear size capabilities.
- See Section 6.7, “Setting Gear Quotas and Sizes for Specific Users” for more information on setting gear quotas.
- See Section 8.7.1, “Setting Tracked and Untracked Storage” for more information on setting maximum tracked and untracked storage per gear.
9.1.16. oo-admin-move Copia collegamentoCollegamento copiato negli appunti!
rsync_id_rsa
private key in the broker host's /etc/openshift/
directory and the public key in each node host's /root/.ssh/authorized_keys
file as explained in the OpenShift Enterprise Deployment Guide at https://access.redhat.com/site/documentation. A gear retains its UNIX UID when moved, therefore cross-district moves are only allowed when the destination district has the same gear UID available.
oo-admin-move
command on the broker host, specifying the desired gear's UUID and the node host you wish to move the gear to:
Example 9.4. Moving a Gear From One Node to Another
oo-admin-move --gear_uuid 3baf79139b0b449d90303464dfa8dd6f -i node2.example.com
# oo-admin-move --gear_uuid 3baf79139b0b449d90303464dfa8dd6f -i node2.example.com
9.1.17. oo-admin-repair Copia collegamentoCollegamento copiato negli appunti!
--help
output for additional uses.
oo-admin-repair
# oo-admin-repair
9.1.18. oo-admin-upgrade Copia collegamentoCollegamento copiato negli appunti!
oo-admin-upgrade
command usage.
Important
oo-admin-upgrade
tool is also often required when applying asynchronous errata updates provided by Red Hat for OpenShift Enterprise. See the latest OpenShift Enterprise Deployment Guide at https://access.redhat.com/site/documentation for usage instructions as it applies to these types of updates.
9.1.19. oo-admin-usage Copia collegamentoCollegamento copiato negli appunti!
oo-admin-usage
command displays a resource usage report for a particular user, or aggregated usage data of all users. The output includes usage type, gear ID, and duration.
oo-admin-usage [-l username] [options]
oo-admin-usage [-l username] [options]oo-admin-usage [-l username] [options]oo-admin-usage [-l username] [options]oo-admin-usage [-l username] [options]oo-admin-usage [-l username] [options]
-l
username is omitted, the command displays aggregated data on all users.
Option | Description |
---|---|
-a , --app application_name |
Filters usage data by the given application name.
|
-g , --gear gear_id | Filters usage data by the given gear ID. |
-s , --start start_date | Filters usage data by the given start date, expressed as ISO dates (YYYY-MM-DD). |
-e , --end end_date | Filters usage data by the given end date, expressed as ISO dates (YYYY-MM-DD). |
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). |
9.1.20. oo-admin-ctl-cartridge Copia collegamentoCollegamento copiato negli appunti!
oo-admin-ctl-cartridge
command facilitates cartridge management on the broker, including importing cartridge manifests from nodes and activating or deactivating cartridges. This command must be used to ensure that newly installed or updated cartridges can be used in applications.
Note
9.1.21. oo-register-dns Copia collegamentoCollegamento copiato negli appunti!
nsupdate
command. Normally this command is used for broker or node hosts, although it can be used for other infrastructure hosts. Do not use this command to change DNS records for applications and gears, because these are CNAME records.
oo-register-dns
# oo-register-dns