vania-janet/multiturn-rag-retrieval-data huggingface dataset:
Advanced channel deployment and management 

When you create a channel, there are a number of advanced options that allow you fine tune the configuration of your channel to fit your use case. In this topic we'll discuss how to edit those options as part of creating a channel or when editing a channel after it has been created.

Target audience: This topic is designed for network operators who are responsible for creating, monitoring, and managing channels.

The roles played by the various participants in channel creation, as well as the underlying method used to create and update the channel configuration, is inherited from the [Hyperledger Fabric processes for creating and editing a channel](https://hyperledger-fabric.readthedocs.io/en/release-2.2/configtx.html).

The parameters that govern how channels function, from the organizations on the channel to their permissions to the policies, are all contained in the channel configuration. When you create a channel, you are asked to decide on a number of these parameters. Some options, such as the channel name, cannot be changed after a channel has been created, while other options can only be changed after the channel has been created.



 General options 

For an overview of the channel creation process that ignores the advanced options, see [Step four: Create a channel](https://cloud.ibm.com/docs/blockchain?topic=blockchain-ibp-console-build-networkibp-console-build-network-create-channel).



* Channel name. Channels should be given distinctive names relevant to the purpose of the channel. Each ordering service can only have a single channel with a given name. If you see an error that a name has already been given to a channel on that ordering service, you will have to select a new name.
* Ordering service. Channels are hosted on a single ordering service and cannot be migrated from one ordering service to another.
* Organizations. This section of the panel is how organizations are added or removed from a channel. Organizations that can be added can be seen in the drop-down list. Note that an organization must be a member of the consortium of the ordering service before it can be added to a channel.
Created 2023-04-24T18:54:29+05:30
Captured at 2023-04-24T09:48:03+05:30
Tags -
Service Tags -
Show more

For more information about available command options, see [ibmcloud is snapshot-create](https://cloud.ibm.com/docs/cli?topic=cli-vpc-referencesnapshot-create).





 Creating a snapshot with the API 

You can create a snapshot by using the API.



 Prerequisites for creating a snapshot with the API 

You can create a snapshot by calling the [VPC API](https://cloud.ibm.com/apidocs/vpc). Before you start, gather the following information:



* A unique name for the snapshot.
* The ID of the source volume.
* The resource group ID. You can't change the resource group after the snapshot is created.
* Any tags that you want to attach to the snapshot.







 Creating a snapshot with the API 

To create a snapshot of a boot or data volume, make a POST /snapshots. The following example creates a snapshot of a boot volume by using the volume ID, and specifies user tags that can be associated with a [backup policy](https://cloud.ibm.com/docs/vpc?topic=vpc-backup-service-about).

curl -X POST "$vpc_api_endpoint/v1/snapshots?version=2022-12-12&generation=2" -H "Authorization: $iam_token" -d '{
"name": "boot-snapshot-1",
"source_volume": {
"id": "8948ad59-bc0f-7510-812f-5dc64f59fab8"
},
"resource_group": {
"id": "a342dbfb-3ea7-48d1-96e8-2825ec5feab4"
},
"user_tags": [
(The XXXp1 represents the partition name.)
* Create the file system:



mkfs.ext3 /dev/mapper/XXXp1
4. Create a mount point for the file system, and mount it.



* Create a partition name PerfDisk or where you want to mount the file system.



mkdir /PerfDisk



* Mount the storage with the partition name.



mount /dev/mapper/XXXp1 /PerfDisk



* Check that you see your new file system listed.



df -h
5. Add the new file system to the system's /etc/fstab file to enable automatic mounting on boot.



* Append the following line to the end of /etc/fstab (with the partition name from Step 3).



/dev/mapper/XXXp1 /PerfDisk ext3 defaults,_netdev 0 1







 Creating a file system with parted 

On many Linux® distributions, parted comes preinstalled. However, if you need to you can install it running the following command.

 yum install parted

To create a file system with parted, follow these steps.



1. Start the interactive parted shell.

parted
2. Create a partition on the disk.



* Unless it is specified otherwise, parted uses your primary drive, which is /dev/sda in most cases. Switch to the disk that you want to partition by using the command select. Replace XXX with your new device name.

select /dev/mapper/XXX
* Run print to confirm that you are on the right disk

print
* Create a GPT partition table.

mklabel gpt
* Parted can be used to create primary and logical disk partitions, the steps that are involved are the same. To create a partition, parted uses mkpart. You can give it other parameters like primary or logical depending on the partition type that you want to create. The listed units default to megabytes (MB). To create a 10-GB partition, you start from 1 and end at 10000.
My key custodian - creator Manages and creates keys. For a complete key lifecycle, both Creator and Deployer roles are needed. To implement separation of duties, assign Creator and Deployer role to different people. <br><br> * hs-crypto.managed-keys.preactivation-destroy<br> * hs-crypto.managed-keys.active-install<br> * hs-crypto.managed-keys.active-uninstall<br> * hs-crypto.managed-keys.deactivated-install<br> * hs-crypto.managed-keys.deactivated-uninstall<br> * hs-crypto.managed-keys.read<br> * hs-crypto.managed-keys.list<br> * hs-crypto.managed-keys.write<br> * hs-crypto.managed-keys.generate<br> * hs-crypto.managed-keys.distribute<br> * hs-crypto.managed-keys.write-dates<br> * hs-crypto.managed-keys.write-tags<br> * hs-crypto.target-keystores.read<br> * hs-crypto.target-keystores.list<br> * hs-crypto.key-templates.read<br> * hs-crypto.key-templates.list<br> * hs-crypto.key-templates.write<br> * hs-crypto.vaults.read<br> * hs-crypto.vaults.list<br><br><br> 
 My key custodian - deployer Manages and deploys keys. For a complete key lifecycle, both Creator and Deployer roles are needed. To implement separation of duties, assign Creator and Deployer role to different people.
If you don't already have an instance of the secrets management vault provider of your choice, create one.
* Optional. A namespace that is created by using the container registry command line. To create a namespace, type the following command from the command line:

ibmcloud cr namespace-add <my namespace>

Alternatively, you can create a namespace on the [Container Registry](https://cloud.ibm.com/registry/namespaces) page. For more information about creating a namespace in this location, see [IBM Cloud Container Registry](https://cloud.ibm.com/docs/Registry?topic=Registry-getting-startedgetting-started) service.





 Related content 



* [Getting started with Continuous Delivery](https://cloud.ibm.com/docs/ContinuousDelivery?topic=ContinuousDelivery-getting-started)
* [Getting started with clusters](https://cloud.ibm.com/docs/containers?topic=containers-getting-started)
* [Getting started with toolchains](https://cloud.ibm.com/devops/getting-started)
* [DevSecOps with Continuous Delivery](https://cloud.ibm.com/docs/devsecops?topic=devsecops-devsecops_intro)









 Step 1: Create the toolchain 

In this step, you create a Deploy your application to multiple clusters toolchain. The target Kubernetes cluster is configured during the toolchain setup by using your IBM Cloud API key and your Kubernetes cluster name. You can change these settings later by updating the Delivery Pipeline configuration. Any code that is merged into the target Git repo branch is automatically built, validated, and deployed into the Kubernetes cluster.

To create a Deploy your application to multiple clusters toolchain, click

[!
In the [IBM Cloud console ![External link icon](https://cloud.ibm.com/docs-content/v1/content/f02b9c9adcbb7328d95a45e105cec371d50f15eb/icons/launch-glyph.svg)](https://cloud.ibm.com/login), go to Menu icon ![Menu icon](https://cloud.ibm.com/docs-content/v1/content/f02b9c9adcbb7328d95a45e105cec371d50f15eb/icons/icon_hamburger.svg) > VPC Infrastructure > Auto scale > Instance templates.
2. Click New instance template and enter the information that is in Table 1.
3. Click Create instance template when the information is complete.





Table 1. Instance template selections

 Field Value 

 Architecture Select the processor architecture that your instance is created with. x86 means x86_64 bit processor, and s390x is z Systems or LinuxONE (s390x processor architecture). 
 Hosting type A Public virtual server instance, created in a multi-tenant environment, is the default selection for a new instance. You can also select a Dedicated virtual server instance to create the instance in a single-tenant space. To provision a dedicated instance, you must have a dedicated host available or [create one](https://cloud.ibm.com/docs/vpc?topic=vpc-creating-dedicated-hosts-instances). z/OS virtual server instances do not support the dedicated type. 
 Location Locations are composed of regions (specific geographic areas) and zones (fault tolerant data centers within a region). Select the geography, region, and zone where you want your virtual server instance to be created. 
 Name A name is required for your virtual server instance. 
 Resource group Select a resource group for the instance. 
 Operating system Select a a stock image, a custom image from your account, or a custom image that was shared with your account from a private catalog.
"scope": "ibm openid"
}

Create an environment variable to save some typing by using the value under the access_token key in the response data:

export TOK="Bearer eyJraWQiOiIyMDE5MD...tIwkCO9A"





 Creating the _replicator database on the Source side 

URL is the Source instance URL that you previously wrote down in step 4.b.

curl -k -X PUT -H"Content-type: application/json" -H'Authorization: '"$TOK"'' 'https://d43caf1b-e2c8-4d3e-9b85-1d04839fa68f-bluemix.cloudant.com/_replicator'

See the results in the following example:

{"ok": "true"}





 Creating the replication job 

Create a file called data.json that contains the following information. The two keys are the Source and Target API keys that are created in the beginning, and the Source and Target instance URLs, with database names added.

{
"source": {
"url": "https://d43caf1b-e2c8-4d3e-9b85-1d04839fa68f-bluemix.cloudant.com/source",
"auth": {
"iam": {
"api_key": "xju1...TxuS"
}
}
},
"target": {
"url": "https://dbc68dd8-f69f-4083-97dd-bf0a3e1a467a-bluemix.cloudant.com/target",
"auth": {
"iam": {
"api_key": "UElc7...QIaL01Bjn"
}
}
},
"create_target": true,
"continuous": true
}
Show more
The snapshot is taken and displayed in the Snapshots section of the Detail page. Its schedule appears Manual.





 Taking a manual Snapshot from the SLCLI 

You can use the following command to create a snapshot from the SLCLI.

 slcli file snapshot-create --help
Usage: slcli file snapshot-create [OPTIONS] VOLUME_ID

Options:
-n, --notes TEXT Notes to set on the new snapshot
-h, --help Show this message and exit.





 Listing all Snapshots with Space Used Information and Management functions in the UI 

A list of retained snapshots and space that is used can be seen on the File Storage for Classic Detail page. Management functions (editing schedules and adding more space) are conducted on the File Storage for Classic Detail page by using the Actions menu or links in the various sections on the page. The Snapshot page displays how much capacity the volume has and how much of it is used.

You receive notifications when you reach space thresholds – 75 percent, 90 percent, and 95 percent.



* At 75 percent capacity, a warning is sent that snapshot space usage exceeded 75 percent. To remediate, you can manually add space, or delete retained unnecessary snapshots. You can reduce the number of retained snapshots in the schedule. If you reduce the snapshot data or increase the space, the warning system is reset, and no autodeletion occurs.
* At 90 percent capacity, a second warning is sent when snapshot space usage exceeded 90 percent. Like with reaching 75 percent capacity, if you take the necessary actions to decrease the snapshot data or increase the space, the warning system is reset and no autodeletion occurs.
* At 95 percent capacity, a final warning is sent. If no action is taken to bring your space usage under the threshold, automatic deletion starts so that future snapshots can be created. Scheduled snapshots are deleted, starting with the oldest, until usage drops under 95 percent. Snapshots continue to be deleted each time usage exceeds 95 percent until it drops under the threshold.
Click View all in the Recent support cases panel and click Create new case. Or, you can directly go to the [Manage cases page](https://cloud.ibm.com/unifiedsupport/cases) and click Create new case.
2. On the Create a case page displayed, select the offering Hyper Protect Crypto Services, and then specify the following values:



Table 1. Describes the fields required for creating a case

 Field name Action 

 Subject Enter Disaster recovery. 
 Description Enter your [service instance ID](https://cloud.ibm.com/docs/hs-crypto?topic=hs-crypto-retrieve-instance-ID) and the region that your service instance resides in. 
 Selected resources Optional. Select your Hyper Protect Crypto Services service instance. 



3. Check the Email me updates about this issue box, and click Continue to review > Create case.

When the restore completes successfully, you will get an email notification, which includes the new region information that your service instance resides in. Alternatively, you can check the state by clicking Support. For more information about IBM Support, see [Support Center](https://cloud.ibm.com/unifiedsupport/supportcenter).
4. After you open the ticket, IBM provisions new crypto units for you in another region by using the same instance ID, and restores all the key resources from the backup. And then, you need to load your master key to the new service instance in the new region. Depending on how you store your master key parts, you can follow the instructions in [Initializing service instances with the IBM Cloud TKE CLI plug-in](https://cloud.ibm.com/docs/hs-crypto?topic=hs-crypto-initialize-hsm) or [Initializing service instances using smart cards and the Management Utilities](https://cloud.ibm.com/docs/hs-crypto?topic=hs-crypto-initialize-hsm-management-utilities).

Make sure to load the same master key to the service instance in the new region so that your key resources can still be accessed.







 What's next
12. Enter the Name and Description for the key.
13. Click Create.



Copy the API key or download to save it.

The key is available for 300 seconds. After the 300 seconds, you won't be able to display or retrieve the key.





 Creating virtual server instances for the cluster 

Complete the following steps to create the virtual server instances that you want to use as high availability cluster nodes.



1. Log in to [Workspaces - Power Systems Virtual Server](https://cloud.ibm.com/power/workspaces).
2. Select the Workspace that you created.
3. Click View virtual server instances > Create Instance. You need to step through the subsections General, Boot Image, Profile, Storage Volume, Network Interfaces.
4. In subsection General, enter the Instance name and click + to increase the Number of instances to 2.
5. Select Numerical postfix as Instance naming convention, and select Different server as Placement group colocation policy. A placement group with colocation policy Different server is automatically created as part of the virtual server instances deployment.
6. Select the SSH key that you created and click Continue.
7. In Boot image, select the Operating system according to your subscription model.
Use one of the Linux selections either from the IBM-provided subscription or through your Client-provided subscription.
Keep Auto-select pool for selecting the Storage Pool.
Click Continue.
8. In Profile, select Machine type, Core type, and the virtual server instance profile according to your workload requirements. Click Continue.
9. In Storage volumes, click Continue.

When you deploy multiple instances, storage volumes that are created are shared by both instances. Certain high availability cluster scenarios require shared volumes. In these cases, create the shared volumes later. For SAP HANA, see [Storage configuration for SAP HANA](https://cloud.ibm.com/docs/sap?topic=sap-storage-design-considerationsstorage-config-hana). Those volumes must be created later for the individual server instances after their provisioning completes.
10.
ibmcloud sat storage config create --location LOCATION --name NAME --template-name local-volume-block --template-version 4.9 --param "auto-discover-devices=AUTO-DISCOVER-DEVICES" --param "label-key=LABEL-KEY" --param "label-value=LABEL-VALUE" [--param "devicepath=DEVICEPATH"]

Example command to create a version 4.10 configuration.

ibmcloud sat storage config create --location LOCATION --name NAME --template-name local-volume-block --template-version 4.10 --param "auto-discover-devices=AUTO-DISCOVER-DEVICES" --param "label-key=LABEL-KEY" --param "label-value=LABEL-VALUE" [--param "devicepath=DEVICEPATH"]

Example command to create a version 4.11 configuration.

ibmcloud sat storage config create --location LOCATION --name NAME --template-name local-volume-block --template-version 4.11 --param "auto-discover-devices=AUTO-DISCOVER-DEVICES" --param "label-key=LABEL-KEY" --param "label-value=LABEL-VALUE" [--param "devicepath=DEVICEPATH"]

Example command to create a version 4.12 configuration.

ibmcloud sat storage config create --location LOCATION --name NAME --template-name local-volume-block --template-version 4.12 --param "auto-discover-devices=AUTO-DISCOVER-DEVICES" --param "label-key=LABEL-KEY" --param "label-value=LABEL-VALUE" [--param "devicepath=DEVICEPATH"]
6. Customize the command based on the settings that you want to use.
7. Run the command to create a configuration.
8. Verify your configuration was created.

ibmcloud sat storage config get --config CONFIG







 Creating a configuration in the API 



1. Generate an API key, then request a refresh token.
"createdBy": "crn-crn:v1:bluemix:public:cloud-object-storage:global:a/ea998d3389c3473aa0987652b46fb146:4b636e74-f3ca-40bb-80b8-3bd21801ccb8::",
"creationDate": "2020-06-15T16:07:37Z",
"lastUpdated": "2020-06-15T16:07:37Z",
"keyVersion": { "id": "2cbea94c-6070-4a24-b0f8-7a56e4d7cb6f", "creationDate": "2020-06-15T16:05:53Z"
}
}
]





 Example 2 

This example shows the full lifecycle of two cloud resources (Cloud Object Storage and Key Protect - from creating Key Protect instances and creating a policy between them to deleting the instances.

A summary of the steps is:



 Step Where Description 

 1 CLI Create cloud object storage (COS) and Key Protect (KP) instances 
 2 CLI Create a policy for COS to access KP encryption keys 
 3 CLI Create a KP root key that COS uses to encrypt data 
 4 Console UI Create a COS bucket and specify KP encryption; this is done in the console user interface (UI) because there is no API or CLI support at this time 
 5 CLI View the KP registration 
 6 CLI Upload and download an object to verify COS and KP works together 
 7 CLI Delete the COS bucket and the KP root key 
 8 CLI Delete the authorization policy between COS and KP 
 9 CLI Delete the COS and KP instances 



These commands show COS and Key Protect service plans. The ibmcloud resource service-instance-create command requires a service plan name and a location, which is in the catalog.

 show the catalog offerings for cloud object storage (COS) and Key Protect
$ ibmcloud catalog service cloud-object-storage
"name": "myinventory",
"description": "This is the resource inventory for production",
"location": "us-east",
"resource_group": "default",
"resource_queries": [
"default.RESOURCEQUERY.string.df3d8a47"
]

}

ibmcloud schematics inventory create --file inventory.json





 Using the interactive mode 

Instead of entering your inventory details by using the command options or a payload file, you can also use the interactive mode for the command. This mode prompts you to enter the required values to create an inventory in Schematics.



1. Enter the command to create the inventory without any command options.

ibmcloud schematics inventory create
2. Enter a name for your inventory and press the return key.
3. Enter the resource group where you want to create the inventory and press the return key.
4. Enter the location where you want to create the inventory, such as us-south, us-east, eu-de, or eu-gb. Then, press the return key.
5. Review the details of the inventory that was created.









 ibmcloud schematics inventory delete 

Delete the resource inventory definition by using the inventory ID from the IBM Cloud Schematics service. Note you can delete the location and region, resource group from where your inventory was created. Also, make sure your IP addresses are in the [allowlist](https://cloud.ibm.com/docs/schematics?topic=schematics-allowed-ipaddresses).

Syntax

ibmcloud schematics inventory delete --id ACTION_ID [--force]

Command options



Schematics inventory delete flags

 Flag Required / Optional Description 

 --id or -i Required The ID of an inventory that you want to delete. 
 --force or -f Optional Force the deletion without user confirmation. 
 --no-prompt Optional Set this flag to run the command without user prompts. 



Example
Dynamic provisioning automatically creates the matching persistent volume (PV) and orders the physical storage device in your IBM Cloud infrastructure account.

Before you begin:



* If you have a firewall, [allow egress access](https://cloud.ibm.com/docs/containers?topic=containers-firewallvyatta_firewall) for the IBM Cloud infrastructure IP ranges of the zones that your clusters are in so that you can create PVCs.
* [Decide on a pre-defined storage class](https://cloud.ibm.com/docs/containers?topic=containers-file_storagefile_predefined_storageclass) or create a [customized storage class](https://cloud.ibm.com/docs/containers?topic=containers-file_storagefile_custom_storageclass).



Looking to deploy File Storage for Classic in a stateful set? See [Using File Storage for Classic in a stateful set](https://cloud.ibm.com/docs/containers?topic=containers-file_storagefile_statefulset) for more information.

To add File Storage for Classic:



1. Create a configuration file to define your persistent volume claim (PVC) and save the configuration as a .yaml file.

Example for bronze, silver, gold storage classes.

The following .yaml file creates a claim that is named mypvc of the "ibmc-file-silver" storage class, billed "monthly", with a gigabyte size of 24Gi.

apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: mypvc
labels:
billingType: "monthly"
region: us-south
zone: dal13
spec:
accessModes:
- ReadWriteMany
resources:
requests:
storage: 24Gi
storageClassName: ibmc-file-silver

Example for using the custom storage class.

The following .yaml file creates a claim that is named mypvc of the storage class ibmc-file-retain-custom, billed "hourly", with a gigabyte size of 45Gi and IOPS of "300".