Commit 8e09ece1 authored by Achilleas Pipinellis's avatar Achilleas Pipinellis

Merge branch 'fix-elasticsearch-docs-for-envvars' into 'master'

Fix elasticsearch docs: ID=1 sudo ... is ineffective

See merge request !1573
parents c506df04 3aac918e
...@@ -101,7 +101,7 @@ Indexing is 65.55% complete (6555/10000 projects) ...@@ -101,7 +101,7 @@ Indexing is 65.55% complete (6555/10000 projects)
By default, one job is created for every 300 projects. For large numbers of By default, one job is created for every 300 projects. For large numbers of
projects, you may wish to increase the batch size, by setting the `BATCH` projects, you may wish to increase the batch size, by setting the `BATCH`
environment variable. You may also wish to consider [throttling](../administration/operations/sidekiq_job_throttling.md) environment variable. You may also wish to consider [throttling](../administration/operations/sidekiq_job_throttling.md)
the `elastic_batch_project_indexer` queue , as this step can be I/O-intensive. the `elastic_batch_project_indexer` queue, as this step can be I/O-intensive.
You can also run the initial indexing synchronously - this is most useful if You can also run the initial indexing synchronously - this is most useful if
you have a small number of projects, or need finer-grained control over indexing you have a small number of projects, or need finer-grained control over indexing
...@@ -121,16 +121,16 @@ If you want to run several tasks in parallel (probably in separate terminal ...@@ -121,16 +121,16 @@ If you want to run several tasks in parallel (probably in separate terminal
windows) you can provide the `ID_FROM` and `ID_TO` parameters: windows) you can provide the `ID_FROM` and `ID_TO` parameters:
``` ```
ID_FROM=1001 ID_TO=2000 sudo gitlab-rake gitlab:elastic:index_repositories sudo gitlab-rake gitlab:elastic:index_repositories ID_FROM=1001 ID_TO=2000
``` ```
Where `ID_FROM` and `ID_TO` are project IDs. Both parameters are optional. Where `ID_FROM` and `ID_TO` are project IDs. Both parameters are optional.
As an example, if you have 3,000 repositories and you want to run three separate indexing tasks, you might run: As an example, if you have 3,000 repositories and you want to run three separate indexing tasks, you might run:
``` ```
ID_TO=1000 sudo gitlab-rake gitlab:elastic:index_repositories sudo gitlab-rake gitlab:elastic:index_repositories ID_TO=1000
ID_FROM=1001 ID_TO=2000 sudo gitlab-rake gitlab:elastic:index_repositories sudo gitlab-rake gitlab:elastic:index_repositories ID_FROM=1001 ID_TO=2000
ID_FROM=2001 sudo gitlab-rake gitlab:elastic:index_repositories sudo gitlab-rake gitlab:elastic:index_repositories ID_FROM=2001
``` ```
Sometimes your repository index process `gitlab:elastic:index_repositories` or Sometimes your repository index process `gitlab:elastic:index_repositories` or
...@@ -144,7 +144,7 @@ it will check every project repository again to make sure that every commit in ...@@ -144,7 +144,7 @@ it will check every project repository again to make sure that every commit in
that repository is indexed, it can be useful in case if your index is outdated: that repository is indexed, it can be useful in case if your index is outdated:
``` ```
UPDATE_INDEX=true ID_TO=1000 sudo gitlab-rake gitlab:elastic:index_repositories sudo gitlab-rake gitlab:elastic:index_repositories UPDATE_INDEX=true ID_TO=1000
``` ```
You can also use the `gitlab:elastic:clear_index_status` Rake task to force the You can also use the `gitlab:elastic:clear_index_status` Rake task to force the
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment