meilisearch: Can't create index (OS error 22)
Describe the bug Can’t create index
To Reproduce
cargo run
in meilisearch root folder
curl
-X POST 'http://localhost:7700/indexes'
-H 'Content-Type: application/json'
--data-binary '{
"uid": "movies",
"primaryKey": "id"
}'
Response:
{
"taskUid": 0,
"indexUid": "movies",
"status": "enqueued",
"type": "indexCreation",
"enqueuedAt": "2022-11-01T08:44:00.269189619Z"
}
curl \
-X GET 'http://localhost:7700/tasks/0'
Response:
{
"uid": 0,
"indexUid": "movies",
"status": "failed",
"type": "indexCreation",
"details": {
"primaryKey": "id"
},
"error": {
"message": "Invalid argument (os error 22)",
"code": "internal",
"type": "internal",
"link": "https://docs.meilisearch.com/errors#internal"
},
"duration": "PT0.000368400S",
"enqueuedAt": "2022-11-01T08:44:00.269189619Z",
"startedAt": "2022-11-01T08:44:00.274817501Z",
"finishedAt": "2022-11-01T08:44:00.275185901Z"
}
Expected behavior
I expected the "status"
field to be "succeeded"
rather than "failed"
in the response from curl -X GET 'http://localhost:7700/tasks/0'
Screenshots
Attempting to post index:
Attempting to get indexes:
Checking task status:
Meilisearch version: [e.g. v0.20.0] 0.28.1
Additional context Additional information that may be relevant to the issue. [e.g. architecture, device, OS, browser] OS: Archlinux Architecture: x86_64
EDITED by @curquiza & @dureuill
- Implement changes in Milli https://github.com/meilisearch/milli/pull/699)
- Release a Milli version containing these changes
- Bump this new Milli version in Meilisearch and merge it into
release-v0.30.0
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 17 (16 by maintainers)
Commits related to this issue
- Merge #693 693: use the lmdb-master.3 branch r=Kerollmops a=irevoire After investigating https://github.com/meilisearch/meilisearch/issues/3017, we found out that it was due to lmdb and that, withou... — committed to meilisearch/milli by bors[bot] 2 years ago
- Merge #3035 3035: Bump milli to v0.36.0 r=irevoire a=Kerollmops This PR bumps milli to v0.36.0 which brings some fixes and a new version of LMDB that is based on `lmdb-master.3`. Fix #3017 Co-au... — committed to meilisearch/meilisearch by bors[bot] 2 years ago
- Merge #699 699: Force vendoring of LMDB even if a system version is available r=irevoire a=dureuill # Pull Request ## Related issue Related to https://github.com/meilisearch/meilisearch/issues/3... — committed to meilisearch/milli by bors[bot] 2 years ago
- Merge #699 699: Force vendoring of LMDB even if a system version is available r=irevoire a=dureuill # Pull Request ## Related issue Related to https://github.com/meilisearch/meilisearch/issues/3... — committed to meilisearch/milli by bors[bot] 2 years ago
- Merge #699 699: Force vendoring of LMDB even if a system version is available r=irevoire a=dureuill # Pull Request ## Related issue Related to https://github.com/meilisearch/meilisearch/issues/3... — committed to meilisearch/milli by bors[bot] 2 years ago
- Merge #699 699: Force vendoring of LMDB even if a system version is available r=Kerollmops a=dureuill # Pull Request ## Related issue Related to https://github.com/meilisearch/meilisearch/issues... — committed to meilisearch/milli by bors[bot] 2 years ago
- community/meilisearch: upgrade to 1.1.1 meilisearch doesn't allow linking lmdb-sys with system-provided lmdb library anymore. See #14799 and https://github.com/meilisearch/meilisearch/issues/3017. C... — committed to alpinelinux/aports by d5ng4i a year ago
- community/garage: build with lmdb Unfortunately, 'heed' doesn't support building against system-provided lmdb library due to previous problems (see #14799, https://github.com/meilisearch/meilisearch/... — committed to alpinelinux/aports by jirutka a year ago
I reproduced the issue on an up-to-date KDE Archlinux and think I have a fix:
lmdb-sys
package using the system’s version of lmdb if it is installedlmdb-sys
to always use the vendored version appears to fix the issue. Adding avendored
feature like is done in https://lib.rs/crates/libgit2-sys is a way of adding this behavior back-compatiblyvendored
feature tolmdb-rs
and make sure we make use of it inmeilisearch
lmdb-rs
PR is here,heed
andmilli
PRs incomingThanks for explanation! Even though it’s not related to me or users, I’m still curious about your process of solving the issue since I might learn something useful that I might use in my own problem-solving. Especially small and easily digested pieces of info.
why is this closed when there are 2 tasks left?
A “dependency bump” means “upgrade a dependency”, is a common term used, see for example this random tutorial I found when typing “bump dependency” on Google
But no worry with this @amab8901, @irevoire was writing this for traceability and for helping his own team internally to investigate the bug. Nothing related to you or any users.