Karaf Console Commands Cheat Sheet
This page serves as a cheat sheet for frequently used Karaf console commands; that is, the descriptions are intentionally kept concise. Commands of particular interest are in bold. Detailed documentation is available at Apache Karaf Container 4.x - Documentation or Karaf Console Commands for the BPC.
General
| Command | ** Description |
|---|---|
|
Ends the current Karaf console session |
|
Shuts down and restarts Karaf (not OpenSearch) |
|
Pressing the Tab key lists possible commands, subshells, etc., or—for a subshell—its commands (e.g., BPC:<TAB-Taste>), or—for a command—its options.
You do not need to type the entire name; if it is unique, it will be automatically completed—for example, entering “ |
|
” to display help for the command. |
|
Executes the command of the specified subshell. |
|
Switches to the specified subshell (from the parent shell or any subshell) and executes the command. |
|
Exits the subshell and returns to the parent shell. |
List, install, stop, etc., Karaf bundles
| Command | Description |
|---|---|
|
Show installed bundles and their status |
|
Show installed bundles whose line does not contain "active" (-v), ignore case (-i) |
|
Stop the bundle with the specified ID (can be determined via list) |
|
Restart the bundle with the specified ID (can be determined via |
|
Installs a feature, e.g., the PostgreSQL JDBC driver with |
|
Installs and starts an OSGi bundle, typically with the URL pattern mvn:my/bundle/1.0 |
|
Uninstalls an OSGi bundle |
System Information
| Command | Description |
|---|---|
|
Display the last 50 log entries |
|
Displays the last [20] log entries and then continuously displays new entries as they arrive. |
|
Displays new log entries as they arrive that contain the search term. |
|
Displays important system information, such as the installation path. This is useful if you’re using SSH access and therefore don’t know where the instance you’re connected to is installed. |
|
Displays the values of system properties.
Examples of ` |
|
Karaf version ` |
|
Creates a ZIP file containing comprehensive information for problem analysis, which is required, for example, for support requests. ` |
` == Manage Karaf Users
These are not necessarily the same as the end users who log in to BPC via a browser, for example, when using INUBIT as an identity provider.
| Command | Description |
|---|---|
|
List of realms to help identify the correct one—Realm 3 is often the one for |
|
Switch to the realm you want to work with |
|
Check the users and Karaf roles in the realm |
|
Create the user |
|
Assign the role |
|
Save changes |
BPC Commands
See also Karaf Console Commands for the BPC.