SQLite:无法运行缓存的语句

发布于 2025-01-12 16:43:00 字数 492 浏览 8 评论 0原文

中使用

volumes: 
  - /mnt/win_share/test:/var/lib/orthanc/db/

我在 Docker 卷Orthanc.js 文件路径

  "StorageDirectory": "/var/lib/orthanc/db",

sqlite 我正在尝试将 Docker 中初始化的 Orthanc 路径复制到安装在我的 Ubuntu 系统上的驱动器,并且每当我尝试运行命令时,我都会收到以下错误

错误

  1. SQLite错误代码5
  2. 无法序列化作业引擎:SQLite:无法运行缓存语句
  3. StatelessDatabaseOperations:3260]异常 [SQLite:无法运行缓存的语句 - ]

I am using Orthanc inside Docker volume

volumes: 
  - /mnt/win_share/test:/var/lib/orthanc/db/

Orthanc.js file path for sqlite

  "StorageDirectory": "/var/lib/orthanc/db",

i am trying to copy Orthanc path intialized in Docker to the drive mounted on my Ubuntu system and whenever I try running the commands i get the following errors

Errors:

  1. SQLite error code 5
  2. Cannot serialize the jobs engine: SQLite: Cannot run a cached statement
  3. StatelessDatabaseOperations:3260] EXCEPTION [SQLite: Cannot run a cached statement - ]

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

过度放纵 2025-01-19 16:43:00

我在尝试运行两个指向同一个 SQLite 数据库的 Orthanc 实例时遇到了类似的问题。

基本上,这个 SQLite 错误代码 5 意味着 SQLite 正忙。
我能找到的唯一解决方案是使用另一个数据库(例如 PostgreSQL)。

Orthanc 配置文件:

  "Name": "Orthanc inside Docker",
  "PostgreSQL" : {
    "EnableIndex" : true,
    "EnableStorage" : true,
    "Lock" : false,
    "ConnectionUri" : "postgresql://username:password@host:port/database"
  },  
  "Plugins": [
    "/home/user/orthancdatabases/BuildPostgreSQL/libOrthancPostgreSQLIndex.so",
    "/home/user/orthanc-databases/BuildPostgreSQL/libOrthancPostgreSQLStorage.so"
  ],

发生这种情况是因为有一个数据库存储 DICOM 和 JSON 文件,另一个数据库存储 DICOM 层次结构和标签。第二个由 Orthanc 同步访问。

然而,在 PostgreSQL 插件中,层次结构和标签的数据库被正确隔离,允许您随意访问同一数据库。

希望这有帮助!

I had a similar problem while trying to run two Orthanc instances poiting to the same SQLite database.

Basically, this SQLite error code 5 means that SQLite is busy.
The only solution I could find to this was to use another database (such as PostgreSQL).

Orthanc configuration file:

  "Name": "Orthanc inside Docker",
  "PostgreSQL" : {
    "EnableIndex" : true,
    "EnableStorage" : true,
    "Lock" : false,
    "ConnectionUri" : "postgresql://username:password@host:port/database"
  },  
  "Plugins": [
    "/home/user/orthancdatabases/BuildPostgreSQL/libOrthancPostgreSQLIndex.so",
    "/home/user/orthanc-databases/BuildPostgreSQL/libOrthancPostgreSQLStorage.so"
  ],

This happens because there is a database storing DICOM and JSON files and another database storing the DICOM hierarchy and tags. The second one is accessed synchronously by Orthanc.

However, in the PostgreSQL plugin, the database for hierarchy and tags is isolated properly, allowing you to access the same database as many as you want.

Hope this helps!

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文