Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document manual procedure of storage resizing #1053

Closed
wants to merge 1 commit into from
Closed

Document manual procedure of storage resizing #1053

wants to merge 1 commit into from

Conversation

Choraden
Copy link
Contributor

@Choraden Choraden commented Oct 3, 2022

Description of your changes:
At this moment we can't easily handle storage resizing it the operator. This PR documents a manual procedure.

Which issue is resolved by this Pull Request:
Resolves #825

Copy link
Contributor

@tnozicka tnozicka left a comment

Choose a reason for hiding this comment

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

I assume this also needs to be linked into an index

@@ -0,0 +1,76 @@
# Resizing storage in Scylla Cluster

Unfortunately changes in storage are currently not supported - it has to be done manually.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
Unfortunately changes in storage are currently not supported - it has to be done manually.
Due to limitations of the underlying StatefulSets, ScyllaClusters don't allow storage changes. The following procedure describes how to adjust the storage manually.


1. List Scylla Cluster
```
k get pods -n scylla
Copy link
Contributor

Choose a reason for hiding this comment

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

don't use k but kubectl (applies globally)

Copy link
Contributor

Choose a reason for hiding this comment

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

the namespace name will differ, it's easier to copy&paste if you leave it out

```
2. Orphan delete Scylla Cluster
```
kubectl delete -n scylla scyllacluster simple-cluster --cascade='orphan'
Copy link
Contributor

Choose a reason for hiding this comment

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

kubectl prefers resource/name

k get pods -n scylla

NAME READY STATUS RESTARTS AGE
simple-cluster-us-east-1-us-east-1a-0 2/2 Running 0 12m
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: might be better to use a single work for the cluster name, like basic


Unfortunately changes in storage are currently not supported - it has to be done manually.

1. List Scylla Cluster
Copy link
Contributor

Choose a reason for hiding this comment

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

this needs to say why as it doesn't do anything

```
4. Orphan delete Statefulsets
```
k delete -n scylla statefulset/simple-cluster-us-east-1-us-east-1a --cascade='orphan'
Copy link
Contributor

Choose a reason for hiding this comment

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

label selector

```
6. Change storage request
```
k -n scylla patch pvc data-simple-cluster-us-east-1-us-east-1a-0 -p '{"spec":{"resources":{"requests":{"storage":"2Gi"}}}}'
Copy link
Contributor

Choose a reason for hiding this comment

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

label selector

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm afraid, patch does not have selecting by label option.

persistentvolumeclaim/data-simple-cluster-us-east-1-us-east-1a-2 patched
```

If the following error occurred:
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
If the following error occurred:
If the PVC change is denied because the PVC doesn't support volume expansion you need replace every node following the procedure described in ...

You should continue with [replacing nodes](nodeoperations/replace_node.md).


7. Reapply Scylla Cluster
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
7. Reapply Scylla Cluster
7. Apply updated ScyllaCluster definition


7. Reapply Scylla Cluster
```
kubectl apply -f clusterDefinition.yaml
Copy link
Contributor

Choose a reason for hiding this comment

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

always use server side apply

@Choraden Choraden requested a review from tnozicka October 6, 2022 08:56
@tnozicka tnozicka mentioned this pull request Nov 18, 2022
@tnozicka
Copy link
Contributor

This PR is being closed because of inactivity. Feel free to reopen if you plan to work on it.

@tnozicka tnozicka closed this Aug 17, 2023
@vinayakakv
Copy link

We ran into the same issues in prod and following these steps.

Is it okay if I reopen the PR with instructions in k9s? Or is kubectl the preferred way?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ARCHIVED] Document and test storage resizing on the same nodes
3 participants