Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
Documentation
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
DevOps Tools
Documentation
Commits
5a314356
Commit
5a314356
authored
4 years ago
by
jurgenhaas
Browse files
Options
Downloads
Patches
Plain Diff
Correct variable names
parent
3aa3eaed
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#35761
passed
4 years ago
Stage: build
Stage: deploy
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
docs/ansible/wiki/elk/re-indexing.md
+6
-6
6 additions, 6 deletions
docs/ansible/wiki/elk/re-indexing.md
with
6 additions
and
6 deletions
docs/ansible/wiki/elk/re-indexing.md
+
6
−
6
View file @
5a314356
...
...
@@ -13,13 +13,13 @@ We use `$IDX` for the existing, e.g. broken index and `$IDXNEW` for the new one.
## Show number of records for all indexes
```
shell
curl
-X
GET
'
http://${E
L
USER}:${E
L
PASS}@localhost:9200/
/
_cat/indices/%2A?v=&s=index:desc
'
curl
-X
GET http://
${
E
S
USER
}
:
${
E
S
PASS
}
@localhost:9200/_cat/indices/%2A?v
=
&s
=
index:desc
```
## Create new index with mappings
```
shell
curl
-X
PUT http://
${
E
L
USER
}
:
${
E
L
PASS
}
@localhost:9200/
$IDXNEW
\
curl
-X
PUT http://
${
E
S
USER
}
:
${
E
S
PASS
}
@localhost:9200/
$IDXNEW
\
-H
'Content-Type: application/json'
\
-d
'{
"mappings": {
...
...
@@ -33,7 +33,7 @@ curl -X PUT http://${ELUSER}:${ELPASS}@localhost:9200/$IDXNEW \
## Re-index from old to new index
```
shell
curl
-X
POST http://
${
E
L
USER
}
:
${
E
L
PASS
}
@localhost:9200/_reindex
\
curl
-X
POST http://
${
E
S
USER
}
:
${
E
S
PASS
}
@localhost:9200/_reindex
\
-H
'Content-Type: application/json'
\
-d
'{
"source": {
...
...
@@ -48,13 +48,13 @@ curl -X POST http://${ELUSER}:${ELPASS}@localhost:9200/_reindex \
## Delete the old index
```
shell
curl
-X
DELETE http://
${
E
L
USER
}
:
${
E
L
PASS
}
@localhost:9200/
$IDX
curl
-X
DELETE http://
${
E
S
USER
}
:
${
E
S
PASS
}
@localhost:9200/
$IDX
```
## Delete and recreate alias
```
shell
curl
-X
POST http://
${
E
L
USER
}
:
${
E
L
PASS
}
@localhost:9200/_aliases
\
curl
-X
POST http://
${
E
S
USER
}
:
${
E
S
PASS
}
@localhost:9200/_aliases
\
-H
'Content-Type: application/json'
\
-d
'{
"actions": [
...
...
@@ -69,7 +69,7 @@ curl -X POST http://${ELUSER}:${ELPASS}@localhost:9200/_aliases \
```
```
shell
curl
-X
POST http://
${
E
L
USER
}
:
${
E
L
PASS
}
@localhost:9200/_aliases
\
curl
-X
POST http://
${
E
S
USER
}
:
${
E
S
PASS
}
@localhost:9200/_aliases
\
-H
'Content-Type: application/json'
\
-d
'{
"actions": [
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment