Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions k8s-suse-rancher-prime-air-gapped.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ helm upgrade --install \
--create-namespace \
--values $VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/sizing_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/affinity_values.yaml \
--values private-registry.yaml \
suse-observability \
suse-observability-A.B.C.tgz
Expand Down
12 changes: 9 additions & 3 deletions k8s-suse-rancher-prime.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,9 @@ The `baseUrl` must be the URL via which SUSE Observability will be accessible to

The `sizing.profile` should be one of trial, 10-nonha, 20-nonha, 50-nonha, 100-nonha, 150-ha, 250-ha, 500-ha. Based on this profiles the `sizing_values.yaml` file is generated containing default sizes for the SUSE Observability resources and configuration to be deployed on an Ha or NonHa mode. E.g. 10-nonha will produce a `sizing_values.yaml` meant to deploy a NonHa SUSE Observability instance to observe a 10 node cluster in a Non High Available mode. Currently moving from a nonha to an ha environment is not possible, so if you expect that your environment willrequire to observe around 150 nodes then better to go with ha immediately.

This command will generate a `$VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml` and a `$VALUES_DIR/suse-observability-values/templates/sizing_values.yaml` file which contains the necessary configuration for installing the SUSE Observability Helm Chart.
The `affinity_values.yaml` file with K8s affinities to deploy Stackstate with different scheduling options.

This command will generate `$VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml`, `$VALUES_DIR/suse-observability-values/templates/sizing_values.yaml`, and `$VALUES_DIR/suse-observability-values/templates/affinity_values.yaml` files which contains the necessary configuration for installing the SUSE Observability Helm Chart.

{% hint style="info" %}
The SUSE Observability administrator password will be autogenerated by the above command and are output as comments in the generated `basicConfig.yaml` file. For more info, see [single password](/setup/security/authentication/single_password.md).
Expand All @@ -174,10 +176,14 @@ Using a single default password is great to get started with SUSE Observability,
{% endhint %}

{% hint style="info" %}
Store the generated `basicConfig.yaml` and `sizing_values.yaml` files somewhere safe. You can reuse this files for upgrades, which will save time and \(more importantly\) will ensure that SUSE Observability continues to use the same API key. This is desirable as it means Agents and other data providers for SUSE Observability won't need to be updated.
Store the generated `basicConfig.yaml`, `sizing_values.yaml`, and `affinity_values.yaml` files somewhere safe. You can reuse this files for upgrades, which will save time and \(more importantly\) will ensure that SUSE Observability continues to use the same API key. This is desirable as it means Agents and other data providers for SUSE Observability won't need to be updated.
The files can be regenerated independently using the switches `basicConfig.generate=false` and `sizing.generate=false` to disable any of them while still keeping the previosuly generated version of the file in the `output-dir`.
{% endhint %}

{% hint style="info" %}
The Suse Observability Values chart generates affinity configurations that can be used by the main SUSE Observability chart to control pod scheduling behavior. Please check [SUSE Observability Affinity Configuration])(affinity.md) for more information.
{% endhint %}

3. Deploy the SUSE Observability helm chart with the generated values:

{% code title="helm_deploy.sh" lineNumbers="true" %}
Expand All @@ -187,6 +193,7 @@ helm upgrade --install \
--create-namespace \
--values $VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/sizing_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/affinity_values.yaml \
suse-observability \
suse-observability/suse-observability
```
Expand Down Expand Up @@ -260,4 +267,3 @@ To enable Single sign-on with your own authentication provider please [see here]
1. After the extensions are installed, the SUSE Observability UI opens in the same tab as the Rancher UI.
* You can use shift-click to open in a new tab, this will become the default behaviour
1. Be aware upgrading or downgrading from HA to NON-HA and vice-versa is not yet supported.

1 change: 1 addition & 0 deletions setup/install-stackstate/kubernetes_openshift/ack.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ helm upgrade \
--namespace suse-observability \
--values $VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/sizing_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/affinity_values.yaml \
--values ack-values.yaml \
suse-observability \
suse-observability/suse-observability
Expand Down
122 changes: 122 additions & 0 deletions setup/install-stackstate/kubernetes_openshift/affinity.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
---
description: SUSE Observability Affinity Configuration
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a new file. To get it published using Gitbook it needs to be included somewhere in the SUMMARY.md. But I guess, now that this needs to be moved to the new docs-site, things will be different but I would expect the file still needs to be added to the sidebar.

---

# Affinity Values Configuration

The Suse Observability Values chart generates affinity configurations that can be used by the main SUSE Observability chart to control pod scheduling behavior. The affinity values help optimize resource utilization and ensure high availability by controlling where pods are scheduled.

## Available Configuration Options

### Node Affinity

Node affinity is used to schedule pods to specific nodes or instance groups, such as EC2 nodes deployed to the same availability zone.

```yaml
affinity:
# Node Affinity settings - applied to all components when configured
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: topology.kubernetes.io/zone
operator: In
values:
- us-west-2a
```

### Pod Anti-Affinity

Pod anti-affinity is used to schedule replicas of data services to different nodes to ensure high availability. By default, the scheduling is required (hard anti-affinity).

```yaml
affinity:
podAntiAffinity:
# Enable required pod anti-affinity (true = hard, false = soft)
requiredDuringSchedulingIgnoredDuringExecution: true
# Topology key for pod anti-affinity
topologyKey: "kubernetes.io/hostname"
```

## Behavior

### Node Affinity
- **When configured**: Applied to all data service components
- **Components affected**: clickhouse, elasticsearch, hbase, kafka, zookeeper, victoria-metrics, stackstate, opentelemetry-collector

### Pod Anti-Affinity
- **When configured**: Only applied when `sizing.profile` ends with `-ha` (High Availability profiles)
- **HA Profiles**: `150-ha`, `250-ha`, `500-ha`, `4000-ha`
- **Components affected**: All stateful data services including clickhouse, kafka, zookeeper, victoria-metrics, hbase components, elasticsearch

## Example Configurations

### Basic Node Affinity (Same Availability Zone) + Pod Anti-Affinity for HA Deployment
```yaml
affinity:
# Schedule all pods to nodes in the same AZ
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: topology.kubernetes.io/zone
operator: In
values:
- us-west-2a

# Ensure replicas are distributed across different nodes
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution: true
topologyKey: "kubernetes.io/hostname"
```

## Usage

### Step 1: Create Your Affinity Values File

Create a separate values file with your desired affinity configuration. For example, save the following as `suse-observability-values-values.yaml`:

```yaml
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: topology.kubernetes.io/zone
operator: In
values:
- us-west-2a
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution: true
topologyKey: "kubernetes.io/hostname"
```

### Step 2: Generate Affinity Template Values

Run the following command to generate the affinity values template:

```text
export VALUES_DIR=.
helm template \
--set license='<your license>' \
--set baseUrl='<suse-observability-base-url>' \
--set sizing.profile='<sizing.profile>' \
--values suse-observability-values-values.yaml \
suse-observability-values \
suse-observability/suse-observability-values --output-dir $VALUES_DIR
```

### Step 3: Use Generated Values in Helm Installation

Include the generated affinity values in your Helm installation:

```bash
helm upgrade \
--install \
--namespace suse-observability \
--values $VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/sizing_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/affinity_values.yaml \
suse-observability \
suse-observability/suse-observability
```
3 changes: 2 additions & 1 deletion setup/install-stackstate/kubernetes_openshift/ingress.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ helm upgrade --install \
--values "ingress_values.yaml" \
--values $VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/sizing_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/affinity_values.yaml \
suse-observability \
suse-observability/suse-observability
```
Expand Down Expand Up @@ -108,6 +109,7 @@ helm upgrade \
--values "ingress_otel_values.yaml" \
--values $VALUES_DIR/suse-observability-values/templates/baseConfig_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/sizing_values.yaml \
--values $VALUES_DIR/suse-observability-values/templates/affinity_values.yaml \
suse-observability \
suse-observability/suse-observability
```
Expand Down Expand Up @@ -144,4 +146,3 @@ Agents that are deployed to the same cluster as SUSE Observability can of course
* [AKS \(learn.microsoft.com\)](https://learn.microsoft.com/en-us/azure/aks/ingress-tls?tabs=azure-cli)
* [EKS Official docs](https://docs.aws.amazon.com/eks/latest/userguide/alb-ingress.html) \(not using nginx\)
* [EKS blog post](https://aws.amazon.com/blogs/opensource/network-load-balancer-nginx-ingress-controller-eks/) \(using nginx\)

Loading