If there is no existing fabric for a broker to join, you will need to create one from the standalone broker. There are two options for how to do this:
The recommended approach is to create the fabric such that the broker is converted into a managed Fabric Server. The container will revert to being a vanilla broker, so you will need to either create a new broker with the desired configuration or deploy an updated broker profile into the Fabric Server.
Ensuring that the new broker is configured properly requires creating a broker profile with the proper settings. This can be done once the new fabric is created using the fabric:mq-create command. The fabric:mq-create command can also create the new broker.
The alternative approach is to create the fabric such that the broker becomes a non-managed Fabric Server. The broker becomes a Fabric Server that is fully capable of being part of a fabric's ensemble. However, the broker retains control over its own configuration. It will continue to be managed as if it were a standalone broker and will not respond to fabric commands that attempt to alter its configuration.
Several things happen when a fabric is created from a standalone broker:
The broker installs the required Fuse Fabric bundles to become a Fabric Server.
The Fabric Server starts up the ensemble process.
A new ensemble containing an empty configuration registry and a runtime registry with a single entry for the Fabric Server is created.
The Fabric Server delegates control over its configuration to the ensemble.
![[Note]](imagesdb/note.gif)
Note If the fabric is created with a non-managed server, this step is skipped.
The ensemble associates the profiles required to be a Fabric Server with the container.
Unless the
--no-importflag is used, the ensemble imports a set of profiles.If the
--import-dirflag is used, the profiles are imported from the specified location.If no location is specified the default set of profiles is imported from
.InstallDir/fabric/import
The ensemble installs the default
mqprofile to the container.This starts a default broker instance in the container.
![[Note]](imagesdb/note.gif)
Note If the fabric is created with a non-managed server, this step is skipped.
The ensemble waits for commands to update the fabric.
To create a new fabric from a standalone broker:
Delete the standalone broker configuration(s) from your installation's
/etcfolder.The configuration is stored in
/etc/org.fusesource.mq.fabric.server-.configName.cfgConnect to the standalone broker's command console.
Remove any brokers running in the container.
Use config:list to locate any PIDs using the form
org.fusesource.mq.fabric.server..IDUse config:delete to delete all of the PIDs using the form
org.fusesource.mq.fabric.server..ID
Enter the following command:
FuseMQ:karaf@root>fabric:create![[Tip]](imagesdb/tip.gif)
Tip If you want to import a predefined set of profiles, use the
-poption to specify the set of profiles to import.import-dirFor details on fabric:create see fabric:create in Console Reference.
Add a new broker to the fabric as described in Deploying a New Broker into a Fabric.








