Skip to content
the poor coder

stop jboss from cli

Poor Man
Published
Reading time
1 min read
On this page

How to stop JBoss from CLI#

If you are working with JBoss and need to stop it from the command line interface (CLI), there are a few ways to do so depending on your environment.

Method 1: Using jboss-cli.sh script#

The easiest way to stop JBoss is to use the jboss-cli.sh script, which can be found in the bin directory of your JBoss installation. Simply navigate to the bin directory and run the following command:

Text
./jboss-cli.sh --connect command=:shutdown

This will connect to the JBoss server and issue a shutdown command, stopping the server.

Method 2: Using Java Management Extensions (JMX)#

If the above method doesn't work for you, you can also stop JBoss using Java Management Extensions (JMX). To do so, follow these steps:

  1. Start the jconsole utility by running the following command:
Text
jconsole
  1. Select the JBoss process from the list of Java processes.
  2. Click on the "MBean" tab.
  3. Expand "jboss.system" and select "Server".
  4. Click on the "Operations" tab and select "shutdown".
  5. Click on the "Invoke" button to stop the server.

Method 3: Using kill command#

If neither of the above methods work for you, you can also stop JBoss using the kill command. To do so, follow these steps:

  1. Find the process ID (PID) of the JBoss server by running the following command:
Text
ps -ef | grep jboss
  1. Note the PID of the JBoss process.
  2. Use the kill command to stop the server by running the following command:
Text
kill -9 PID
  1. Replace "PID" with the actual process ID of the JBoss server.

Regardless of which method you choose, stopping JBoss from the CLI is a simple process that can be done quickly and easily using the steps outlined above.

Keep going

2023

how to sort an array

How to Sort an Array If you have an array and you want to order its elements in a specific way, you need to use a sorting algorithm. There are several sorting algorithms available, but two of the most commonly used are…

javascript2 min read
2023

jquery mobile or desktop

jQuery Mobile or Desktop? As a web developer, I have had some experience with both jQuery Mobile and jQuery Desktop. Both frameworks have their pros and cons, and which one to use really depends on the specific project…

javascript1 min read
2023

node.js folder structure

Node.js Folder Structure If you are new to Node.js, it can be daunting to create a folder structure that will work for your project. The structure you choose will depend on the size and complexity of your project. Here…

javascript1 min read
ESC