このコンテンツは選択した言語では利用できません。
Chapter 9. How to…
The following CLI commands and operations provide basic examples on how to accomplish certain tasks. For detailed instructions, see the appropriate section of the Configuration Guide or other JBoss EAP guide.
Unless specified otherwise, the examples apply when running as a standalone server. Use the --help argument on a command to get usage for that command. Use the read-operation-description to get information on a particular operation for a resource.
9.1. Add a Datasource リンクのコピーリンクがクリップボードにコピーされました!
data-source add --name=DATASOURCE_NAME --jndi-name=JNDI_NAME --driver-name=DRIVER_NAME --connection-url=CONNECTION_URL
data-source add --name=DATASOURCE_NAME --jndi-name=JNDI_NAME --driver-name=DRIVER_NAME --connection-url=CONNECTION_URL
9.2. Add a JMS Queue リンクのコピーリンクがクリップボードにコピーされました!
jms-queue add --queue-address=QUEUE --entries=java:/jms/queue/QUEUE
jms-queue add --queue-address=QUEUE --entries=java:/jms/queue/QUEUE
9.3. Add a JMS Topic リンクのコピーリンクがクリップボードにコピーされました!
jms-topic add --topic-address=TOPIC --entries=java:/jms/topic/TOPIC
jms-topic add --topic-address=TOPIC --entries=java:/jms/topic/TOPIC
9.4. Add a Module リンクのコピーリンクがクリップボードにコピーされました!
module add --name=MODULE_NAME --resources=PATH_TO_RESOURCE --dependencies=DEPENDENCIES
module add --name=MODULE_NAME --resources=PATH_TO_RESOURCE --dependencies=DEPENDENCIES
Using the module management CLI command to add and remove modules is provided as technology preview only. This command is not appropriate for use in a managed domain or when connecting to the management CLI remotely. Modules should be added and removed manually in a production environment. For more information, see the Create a Custom Module Manually and Remove a Custom Module Manually sections of the JBoss EAP Configuration Guide.
9.5. Add a Server リンクのコピーリンクがクリップボードにコピーされました!
Add a new server to a host in a managed domain.
/host=HOST_NAME/server-config=SERVER_NAME:add(group=SERVER_GROUP_NAME)
/host=HOST_NAME/server-config=SERVER_NAME:add(group=SERVER_GROUP_NAME)
9.6. Add a Server Group リンクのコピーリンクがクリップボードにコピーされました!
Add a new server group in a managed domain.
/server-group=SERVER_GROUP_NAME:add(profile=PROFILE_NAME, socket-binding-group=SOCKET_BINDING_GROUP_NAME)
/server-group=SERVER_GROUP_NAME:add(profile=PROFILE_NAME, socket-binding-group=SOCKET_BINDING_GROUP_NAME)
9.7. Add a System Property リンクのコピーリンクがクリップボードにコピーされました!
/system-property=PROPERTY_NAME:add(value=PROPERTY_VALUE)
/system-property=PROPERTY_NAME:add(value=PROPERTY_VALUE)
9.8. Clone a Profile リンクのコピーリンクがクリップボードにコピーされました!
Clone a profile in a managed domain.
/profile=PROFILE_TO_CLONE:clone(to-profile=NEW_PROFILE_NAME)
/profile=PROFILE_TO_CLONE:clone(to-profile=NEW_PROFILE_NAME)
9.9. Create a Hierarchical Profile リンクのコピーリンクがクリップボードにコピーされました!
Create a new profile that inherits from other profiles.
/profile=NEW_PROFILE_NAME:add(includes=[PROFILE_1,PROFILE_2])
/profile=NEW_PROFILE_NAME:add(includes=[PROFILE_1,PROFILE_2])
9.10. Deploy an Application to a Managed Domain リンクのコピーリンクがクリップボードにコピーされました!
Deploy an Application to All Server Groups.
deploy /path/to/DEPLOYMENT.war --all-server-groups
deploy /path/to/DEPLOYMENT.war --all-server-groups
Deploy an Application to One or More Server Groups.
deploy /path/to/DEPLOYMENT.war --server-groups=SERVER_GROUP_1,SERVER_GROUP_2
deploy /path/to/DEPLOYMENT.war --server-groups=SERVER_GROUP_1,SERVER_GROUP_2
9.11. Deploy an Application to a Standalone Server リンクのコピーリンクがクリップボードにコピーされました!
deploy /path/to/DEPLOYMENT.war
deploy /path/to/DEPLOYMENT.war
9.12. Display the Active User リンクのコピーリンクがクリップボードにコピーされました!
Command:
:whoami
:whoami
Output:
9.13. Display Schema Information リンクのコピーリンクがクリップボードにコピーされました!
To show the schema information for the :product-info command:
:read-operation-description(name=product-info)
:read-operation-description(name=product-info)
To display the schema version, execute an ls command at the management CLI root and look for the management-*-version values:
... management-major-version=4 management-micro-version=0 management-minor-version=1 ...
...
management-major-version=4
management-micro-version=0
management-minor-version=1
...
9.14. Display System and Server Information リンクのコピーリンクがクリップボードにコピーされました!
Command:
:product-info
:product-info
Output:
Similarly, for a managed domain, you can display the information for a particular JBoss EAP host or server:
/host=HOST_NAME:product-info
/host=HOST_NAME:product-info
/host=HOST_NAME/server=SERVER_NAME:product-info
/host=HOST_NAME/server=SERVER_NAME:product-info
9.15. Reload a Host Controller リンクのコピーリンクがクリップボードにコピーされました!
reload --host=HOST_NAME
reload --host=HOST_NAME
9.16. Reload a Host Controller in Admin-only Mode リンクのコピーリンクがクリップボードにコピーされました!
reload --host=HOST_NAME --admin-only=true
reload --host=HOST_NAME --admin-only=true
9.17. Reload the Server リンクのコピーリンクがクリップボードにコピーされました!
reload
reload
9.18. Reload the Server in Admin-Only Mode リンクのコピーリンクがクリップボードにコピーされました!
reload --admin-only=true
reload --admin-only=true
9.19. Remove a Module リンクのコピーリンクがクリップボードにコピーされました!
module remove --name=MODULE_NAME
module remove --name=MODULE_NAME
Using the module management CLI command to add and remove modules is provided as technology preview only. This command is not appropriate for use in a managed domain or when connecting to the management CLI remotely. Modules should be added and removed manually in a production environment. For more information, see the Create a Custom Module Manually and Remove a Custom Module Manually sections of the JBoss EAP Configuration Guide.
9.20. Shut Down a Host Controller リンクのコピーリンクがクリップボードにコピーされました!
Shut down a host controller in a managed domain.
shutdown --host=HOST_NAME
shutdown --host=HOST_NAME
9.21. Shut Down the Server リンクのコピーリンクがクリップボードにコピーされました!
Shut down a standalone server.
shutdown
shutdown
9.22. Start a Server リンクのコピーリンクがクリップボードにコピーされました!
Start a server in a managed domain.
/host=HOST_NAME/server-config=SERVER_NAME:start
/host=HOST_NAME/server-config=SERVER_NAME:start
9.23. Start All Servers in a Server Group リンクのコピーリンクがクリップボードにコピーされました!
Start all servers in a certain server group in a managed domain.
/server-group=SERVER_GROUP_NAME:start-servers
/server-group=SERVER_GROUP_NAME:start-servers
9.24. Stop a Server リンクのコピーリンクがクリップボードにコピーされました!
Stop a server in a managed domain.
/host=HOST_NAME/server-config=SERVER_NAME:stop
/host=HOST_NAME/server-config=SERVER_NAME:stop
9.25. Stop All Servers in a Server Group リンクのコピーリンクがクリップボードにコピーされました!
Stop all servers in a certain server group in a managed domain.
/server-group=SERVER_GROUP_NAME:stop-servers
/server-group=SERVER_GROUP_NAME:stop-servers
9.26. Take a Configuration Snapshot リンクのコピーリンクがクリップボードにコピーされました!
Take a snapshot of the current configurations.
:take-snapshot
:take-snapshot
9.27. Undeploy an Application from a Managed Domain リンクのコピーリンクがクリップボードにコピーされました!
Undeploy an application from all server groups with that deployment.
undeploy DEPLOYMENT.war --all-relevant-server-groups
undeploy DEPLOYMENT.war --all-relevant-server-groups
Undeploy an application from a specific server group. The --keep-content parameter is required in order to keep the content in the repository for other server groups with that deployment.
undeploy DEPLOYMENT.war --server-groups=SERVER_GROUP_NAME --keep-content
undeploy DEPLOYMENT.war --server-groups=SERVER_GROUP_NAME --keep-content
9.28. Undeploy an Application from a Standalone Server リンクのコピーリンクがクリップボードにコピーされました!
undeploy DEPLOYMENT.war
undeploy DEPLOYMENT.war
9.29. Update a Host Name リンクのコピーリンクがクリップボードにコピーされました!
Update the name of a host in a managed domain. The host must be reloaded in order for the changes to take effect.
/host=EXISTING_HOST_NAME:write-attribute(name=name,value=NEW_HOST_NAME) reload --host=EXISTING_HOST_NAME
/host=EXISTING_HOST_NAME:write-attribute(name=name,value=NEW_HOST_NAME)
reload --host=EXISTING_HOST_NAME
9.30. View a Server Log リンクのコピーリンクがクリップボードにコピーされました!
/subsystem=logging/log-file=SERVER_LOG_NAME:read-log-file
/subsystem=logging/log-file=SERVER_LOG_NAME:read-log-file