diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/_index.md b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/_index.md index 256137b398..51803af883 100644 --- a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/_index.md +++ b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/_index.md @@ -1,6 +1,10 @@ --- title: Deploy Couchbase on Google Cloud C4A (Arm-based Axion VMs) +draft: true +cascade: + draft: true + minutes_to_complete: 30 who_is_this_for: This learning path is intended for software developers deploying and optimizing Couchbase workloads on Linux/Arm64 environments, specifically using Google Cloud C4A virtual machines powered by Axion processors. diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/baseline.md b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/baseline.md index db8dc651e4..3f2e4f41a4 100644 --- a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/baseline.md +++ b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/baseline.md @@ -1,89 +1,90 @@ --- title: Couchbase Baseline Testing on Google Axion C4A Arm Virtual Machine -weight: 5 +weight: 6 ### FIXED, DO NOT MODIFY layout: learningpathall --- ## Couchbase Baseline Testing on GCP SUSE VMs -This section confirms that Couchbase is correctly installed and running on the GCP SUSE Arm64 VM. It includes checking required ports, initializing the cluster, verifying node status, and accessing the Web UI — ensuring the setup is ready for benchmarking. +This section confirms that Couchbase is correctly installed and running on the GCP SUSE Arm64 VM. It includes initializing the cluster, verifying node status, and accessing the Web UI to create a bucket — this ensures the setup is ready for benchmarking. -### Check Required Ports -This command checks if those ports are open and active. If you see “LISTEN” next to these ports, it means Couchbase is ready to accept connections. +### Setup the default cluster +Once the service is running, we need to setup the default cluster for the first time. -Couchbase uses the following ports for basic operation: - -- Web Console: `8091` -- Query Service: `8093` (optional for N1QL queries) -- Data Service: `11210` - -Check if the ports are listening: +- Open Web Console using your VM public IP address that you saved off in the last step: ```console -sudo ss -tuln | grep -E '8091|11210' +http://:8091 ``` +- Press "Setup New Cluster" -```output -tcp LISTEN 0 128 0.0.0.0:8091 0.0.0.0:* -tcp LISTEN 0 1024 0.0.0.0:11210 0.0.0.0:* -tcp LISTEN 0 1024 [::]:11210 [::]:* -``` +![Setup new cluster](images/cluster-setup-1.png "Setup new cluster") -### Initialize Couchbase Cluster -This step sets up Couchbase for the first time, essentially turning it on and configuring its basic settings. -- You’re giving it an admin username and password for login. -- The cluster name helps identify your setup. -- You’re enabling key services (data, index, query). -- You’re assigning memory so Couchbase knows how much RAM it can use. -If it says **“SUCCESS: Cluster initialized”**, Couchbase is ready to store and manage data. +- Provide a name for your cluster (example: "my_cluster") and create a password for your administrator account (leave the username as the default "Administrator") -```console -/opt/couchbase/bin/couchbase-cli cluster-init \ - -c localhost:8091 \ - --cluster-username Administrator \ - --cluster-password password \ - --cluster-name MyCluster \ - --services data,index,query \ - --cluster-ramsize 1024 \ - --cluster-index-ramsize 512 -``` +![Create cluster and admin count](images/cluster-setup-2.png "Create cluster and admin count") -You should see an output similar to: -```output -SUCCESS: Cluster initialized -``` +- Check the "Accept terms" checkbox and press "Configure Disk, Memory, Services" button + +![Accept Terms](images/cluster-setup-3.png "Accept Terms") + +- Accept the defaults of your cluster configuration and press "Save & Finish" + +![Finalize configuration](images/cluster-setup-4.png "Finalize configuration") + +Our default cluster is now created! Please retain the passord you created for your "Administrator" account... you'll need that in the next steps. ### Verify Cluster Nodes -This command checks if your Couchbase server (called a “node”) is running properly. +This command checks if your Couchbase server (called a “node”) is running properly. Replace "password" with your specified Couchbase Administrator password. If the output says **“healthy active”**, it means your Couchbase node is working fine and ready for operations. ```console /opt/couchbase/bin/couchbase-cli server-list \ - -u Administrator -p password \ - --cluster localhost + -u Administrator -p password --cluster localhost ``` ```output ns_1@cb.local 127.0.0.1:8091 healthy active ``` -### Web UI Access -Ensure the Couchbase service is running and ports **8091 (Web UI)** and **11210 (Data)** are open. +### Prepare a Couchbase Bucket for benchmarking +Once the service is running, you can access the **Couchbase Web Console** to create a bucket for benchmarking. + +Open Web Console using the public IP address of your VM that you saved off from the last step: ```console -sudo systemctl start couchbase-server -sudo systemctl enable couchbase-server -sudo systemctl status couchbase-server +http://:8091 ``` -These commands make sure Couchbase is running and will automatically start after system reboots. After starting the service, open your web browser and visit your VM’s IP on port 8091. -Once the service is running, Couchbase is accessible in your browser at: +Use the admin `username` (default is "Administrator") and `password` you created during Couchbase cluster setup in the previous step. -```cpp -http://:8091 -``` -You will see the Couchbase Web Console — a dashboard where you can log in, manage data buckets, and monitor performance visually. +![Couchbase Dashboard](images/dashboard-1.png "Couchbase Dashboard") + +- On the left hand side select "Buckets" +- Press the "Add Bucket" in the upper right hand corner: + +![Create Bucket](images/create-bucket-1.png "Create Bucket") + +- Name the new bucket "benchmark" +- The bucket type will be "Couchbase" +- The Memory Quota can be set to "512 MB" + +![Create Bucket](images/create-bucket-2.png "Create Bucket") + +| **Parameter** | **Value** | +|----------------|-----------| +| **Bucket Name** | benchmark | +| **Bucket Type** | Couchbase | +| **Memory Quota** | 512 MB | + +- You should now see that your bucket has been created: + +![Created Bucket](images/create-bucket-3.png "Created Bucket") + +#### Additional notes about buckets in Couchbase -![Couchbase Dashboard alt-text#center](images/couchbase.png "Couchbase Web") +- A **bucket** in Couchbase is like a **database** — it stores and manages your data. +- The **benchmark** bucket will be used for **load testing** and **performance benchmarking**. +- Setting the **RAM Quota** ensures Couchbase allocates sufficient memory for **in-memory data operations**, improving overall speed. You can now proceed to the next section for benchmarking to measure Couchbase’s performance. diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/benchmarking.md b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/benchmarking.md index 4163d7fd6f..4ecff50f41 100644 --- a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/benchmarking.md +++ b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/benchmarking.md @@ -1,13 +1,13 @@ --- title: Couchbase Benchmarking -weight: 6 +weight: 7 ### FIXED, DO NOT MODIFY layout: learningpathall --- -## Puppet Benchmark on GCP SUSE Arm64 VM +## Couchbase Benchmark on GCP SUSE Arm64 VM This section guides you through benchmarking Couchbase performance on a GCP SUSE Arm64 VM using the **official `cbc-pillowfight` tool** from Couchbase C SDK. It involves installing dependencies, building the SDK, verifying the setup, and running the benchmark test. @@ -15,7 +15,7 @@ It involves installing dependencies, building the SDK, verifying the setup, and Before compiling the Couchbase SDK, install all required development tools and libraries. ```console -sudo zypper install -y gcc gcc-c++ cmake make git openssl-devel libevent-devel cyrus-sasl-devel +sudo zypper install -y gcc gcc-c++ cmake make git openssl-devel libevent-devel cyrus-sasl-devel java ``` ### Download and Build the Couchbase C SDK (includes cbc-pillowfight) @@ -60,7 +60,7 @@ After installation, the tools like **cbc**, **cbc-pillowfight**, etc. should be cbc version cbc-pillowfight --help ``` -You should see an output similar to: +For the "cbc version" command, you should see an output similar to: ```output cbc: Runtime: Version=3.3.18, Changeset=a8e17873d167ec75338a358e54cec3994612d260 @@ -79,18 +79,19 @@ cbc: CXX: GNU 7.5.0; -fno-strict-aliasing -ggdb3 -pthread ``` +For the "cbc-pillowfight --help" command, you should see the "help" menu displayed for cbc-pillowfight. + ### Run Benchmark using cbc-pillowfight -Once Couchbase Server is running and a bucket (e.g., `benchmark`) is created, you can run a workload test using the following command: +Once Couchbase Server is running and a bucket (e.g., `benchmark`) is created, you can run a workload test using the following command (use your Couchbase administrators password): ```console cbc-pillowfight -U couchbase://127.0.0.1/benchmark \ --u Administrator -P password \ --I 10000 -B 1000 -t 5 -c 500 +-u Administrator -P password -I 10000 -B 1000 -t 5 -c 500 ``` - **-U couchbase://127.0.0.1/benchmark**: Connection string to Couchbase bucket -- **-u Administrator**: Couchbase username -- **-P password**: Couchbase password +- **-u Administrator**: Couchbase admin username (default: "Administrator") +- **-P password**: Couchbase Administrator's password - **-I 10000**: Number of items (documents) to use - **-B 1000**: Batch size for operations - **-t 5**: Number of concurrent threads @@ -114,7 +115,7 @@ http://:8091 ``` **Navigate to**: -**Dashboard → Buckets → benchmark → Metrics tab** +**Dashboard → Buckets → benchmark** Monitor real-time performance metrics such as: - **Ops/sec** — should match your CLI output @@ -124,22 +125,13 @@ Monitor real-time performance metrics such as: ![Couchbase Dashboard alt-text#center](images/arm-benchmark.png "Monitor Benchmark Log") -### Benchmark summary on x86_64 -To compare the benchmark results, the following results were collected by running the same benchmark on a `x86 - c4-standard-4` (4 vCPUs, 15 GB Memory) x86_64 VM in GCP, running SUSE: - -| **Name** | **Items** | **Resident** | **Ops/sec** | **RAM Used / Quota** | **Disk Used** | -|---------------|------------|---------------|---------------|-----------------------|---------------| -| benchmark | 10,000 | 100% | 219,961.9 | 36.9 MiB / 1 GiB | 25.3 MiB | - -### Benchmark summary on Arm64 +### Benchmark summary Results from the earlier run on the `c4a-standard-4` (4 vCPU, 16 GB memory) Arm64 VM in GCP (SUSE): | **Name** | **Items** | **Resident** | **Ops/sec** | **RAM Used / Quota** | **Disk Used** | |---------------|------------|---------------|---------------|-----------------------|---------------| | benchmark | 10,000 | 100% | 227,981.1 | 36.8 MiB / 1 GiB | 26.7 MiB | -### Couchbase benchmarking comparison on Arm64 and x86_64 - - **Operations per Second:** 227,981.1 ops/sec — indicates high throughput - **Resident Ratio:** 100% — all data served directly from memory - **RAM Usage:** 36.8 MiB used out of 1 GiB quota — highly efficient memory utilization diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/firewall_setup.md b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/firewall_setup.md new file mode 100644 index 0000000000..83cc7be2df --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/firewall_setup.md @@ -0,0 +1,42 @@ +--- +title: Create a Firewall Rule on GCP +weight: 3 + +### FIXED, DO NOT MODIFY +layout: learningpathall +--- + +## Overview + +In this section, you will learn how to create a Firewall Rule within Google Cloud Console. For this learning path, we need to expose TCP port 8091. + +{{% notice Note %}} +For support on GCP setup, see the Learning Path [Getting started with Google Cloud Platform](https://learn.arm.com/learning-paths/servers-and-cloud-computing/csp/google/). +{{% /notice %}} + +## Create a Firewall Rule in GCP + +For this learning path, we need to expose TCP port 8091. To accomplish this, we first need to create a firewall rule. +- Navigate to the [Google Cloud Console](https://console.cloud.google.com/). +- Go to **VPC Network > Firewall** and press **Create firewall rule**. + +![Create a firewall rule](images/firewall-rule.png "Create a firewall rule") + +- Next, we create the firewall rule that will expose TCP port 8091 for our learning path. +- Set the "Name" of the new rule to "allow-tcp-8091" +- Select your network that you intend to bind to your VM (default is "autoscaling-net" but your organization might have others that you need to use) +- Direction of traffic should be set to "Ingress" +- Allow on match should be set to "Allow" and the "Targets" should be set to "Specified target tags". +- Enter "allow-tcp-8091" to the "Target tags" text field +- Set the "Source IPv4 ranges" text value to "0.0.0.0/0" + +![Create a firewall rule](images/network-rule.png "Creating the TCP/8091 firewall rule") + +- Lastly, we select "Specified protocols and ports" under the "Protocols and ports" section +- Select the "TCP" checkbox +- Enter "8091" in the "Ports" text field +- Press "Create" + +![Specifying the TCP port to expose](images/network-port.png "Specifying the TCP port to expose") + +Our network firewall rule is now created so we can continue with the VM creation! \ No newline at end of file diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-1.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-1.png new file mode 100644 index 0000000000..d9156c0b50 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-1.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-2.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-2.png new file mode 100644 index 0000000000..bc4813e5f4 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-2.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-3.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-3.png new file mode 100644 index 0000000000..7d38ae3f03 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-3.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-4.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-4.png new file mode 100644 index 0000000000..dcda544d03 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/cluster-setup-4.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/couchbase.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/couchbase.png deleted file mode 100644 index 7fa90539aa..0000000000 Binary files a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/couchbase.png and /dev/null differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-1.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-1.png new file mode 100644 index 0000000000..1641f5345b Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-1.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-2.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-2.png new file mode 100644 index 0000000000..c7f4d02d90 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-2.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-3.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-3.png new file mode 100644 index 0000000000..20f5baed7c Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/create-bucket-3.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/dashboard-1.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/dashboard-1.png new file mode 100644 index 0000000000..f9ad1979b9 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/dashboard-1.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/firewall-rule.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/firewall-rule.png new file mode 100644 index 0000000000..cb2d9bf40a Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/firewall-rule.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/gcp-pubip-ssh.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/gcp-pubip-ssh.png new file mode 100644 index 0000000000..558745de3e Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/gcp-pubip-ssh.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/gcp-shell.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/gcp-shell.png new file mode 100644 index 0000000000..7e2fc3d1b5 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/gcp-shell.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-config.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-config.png new file mode 100644 index 0000000000..e590740480 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-config.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-port.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-port.png new file mode 100644 index 0000000000..b475935755 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-port.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-rule.png b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-rule.png new file mode 100644 index 0000000000..796262b07e Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/images/network-rule.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/installation.md b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/installation.md index 50187a814c..afa13edf7d 100644 --- a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/installation.md +++ b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/installation.md @@ -1,6 +1,6 @@ --- title: Install Couchbase -weight: 4 +weight: 5 ### FIXED, DO NOT MODIFY layout: learningpathall @@ -65,27 +65,30 @@ sudo systemctl enable couchbase-server sudo systemctl status couchbase-server ``` -### Prepare Couchbase Bucket -Once the service is running, you can access the **Couchbase Web Console** to create a bucket for baseline and benchmarking. +You should see the following snippet as part of your output: +```output +Active: active(running) since YYY XXXX-XX-XX +``` -Open Web Console: +### Check Required Ports +This command checks if those ports are open and active. If you see “LISTEN” next to these ports, it means Couchbase is ready to accept connections. -```console -http://:8091 -``` -Use the admin `username` and `password` you created during Couchbase setup. +Couchbase uses the following ports for basic operation: -Create a bucket named `benchmark`: +- Web Console: `8091` +- Query Service: `8093` (optional for N1QL queries) +- Data Service: `11210` -| **Parameter** | **Value** | -|----------------|-----------| -| **Bucket Name** | benchmark | -| **Bucket Type** | Couchbase | -| **RAM Quota** | 512 MB (or as per VM size) | -| **Password** | Choose a secure password (e.g., `mypassword`) | +Check if the ports are listening: -- A **bucket** in Couchbase is like a **database** — it stores and manages your data. -- The **benchmark** bucket will be used for **load testing** and **performance benchmarking**. -- Setting the **RAM Quota** ensures Couchbase allocates sufficient memory for **in-memory data operations**, improving overall speed. +```console +sudo ss -tuln | grep -E '8091|11210' +``` + +```output +tcp LISTEN 0 128 0.0.0.0:8091 0.0.0.0:* +tcp LISTEN 0 1024 0.0.0.0:11210 0.0.0.0:* +tcp LISTEN 0 1024 [::]:11210 [::]:* +``` Once the **installation and setup are complete**, you can now proceed to the **baseline testing** phase. diff --git a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/instance.md b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/instance.md index 2b93bc950d..11cd46284a 100644 --- a/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/instance.md +++ b/content/learning-paths/servers-and-cloud-computing/couchbase-on-gcp/instance.md @@ -1,6 +1,6 @@ --- title: Create a Google Axion C4A Arm virtual machine on GCP -weight: 3 +weight: 4 ### FIXED, DO NOT MODIFY layout: learningpathall @@ -26,6 +26,24 @@ To create a virtual machine based on the C4A instance type: ![Create a Google Axion C4A Arm virtual machine in the Google Cloud Console with c4a-standard-4 selected alt-text#center](images/gcp-vm.png "Creating a Google Axion C4A Arm virtual machine in Google Cloud Console") -- Under **OS and Storage**, select **Change**, then choose an Arm64-based OS image. For this Learning Path, use **SUSE Linux Enterprise Server**. Pick the preferred version for your Operating System. Ensure you select the **Arm image** variant. Click **Select**. + +- Under **OS and Storage**, select **Change**, then choose an Arm64-based OS image. For this Learning Path, use **SUSE Linux Enterprise Server**. +- If using use **SUSE Linux Enterprise Server**. Select "Pay As You Go" for the license type. +- Once appropriately selected, please Click **Select**. - Under **Networking**, enable **Allow HTTP traffic**. +- Also under **Networking**, in the "Network tags" text field add "allow-tcp-8091" as an additional tag + +![Adding the TCP/8091 firewall rule to our VM](images/network-config.png "Adding the TCP/8091 firewall rule to our VM") + - Click **Create** to launch the instance. +- Once created, you should see a "SSH" option to the right in your list of VM instances. You should also see the public IP address for your VM. +- Save off the public IP address for your VM as you will need this in the next step. +- Click on this to launch a SSH shell into your VM instance: + +![Invoke a SSH session via your browser alt-text#center](images/gcp-pubip-ssh.png "Invoke a SSH session into your running VM instance") + +- A window from your browser should come up and you should now see a shell into your VM instance: + +![Terminal Shell in your VM instance alt-text#center](images/gcp-shell.png "Terminal shell in your VM instance") + +Next, let's install Couchbase! \ No newline at end of file