[GH-ISSUE #1825] [BUG]: addDocumentToNamespace LanceDBError : Operation not supported (os error 95) #1188

Closed
opened 2026-02-22 18:23:36 -05:00 by yindo · 5 comments
Owner

Originally created by @aprt06 on GitHub (Jul 7, 2024).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1825

How are you running AnythingLLM?

Docker (remote machine)

What happened?

I use k8s on this app .mount the path /app/server/storage/ to azure file share. the lancedb is selected as DB . the chat is ok and the upload is work fine but this error happens when I move file to work space
[backend] info: Chunks created from document: [backend] info: Inserting vectorized chunks into LanceDB collection. [backend] error: addDocumentToNamespace [backend] error: Failed to vectorize
addDocumentToNamespace LanceDBError: LanceError(IO): Generic LocalFileSystem error: Unable to copy file from /app/server/storage/lancedb/hello-world2.lance/_versions/.tmp_1.manifest_6fd3dc1e-e164-4235-ba8d-0045de339d5f to /app/server/storage/lancedb/hello-world2.lance/_versions/1.manifest: Operation not supported (os error 95), /rustc/07dca489ac2d933c78d3c5158e3f43beefeb02ce/library/core/src/convert/mod.rs:757:9

Are there known steps to reproduce?

Hi everyone , for my case . I use k8s on this app and my path mount is /app/server/storage the lancedb was selected and the upload was work fine but This happens when I move file to work space

addDocumentToNamespace LanceDBError: LanceError(IO): Generic LocalFileSystem error: Unable to copy file from /app/server/storage/lancedb/hello-world2.lance/_versions/.tmp_1.manifest_6fd3dc1e-e164-4235-ba8d-0045de339d5f to /app/server/storage/lancedb/hello-world2.lance/_versions/1.manifest: Operation not supported (os error 95), /rustc/07dca489ac2d933c78d3c5158e3f43beefeb02ce/library/core/src/convert/mod.rs:757:9

Screenshot 2024-07-05 163511

Originally created by @aprt06 on GitHub (Jul 7, 2024). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1825 ### How are you running AnythingLLM? Docker (remote machine) ### What happened? I use k8s on this app .mount the path /app/server/storage/ to azure file share. the lancedb is selected as DB . the chat is ok and the upload is work fine but this error happens when I move file to work space `[backend] info: Chunks created from document: [backend] info: Inserting vectorized chunks into LanceDB collection. [backend] error: addDocumentToNamespace [backend] error: Failed to vectorize` addDocumentToNamespace LanceDBError: LanceError(IO): Generic LocalFileSystem error: Unable to copy file from /app/server/storage/lancedb/hello-world2.lance/_versions/.tmp_1.manifest_6fd3dc1e-e164-4235-ba8d-0045de339d5f to /app/server/storage/lancedb/hello-world2.lance/_versions/1.manifest: Operation not supported (os error 95), /rustc/07dca489ac2d933c78d3c5158e3f43beefeb02ce/library/core/src/convert/mod.rs:757:9 ### Are there known steps to reproduce? Hi everyone , for my case . I use k8s on this app and my path mount is /app/server/storage the lancedb was selected and the upload was work fine but This happens when I move file to work space `addDocumentToNamespace LanceDBError: LanceError(IO): Generic LocalFileSystem error: Unable to copy file from /app/server/storage/lancedb/hello-world2.lance/_versions/.tmp_1.manifest_6fd3dc1e-e164-4235-ba8d-0045de339d5f to /app/server/storage/lancedb/hello-world2.lance/_versions/1.manifest: Operation not supported (os error 95), /rustc/07dca489ac2d933c78d3c5158e3f43beefeb02ce/library/core/src/convert/mod.rs:757:9` ![Screenshot 2024-07-05 163511](https://github.com/Mintplex-Labs/anything-llm/assets/10378077/de42a774-8145-4b48-9582-3b4cd0dadc40)
yindo added the possible bug label 2026-02-22 18:23:36 -05:00
yindo closed this issue 2026-02-22 18:23:36 -05:00
Author
Owner

@timothycarambat commented on GitHub (Jul 8, 2024):

This is because for whatever reason the application and/or docker user does not have write permissions on the /app folder - or more likely where the /app folder for the docker container is bound to. In most cases it should be some $HOME directory for the host - something easily writable

@timothycarambat commented on GitHub (Jul 8, 2024): This is because for whatever reason the application and/or docker user does not have write permissions on the `/app` folder - or more likely where the `/app` folder for the docker container is bound to. In most cases it should be some `$HOME` directory for the host - something easily writable
Author
Owner

@ccr-fan-3000 commented on GitHub (Aug 1, 2024):

@aprt06 Did you find out how to resolve this with an Azure File Share? I think I am trying to set it up in a similar environment. Tried granting contributor access to my AnythingLLM cloud deployment but it did not work.

@ccr-fan-3000 commented on GitHub (Aug 1, 2024): @aprt06 Did you find out how to resolve this with an Azure File Share? I think I am trying to set it up in a similar environment. Tried granting contributor access to my AnythingLLM cloud deployment but it did not work.
Author
Owner

@ericthomas1 commented on GitHub (Aug 8, 2024):

@aprt06 , @timothycarambat , @ccr-fan-3000,

Is this a factor?: https://lancedb.github.io/lancedb/guides/storage/#azure-blob-storage

  • How can we configure the default LanceDB instance to write to Azure Blob Storage?

Seems like this is a good place to configure?

Disregard. Instead see below.

@ericthomas1 commented on GitHub (Aug 8, 2024): @aprt06 , @timothycarambat , @ccr-fan-3000, **Is this a factor?**: https://lancedb.github.io/lancedb/guides/storage/#azure-blob-storage - How can we configure the default LanceDB instance to write to Azure Blob Storage? Seems like this is a good place to configure? - https://github.com/Mintplex-Labs/anything-llm/blob/53d64f30b116128cdd4e2adcbafb012f3202e405/server/utils/vectorDbProviders/lance/index.js#L25 Disregard. Instead see below.
Author
Owner

@ericthomas1 commented on GitHub (Aug 8, 2024):

I think we are going to try this unless @timothycarambat doesn't think it will work:

  1. Create Blob Container. Within the Blob Container, create a LanceDB database.
  2. Set theses Azure Web App Environment Variables:
    • AZURE_STORAGE_ACCOUNT_NAME
    • AZURE_STORAGE_ACCOUNT_KEY
    • AZURE_CONTAINER_NAME (set to container name from above)
    • AZURE_DATABASE_NAME (set to db name from above)
    • VECTOR_DB (set this to lancedb)
  3. Make changes to server/utils/vectorDbProviders/lance/index.js
const lancedb = require("@lancedb/lancedb");  
  
/** * LancedDB Client connection object * @typedef {import('@lancedb/lancedb').Connection} LanceClient */  
const LanceDb = {  
  // Update URI to point to Azure Blob Storage  
  uri: `az://${process.env.AZURE_CONTAINER_NAME || 'my-container'}/${process.env.AZURE_DATABASE_NAME || 'my-database'}`,  
  name: "LanceDb",  
  
  /** @returns {Promise<{client: LanceClient}>} */  
  connect: async function () {  
    if (process.env.VECTOR_DB !== "lancedb") throw new Error("LanceDB::Invalid ENV settings");  
  
    // Add Azure Blob Storage credentials to storage options  
    const storageOptions = {  
      accountName: process.env.AZURE_STORAGE_ACCOUNT_NAME,  
      accountKey: process.env.AZURE_STORAGE_ACCOUNT_KEY  
    };  
  
    const client = await lancedb.connect(this.uri, { storageOptions });  
    return { client };  
  },  
  
  // ... rest of your methods  
};  
  
module.exports.LanceDb = LanceDb;  

We'll likely need to also grant a Blob Data Contributor Role to the Azure Web App so it can read/write...

Thoughts on this one?

@ericthomas1 commented on GitHub (Aug 8, 2024): I think we are going to try this unless @timothycarambat doesn't think it will work: 1. Create Blob Container. Within the Blob Container, create a LanceDB database. 2. Set theses Azure Web App Environment Variables: - AZURE_STORAGE_ACCOUNT_NAME - AZURE_STORAGE_ACCOUNT_KEY - AZURE_CONTAINER_NAME (set to container name from above) - AZURE_DATABASE_NAME (set to db name from above) - VECTOR_DB (set this to lancedb) 3. Make changes to `server/utils/vectorDbProviders/lance/index.js` ``` const lancedb = require("@lancedb/lancedb"); /** * LancedDB Client connection object * @typedef {import('@lancedb/lancedb').Connection} LanceClient */ const LanceDb = { // Update URI to point to Azure Blob Storage uri: `az://${process.env.AZURE_CONTAINER_NAME || 'my-container'}/${process.env.AZURE_DATABASE_NAME || 'my-database'}`, name: "LanceDb", /** @returns {Promise<{client: LanceClient}>} */ connect: async function () { if (process.env.VECTOR_DB !== "lancedb") throw new Error("LanceDB::Invalid ENV settings"); // Add Azure Blob Storage credentials to storage options const storageOptions = { accountName: process.env.AZURE_STORAGE_ACCOUNT_NAME, accountKey: process.env.AZURE_STORAGE_ACCOUNT_KEY }; const client = await lancedb.connect(this.uri, { storageOptions }); return { client }; }, // ... rest of your methods }; module.exports.LanceDb = LanceDb; ``` We'll likely need to also grant a `Blob Data Contributor` Role to the Azure Web App so it can read/write... Thoughts on this one?
Author
Owner

@ericthomas1 commented on GitHub (Aug 9, 2024):

Bingo! This works.
I ❤️open-source 🧙‍♂️
Thank you!

@ericthomas1 commented on GitHub (Aug 9, 2024): Bingo! This works. I ❤️open-source 🧙‍♂️ Thank you!
yindo changed title from [BUG]: addDocumentToNamespace LanceDBError : Operation not supported (os error 95) to [GH-ISSUE #1825] [BUG]: addDocumentToNamespace LanceDBError : Operation not supported (os error 95) 2026-06-05 14:39:26 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#1188