Skip to content

Commit b1a6cc0

Browse files
committed
add index rebuild debug steps
1 parent defc999 commit b1a6cc0

1 file changed

Lines changed: 21 additions & 2 deletions

File tree

mkdocs/docs/advanced.md

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,12 +98,31 @@ In general the mapping update process is as follows:
9898

9999
If you are not sure if anything is happening, you can monitor your index and `docs.count` value for each index. Those values should change over time during the process and you should get an indicator of progress happening:
100100

101-
From within the ES container:
101+
From within the ES container get a list of your indexes :
102102

103103
```bash
104-
curl -u elastic:$ELASTIC_PASSWORD "localhost:9200/_cat/indices?v&s=index"
104+
curl -u elastic:$ELASTIC_PASSWORD "localhost:9200/_cat/indices/ta_*?v&s=index"
105105
```
106106

107+
### Resource already exists
108+
109+
If you get an error like `resource_already_exists_exception` for example `"index [ta_download_v2/...] already exists"`, this means a previous migration attempt was interrupted. So according to the steps outlined above:
110+
111+
- double check the available indexes first. From the example above `ta_download_v2` already exists. If the older index e.g. `ta_download` also exists, that means you can simply delete the `ta_download_v2` index:
112+
113+
```
114+
curl -u elastic:$ELASTIC_PASSWORD -XDELETE "localhost:9200/ta_download_v2"
115+
```
116+
117+
- Double check the aliases, to make sure they point to the current index version:
118+
119+
```
120+
curl -u elastic:$ELASTIC_PASSWORD "localhost:9200/_cat/aliases/ta_*?v&s=index"
121+
```
122+
123+
- if that is incorrect, refer to the [elasticsearch docs](https://www.elastic.co/docs/manage-data/data-store/aliases) on how to modify and point the alias to the correct location.
124+
- after that, restart and monitor the startup logs for any errors.
125+
107126
## Manual yt-dlp update
108127
!!! warning
109128
Doing this is **very likely** going to break things for you. You will want to try this out on a testing instance first. Regularly there have been subtle changes in the yt-dlp API, so only do this if you know how to debug this project by yourself, but obviously share your fixes so any problems can be dealt with before release.

0 commit comments

Comments
 (0)