> For the complete documentation index, see [llms.txt](https://docs.catalyx.solutions/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.catalyx.solutions/catalyx-blockchain-manager/hyperledger-fabric/version-2.4/network-and-node-management/ordering-service.md).

# Ordering Service

## What is an Ordering Service?

Hyperledger Fabric features an **ordering node** (orderer) that performs transaction ordering, along with other orderer nodes forming an **ordering service**. Because Hyperledger Fabric's design relies on deterministic consensus algorithms, any block validated by the peer is guaranteed to be final and correct — ledgers cannot fork the way they do in other distributed blockchain networks. See the [Hyperledger Fabric documentation](https://hyperledger-fabric.readthedocs.io/en/release-2.0/orderer/ordering_service.html#the-ordering-service) for more.

### System Channel

Every network begins with an ordering system channel. The policies in the ordering system channel configuration govern the consensus used by the ordering service and define how new blocks are created. It also contains information about orderer organizations and those allowed to create new channels (consortium organizations).

{% hint style="info" %}
Starting from Hyperledger Fabric v2.3, orderer channel management without a system channel is available. However, this is not supported by the current version of Catalyst Blockchain Manager.
{% endhint %}

### Raft

Starting from version 2.0, Hyperledger Fabric only supports **Raft** consensus. Raft is a crash fault-tolerant consensus protocol that allows multiple non-trusting organizations to reach mutual agreement through a leader-follower concept.

To keep an ordering service functional, you need to achieve a **quorum** — the minimum number of working orderers (consenters) required to ensure effective consensus. For every consenter set, this is a majority of nodes (e.g., 3 out of 5, 2 out of 2).

{% hint style="danger" %}
Add and remove consenters carefully. If a quorum is not available, the ordering service will not work and no new transactions will appear on the channel.
{% endhint %}

### Ordering Set

An **ordering set** is a template introduced by Catalyst Blockchain Manager for ordering nodes. Configurations specified when creating an ordering set apply to all orderers within it.

***

## How to Create an Ordering Set?

Go to the **Orderers** page and click **Create ordering set**.

<figure><img src="/files/3yQEglVNFJq5yYF3sC45" alt=""><figcaption></figcaption></figure>

Provide:

* **Ordering set name**
* **Image** — Docker image for creating ordering nodes

{% hint style="info" %}
Using a predefined image is recommended for compatibility. For private repositories, specify an `imagePullSecret`. You can create one in your Kubernetes cluster with the label `"app.kubernetes.io/name": "image-pull-secret"`.
{% endhint %}

* **Resources:** Requested CPU, CPU limit, Requested memory (MB), Memory limit (MB), Storage size
* **Environment variables**

{% hint style="danger" %}
Do not customize the following environment variables to ensure your Hyperledger Fabric Blockchain runs seamlessly: `ORDERER_GENERAL_LISTENADDRESS`, `ORDERER_GENERAL_LISTENPORT`, `ORDERER_GENERAL_GENESISPROFILE`, `ORDERER_GENERAL_TLS_ENABLED`, `ORDERER_FILELEDGER_LOCATION`, `ORDERER_CONSENSUS_WALDIR`, `ORDERER_CONSENSUS_SNAPDIR`
{% endhint %}

You can create as many ordering sets as needed.

***

## How to Create an Orderer?

Click **Add new node** in the ordering set page.

<figure><img src="/files/5ecawSM2xGhppM0cc7KW" alt=""><figcaption></figcaption></figure>

Provide:

1. **Orderer name** — Cannot be the same as any other orderer in the organization
2. **Select MSP** — Provides identity to the orderer on the network
3. **Add a signing identity** — Select an existing identity or create a new one with a password
4. **Add a TLS identity** — Similar to step 3, but for enrolling a TLS certificate

After creation, the new orderer appears under the **Orderers** tab with a "No genesis block" button. You need to [add the genesis block](#how-to-add-a-genesis-block) for the ordering node to function.

<details>

<summary>Orderer node states</summary>

| State           | Description                                       |
| --------------- | ------------------------------------------------- |
| **Pending**     | Starting or awaiting Kubernetes cluster expansion |
| **Running**     | Successfully created and ready to use             |
| **Terminating** | User has initiated deletion                       |
| **Failed**      | Unable to start (e.g., exhausted resources)       |
| **Unknown**     | Node status could not be obtained                 |

</details>

{% hint style="info" %}
If deleting an ordering node, remove it manually from application channels and then from the Raft page. Otherwise, it will still exist in channels and affect the quorum count.
{% endhint %}

***

## How to Create an External Orderer?

If your organization does not host any ordering nodes, you can add an **external orderer** that connects to an orderer deployed by another organization.

Go to the **Orderers** tab and click **Create external orderer**. Provide the name, choose the MSP of the organization hosting the orderer, and provide the link to the orderer.

<figure><img src="/files/V79vBcyoQZ0cxn5Wz9nP" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Both organizations must add each other to their partners list before adding an external orderer.
{% endhint %}

***

## How to Add a Genesis Block?

To make an orderer functional, you must add a genesis block containing the system channel configuration.

{% tabs %}
{% tab title="Bootstrap a System Channel" %}
You need to bootstrap a system channel to create a new network. See [How to Create a System Channel](#how-to-create-a-system-channel).
{% endtab %}

{% tab title="Join an Existing System Channel" %}
Click the **No Genesis Block** button at the ordering node, or click **Add genesis block** from the node's detail page.

Two options:

* **Fetch a genesis block** — Provide a link to any active orderer from a system channel. Your ordering node will fetch the last block automatically.
* **Upload a genesis block** — Ask any orderer organization to download the last system channel's block and send it to you. Upload it to your ordering node.

!\[Add a genesis block]\(.gitbook/assets/ordering-service/10 - Add a genesis block.png)
{% endtab %}

{% tab title="Add Another Consenter" %}
If you're already a network member and want to add another orderer to the system channel:

1. Create the orderer.
2. Add the new orderer to the consenter set on the system channel at the Raft page.
3. Add a genesis block (fetch or upload).

{% hint style="danger" %}
Add your new consenter to the consenter set **before** fetching the genesis block. If you don't, the orderer won't function properly even if it fetches the genesis block.
{% endhint %}

!\[Add a consenter to a system channel]\(.gitbook/assets/ordering-service/11 - Add a consenter to a system channel.png)
{% endtab %}
{% endtabs %}

***

## How to Create a System Channel?

{% hint style="danger" %}
Create a system channel only if you are bootstrapping the network. To join an existing one, see [Join a Network](file:///7571772/getting-started/join-a-network.md).
{% endhint %}

{% hint style="info" %}
Catalyst Blockchain Manager supports only one system channel. Your organization cannot be part of multiple system channels.
{% endhint %}

Go to the **Orderers** page, click **System channel**, then **Create system channel**.

!\[Create a system channel]\(.gitbook/assets/ordering-service/12 - Create a system channel.png)

{% stepper %}
{% step %}

#### Add Orderer Organizations

Orderer organizations contribute ordering nodes to the ordering service.

* **Your organization:** Select its MSP and orderers (create these before creating the system channel)
* **Other organizations:** Select their MSP and upload their orderer's JSON profile (only one orderer per organization at this step)

{% hint style="danger" %}
If adding other organizations during this step, your organization must have **more orderers** than the number of organizations you're adding. Otherwise, a quorum will not be achieved.
{% endhint %}

<figure><img src="/files/iU4CCN7Ane9IcwH53uCa" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

#### Create a Consortium

The consortium is the list of organizations that can create application channels. Your organization must be added to the consortium. You can add more organizations later.

{% hint style="info" %}
To add an organization, its MSP must be in your **Partners** list first.
{% endhint %}

<figure><img src="/files/LqM7wgyeK8nxt0HmWtX4" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

#### Configure the System Channel

Configure batch timeout, batch size, and Raft options (tick interval, max inflight blocks, etc.). All fields are pre-populated with recommended settings. See [Raft configuration docs](https://hyperledger-fabric.readthedocs.io/en/release-2.2/raft_configuration.html) for details.

<figure><img src="/files/xNDPAYsRvsZh58sRFtri" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
These values will be inherited by each application channel you create. They can be edited later on system and application channels.
{% endhint %}
{% endstep %}
{% endstepper %}

***

## How to Add an Organization as an Orderer Organization?

**Option 1 — During system channel creation:** Select the organization from the dropdown and provide its orderer JSON profile.

**Option 2 — On the Raft page of the system channel details:** Click **Add organization**.

<figure><img src="/files/KDo5zOGzixdEgEP1dExW" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
The organization must be in your partners' MSP list. See [Add Organization as a Partner](broken://pages/6c4372d218492584222726bb8b117a6b73c116b6#how-to-add-organization-as-a-partner).
{% endhint %}

***

## How to Add an Organization to the Consortium?

**Option 1 — During system channel creation:** Select the organization from the dropdown.

**Option 2 — On the Consortium page of the system channel details:** Click **Add an Organization** and select from the dropdown.

{% hint style="info" %}
The organization must be in the orderer organization list first.
{% endhint %}

{% hint style="danger" %}
Only consortium members can add other organizations to the consortium.
{% endhint %}

<figure><img src="/files/SSSPoHGC6A8aEypRp87M" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.catalyx.solutions/catalyx-blockchain-manager/hyperledger-fabric/version-2.4/network-and-node-management/ordering-service.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
