-
Notifications
You must be signed in to change notification settings - Fork 460
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
Add Documentation for Replication Using a Load Balancer #2375
Open
cniackz
wants to merge
1
commit into
master
Choose a base branch
from
add-replication-docs
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -131,3 +131,58 @@ spec: | |||||||||||
port: | ||||||||||||
number: 9443 | ||||||||||||
``` | ||||||||||||
|
||||||||||||
### Replication configuration: | ||||||||||||
|
||||||||||||
Sometimes, you need to configure timeout in order to avoid Load Balancer to kill the connection while replication is taking place, for that, we can configure a read/write timeout of X minutes in the provided load balancer, you can add the appropriate NGINX annotations to your ingress configuration under `metadata.annotations`. The relevant annotations are: | ||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Rec based on Anis comment:
Suggested change
|
||||||||||||
|
||||||||||||
* `nginx.ingress.kubernetes.io/proxy-read-timeout`: Controls how long the NGINX load balancer waits for a response from the backend. | ||||||||||||
|
||||||||||||
* `nginx.ingress.kubernetes.io/proxy-send-timeout`: Controls how long the NGINX load balancer waits to send a request to the backend. | ||||||||||||
|
||||||||||||
Here is the updated ingress configuration: | ||||||||||||
|
||||||||||||
```yaml | ||||||||||||
apiVersion: networking.k8s.io/v1 | ||||||||||||
kind: Ingress | ||||||||||||
metadata: | ||||||||||||
name: ingress-minio | ||||||||||||
namespace: tenant1-ns | ||||||||||||
annotations: | ||||||||||||
kubernetes.io/ingress.class: "nginx" | ||||||||||||
## Remove if using CA signed certificate | ||||||||||||
nginx.ingress.kubernetes.io/proxy-ssl-verify: "off" | ||||||||||||
nginx.ingress.kubernetes.io/backend-protocol: "HTTPS" | ||||||||||||
nginx.ingress.kubernetes.io/rewrite-target: / | ||||||||||||
nginx.ingress.kubernetes.io/proxy-body-size: "0" | ||||||||||||
nginx.ingress.kubernetes.io/server-snippet: | | ||||||||||||
client_max_body_size 0; | ||||||||||||
nginx.ingress.kubernetes.io/configuration-snippet: | | ||||||||||||
chunked_transfer_encoding off; | ||||||||||||
nginx.ingress.kubernetes.io/proxy-read-timeout: "60s" | ||||||||||||
nginx.ingress.kubernetes.io/proxy-send-timeout: "60s" | ||||||||||||
Comment on lines
+162
to
+163
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Q: Is there a value here we would consider to be too high? We have internal timeouts as well. Just curious. |
||||||||||||
spec: | ||||||||||||
tls: | ||||||||||||
- hosts: | ||||||||||||
- minio.example.com | ||||||||||||
secretName: nginx-tls | ||||||||||||
rules: | ||||||||||||
- host: minio.example.com | ||||||||||||
http: | ||||||||||||
paths: | ||||||||||||
- path: / | ||||||||||||
pathType: Prefix | ||||||||||||
backend: | ||||||||||||
service: | ||||||||||||
name: minio | ||||||||||||
port: | ||||||||||||
number: 443 | ||||||||||||
``` | ||||||||||||
|
||||||||||||
> Explanation: | ||||||||||||
|
||||||||||||
* `proxy-read-timeout`: Ensures that NGINX waits for 60 seconds for a response from the MinIO backend before timing out. | ||||||||||||
|
||||||||||||
* `proxy-send-timeout`: Ensures that NGINX waits for 60 seconds for data to be sent to the MinIO backend before timing out. | ||||||||||||
|
||||||||||||
Apply the updated configuration using `kubectl apply -f <file_name>.yaml`. This will set the desired timeouts for read and write operations. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not necessarly related to replication, this is mainly a very slow deployment or best practice were not followed, like a user storing a lot of objects under a single prefix
the one here works most of the time,
https://min.io/docs/minio/linux/integrations/setup-nginx-proxy-with-minio.html