Skip to content

Commit 86dfae9

Browse files
committed
📚 Sync docs from alaudadevops/gitlab-ce-operator on d6630f97ce96c967898f7f3dbb36d2af1d23171b
Source: doc: enhance upgrade documentation with migration duration tips (#282) Author: nanjingfm Ref: refs/heads/release-17.8 Commit: d6630f97ce96c967898f7f3dbb36d2af1d23171b This commit automatically syncs documentation changes from the source-docs repository. 🔗 View source commit: AlaudaDevops/gitlab-ce-operator@d6630f9 🤖 Synced on 2025-11-10 09:23:28 UTC
1 parent fb0879d commit 86dfae9

File tree

2 files changed

+51
-12
lines changed

2 files changed

+51
-12
lines changed

‎.github/SYNC_INFO.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Documentation Sync Information
22

3-
- **Last synced**: 2025-11-07 07:15:32 UTC
3+
- **Last synced**: 2025-11-10 09:23:28 UTC
44
- **Source repository**: alaudadevops/gitlab-ce-operator
5-
- **Source commit**: [bd825f948336c858eca03a26aad0ae17d2f54f96](https://github.com/alaudadevops/gitlab-ce-operator/commit/bd825f948336c858eca03a26aad0ae17d2f54f96)
5+
- **Source commit**: [d6630f97ce96c967898f7f3dbb36d2af1d23171b](https://github.com/alaudadevops/gitlab-ce-operator/commit/d6630f97ce96c967898f7f3dbb36d2af1d23171b)
66
- **Triggered by**: nanjingfm
7-
- **Workflow run**: [#52](https://github.com/alaudadevops/gitlab-ce-operator/actions/runs/19161120278)
7+
- **Workflow run**: [#54](https://github.com/alaudadevops/gitlab-ce-operator/actions/runs/19226787347)
88

99
## Files synced:
1010
- docs/

‎docs/en/upgrade/02_14_upgrade_to_17.mdx‎

Lines changed: 48 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,6 @@ Versions 3.16 and 3.18 support GitLab versions that lag behind the official vers
1919

2020
## Process Overview
2121

22-
:::warning
23-
The time required for the upgrade varies significantly depending on the size of the GitLab data. It may take several days to complete the upgrade, **so it's necessary to evaluate the maintenance window in advance**.
24-
25-
Test data: Includes 3 projects (one large project of 666MB, 2 empty projects), backup file size of 668MB, upgrade time of 8 hours.
26-
:::
27-
2822
### Data Migration Path
2923

3024
According to the [official upgrade path](https://gitlab-com.gitlab.io/support/toolbox/upgrade-path/?current=14.0.12&target=17.8.1&distro=docker&edition=ce) documentation, the data migration path is as follows:
@@ -58,6 +52,28 @@ Back up the `platform-deployed` GitLab and restore it to an `all-in-one` image d
5852
For the latest GitLab instance and operator versions, please refer to the [Release Note](../overview/release_notes.mdx).
5953
:::
6054

55+
:::tip Migration Duration
56+
The migration process involves database and repository backup/restore operations:
57+
58+
- Larger databases increase migration time.
59+
- A higher number of repositories or larger single repositories significantly extends the duration.
60+
- Storage performance also impacts efficiency — using topolvm is recommended for better performance.
61+
62+
Test setup:
63+
64+
- One large repository (~600 MB), others are small initial repositories
65+
- GitLab instance: 6,700 issues, 3,600 merge requests
66+
67+
|Migration Step | Key Factor | 1,000 Repos |10,000 Repos|
68+
|----|---|---|---|
69+
|Back up platform-deployed GitLab 14.0.12 | Repo size & count | 10 min | 30 min|
70+
|Restore to all-in-one GitLab 14.0.12 |Repo size & count | 20 min | 1 hr|
71+
|Rolling upgrade to GitLab 17.8.1 | Database size | 1 hr 30 min | 1 hr 40 min|
72+
|Back up all-in-one GitLab 17.8.1 | Repo size & count | 3 min | 10 min|
73+
|Restore to platform-deployed GitLab | Repo size & count | 30 min | 1 hr|
74+
75+
:::
76+
6177

6278
## Prerequisites
6379

@@ -332,7 +348,14 @@ For the latest GitLab instance and operator versions, please refer to the [Relea
332348
333349
echo "Waiting for migrations to finish..."
334350
kubectl -n $GITLAB_NAMESPACE cp finalize_migrations.sql $new_pod_name:/tmp/finalize_migrations.sql
335-
kubectl -n $GITLAB_NAMESPACE exec -ti $new_pod_name -- bash -c "gitlab-psql -t -A -f /tmp/finalize_migrations.sql > /tmp/run_migration_tasks.sh && bash -x /tmp/run_migration_tasks.sh"
351+
for i in {1..3}; do
352+
echo "Running migration tasks (attempt $i/3)..."
353+
if kubectl -n $GITLAB_NAMESPACE exec -ti $new_pod_name -- bash -c "gitlab-psql -t -A -f /tmp/finalize_migrations.sql > /tmp/run_migration_tasks.sh && xargs -d \"\n\" -P 3 -I {} bash -c \"{}\" < /tmp/run_migration_tasks.sh"; then
354+
echo "Migration tasks completed successfully"
355+
break
356+
fi
357+
sleep 20
358+
done
336359
bash monitor_gitlab.sh $new_pod_name
337360
echo "Upgraded to ${version} successfully"
338361
mark_done "$version"
@@ -550,10 +573,10 @@ For the latest GitLab instance and operator versions, please refer to the [Relea
550573
protocol: TCP
551574
resources:
552575
limits:
553-
cpu: "4"
576+
cpu: "8"
554577
memory: 8Gi
555578
requests:
556-
cpu: 2
579+
cpu: 4
557580
memory: "4Gi"
558581
securityContext:
559582
privileged: true
@@ -632,6 +655,22 @@ For the latest GitLab instance and operator versions, please refer to the [Relea
632655
kubectl -n $GITLAB_NAMESPACE cp all-in-one-gitlab-secrets.json $pod_name:/etc/gitlab/gitlab-secrets.json
633656
```
634657
658+
Disable unnecessary components.
659+
660+
```bash
661+
cat <<EOF >> gitlab.rb
662+
prometheus['enable'] = false
663+
gitlab_kas['enable'] = false
664+
redis_exporter['enable'] = false
665+
gitlab_exporter['enable'] = false
666+
postgres_exporter['enable'] = false
667+
sidekiq['enable'] = false
668+
EOF
669+
670+
# Copy the gitlab.rb to the pod
671+
kubectl -n $GITLAB_NAMESPACE cp gitlab.rb $pod_name:/etc/gitlab/gitlab.rb
672+
```
673+
635674
Restart the pod and wait for it to start up.
636675
637676
```bash

0 commit comments

Comments
 (0)