此内容没有您所选择的语言版本。

2.3. The rhqctl Control Script


JBoss Operations Network has a control script which is used for basic lifecycle management for the server and storage nodes. It can open a server console, start and stop an instance, and install or upgrade components.
The rhqctl script has subcommands and options:
rhqctl [command] [[options]
Copy to Clipboard Toggle word wrap
The option usually specifies what local instance to perform the task on, --server, --agent, or --storage.

Example 2.1. Installing Specific Services

The install command configures the JBoss ON server, storage node, and agent all at the same time.
While it is recommended that all three management services be run on the same system (and from the same parent directory), there may be some environments where it is beneficial to run the JBoss ON server on a separate machine from the storage node. In other cases, it may be required to install the different services at different times.
The install command has options for each service. If that option is used, the only that service is installed; the other services are excluded.
For example, this installs the server, storage node, and agent in three separate command invocations:
[root@server bin]# ./rhqctl install --storage --start
[root@server bin]# ./rhqctl install --server --start
[root@server bin]# ./rhqctl install --agent --start
Copy to Clipboard Toggle word wrap
After a server or a node is installed, the rhqctl command is used to start and stop the instance, so start/stop commands are the most common ones to use. Running a command with no options runs that command for all JBoss ON instances on the system.
[root@server bin]# ./rhqctl start
Copy to Clipboard Toggle word wrap
Using an option runs that command only for that instance.
[root@server bin]# ./rhqctl start --server --agent
Copy to Clipboard Toggle word wrap
Expand
Table 2.5. rhqctl Command
Command Description
console Starts a server or storage node in the foreground rather than as a service.
install Installs a server, storage node, or agent instance.
restart Restarts a JBoss ON service. If the type of service is not specified, then all local services are restarted.
start Starts a JBoss ON service. If the type of service is not specified, then all local services are started.
status Shows the status of a JBoss ON service. If the type of service is not specified, then the status of all local services is displayed.
stop Stops a JBoss ON service. If the type of service is not specified, then all local services are stopped.
upgrade Upgrades all JBoss ON services. This can be rerun to migrate historical metric data after a server migration.
Expand
Table 2.6. rhqctl Options
Option Description Commands That Allow It
--start Starts all services.
  • upgrade
  • install
--server Runs the given command for the local server. If this is specified, then the command only is run for the server, and the other components are ignored (unless they are explicitly mentioned).
  • console
  • restart
  • start
  • stop
  • status
  • install
--agent Runs the given command for the agent. If this is specified, then the command only is run for the agent, and the other components are ignored (unless they are explicitly mentioned).
  • restart
  • start
  • stop
  • status
  • install
--storage Runs the given command for the storage database node. If this is specified, then the command only is run for the storage database node, and the other components are ignored (unless they are explicitly mentioned).
  • console
  • restart
  • start
  • stop
  • status
  • install
--storage-data-root-dir directory Changes the directory where the storage data are stored. By default, the storage node directory is serverRoot/jon-server-3.3.0.GA/rhq-data/.
  • install
--from-server-dir directory Gives the directory path to the server to be upgraded.
  • upgrade
--from-agent-dir directory Gives the directory path to the agent to be upgraded. The upgrade script assumes that the agent is installed in the same directory as the server, in a subdirectory named rhq-agent/. This option is required if the agent is in a different location.
  • upgrade
--run-data-migrator Migrates the data from an existing JBoss ON SQL database into a new monitoring storage database. The upgrade command creates the monitoring database. If this option is not used, any previous monitoring data are lost.
  • upgrade
返回顶部
Red Hat logoGithubredditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。 了解我们当前的更新.

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

Theme

© 2025 Red Hat