Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
bab22868
Commit
bab22868
authored
Jan 19, 2022
by
Evan Read
Committed by
Craig Norris
Jan 19, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Clarify that migrations are for the database
parent
768b03ba
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
doc/administration/gitaly/praefect.md
doc/administration/gitaly/praefect.md
+8
-8
No files found.
doc/administration/gitaly/praefect.md
View file @
bab22868
...
@@ -408,7 +408,7 @@ On the **Praefect** node:
...
@@ -408,7 +408,7 @@ On the **Praefect** node:
# Enable only the Praefect service
# Enable only the Praefect service
praefect
[
'enable'
]
=
true
praefect
[
'enable'
]
=
true
#
P
revent database connections during 'gitlab-ctl reconfigure'
#
Disable database migrations to p
revent database connections during 'gitlab-ctl reconfigure'
gitlab_rails
[
'auto_migrate'
]
=
false
gitlab_rails
[
'auto_migrate'
]
=
false
praefect
[
'auto_migrate'
]
=
false
praefect
[
'auto_migrate'
]
=
false
```
```
...
@@ -531,7 +531,7 @@ On the **Praefect** node:
...
@@ -531,7 +531,7 @@ On the **Praefect** node:
1.
For:
1.
For:
-
The "deploy node":
-
The "deploy node":
1.
Enable Praefect auto-migration again by setting
`praefect['auto_migrate'] = true`
in
1.
Enable Praefect
database
auto-migration again by setting
`praefect['auto_migrate'] = true`
in
`/etc/gitlab/gitlab.rb`
.
`/etc/gitlab/gitlab.rb`
.
1.
To ensure database migrations are only run during reconfigure and not automatically on
1.
To ensure database migrations are only run during reconfigure and not automatically on
upgrade, run:
upgrade, run:
...
@@ -767,7 +767,7 @@ For more information on Gitaly server configuration, see our
...
@@ -767,7 +767,7 @@ For more information on Gitaly server configuration, see our
# Enable Prometheus if needed
# Enable Prometheus if needed
prometheus
[
'enable'
]
=
true
prometheus
[
'enable'
]
=
true
#
P
revent database connections during 'gitlab-ctl reconfigure'
#
Disable database migrations to p
revent database connections during 'gitlab-ctl reconfigure'
gitlab_rails
[
'auto_migrate'
]
=
false
gitlab_rails
[
'auto_migrate'
]
=
false
```
```
...
@@ -1229,9 +1229,9 @@ To migrate existing clusters:
...
@@ -1229,9 +1229,9 @@ To migrate existing clusters:
1.
Praefect nodes didn't historically keep database records of every repository stored on the cluster. When
1.
Praefect nodes didn't historically keep database records of every repository stored on the cluster. When
the
`per_repository`
election strategy is configured, Praefect expects to have database records of
the
`per_repository`
election strategy is configured, Praefect expects to have database records of
each repository. A
[
background migration
](
https://gitlab.com/gitlab-org/gitaly/-/merge_requests/2749
)
is
each repository. A
[
background
database
migration
](
https://gitlab.com/gitlab-org/gitaly/-/merge_requests/2749
)
is
included in GitLab 13.6 and later to create any missing database records for repositories. Before migrating
included in GitLab 13.6 and later to create any missing database records for repositories. Before migrating
,
you should verify the migration has run by checking Praefect's logs:
check Praefect's logs to verify that the database migration ran.
Check Praefect's logs for
`repository importer finished`
message. The
`virtual_storages`
field contains
Check Praefect's logs for
`repository importer finished`
message. The
`virtual_storages`
field contains
the names of virtual storages and whether they've had any missing database records created.
the names of virtual storages and whether they've had any missing database records created.
...
@@ -1248,8 +1248,8 @@ To migrate existing clusters:
...
@@ -1248,8 +1248,8 @@ To migrate existing clusters:
{
"level"
:
"info"
,
"msg"
:
"repository importer finished"
,
"pid"
:
19752
,
"time"
:
"2021-04-28T11:41:36.743Z"
,
"virtual_storages"
:{
"default"
:
false
}}
{
"level"
:
"info"
,
"msg"
:
"repository importer finished"
,
"pid"
:
19752
,
"time"
:
"2021-04-28T11:41:36.743Z"
,
"virtual_storages"
:{
"default"
:
false
}}
```
```
The
migration is ran when Praefect starts up. If th
e migration is unsuccessful, you can restart
The
database migration runs when Praefect starts. If the databas
e migration is unsuccessful, you can restart
a Praefect node to reattempt it.
The migration only runs with
`sql`
election strategy configured.
a Praefect node to reattempt it.
1.
Running two different election strategies side by side can cause a split brain, where different
1.
Running two different election strategies side by side can cause a split brain, where different
Praefect nodes consider repositories to have different primaries. This can be avoided either:
Praefect nodes consider repositories to have different primaries. This can be avoided either:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment