2016-07-15 102 views
1

创建索引时,我能够使用连接到我的ArangoDB集群的协调如下:锁定超时在ArangoDB

sudo arangosh --server.endpoint tcp://10.32.0.15:1027 

一切正常(CRUD,查询等),除了当我尝试创建索引我得到一个“锁定超时”的错误:

10.32.0.15:[email protected]_system> db.imdb_vertices.ensureIndex({ type: "skiplist", fields: ["name"] }) 
JavaScript exception in file '/usr/share/arangodb3/js/client/modules/@arangodb/arangosh.js' at 100,7: ArangoError 18: : lock timeout 
!  throw error; 
! ^
stacktrace: ArangoError: : lock timeout 
    at Object.exports.checkRequestResult (/usr/share/arangodb3/js/client/modules/@arangodb/arangosh.js:98:21) 
    at ArangoCollection.ensureIndex (/usr/share/arangodb3/js/client/modules/@arangodb/arango-collection.js:738:12) 
    at <shell command>:1:18 

10.32.0.15:[email protected]_system> 

我得到同样的错误,当我尝试创建索引通过HTTP:

$ curl -X POST --data-binary @- --dump - http://10.32.0.15:1027/_api/index?collection=imdb_vertices << EOF 
{ 
    "type" : "skiplist", 
    "fields" : [ 
     "name", 
     "genre" 
    ] 
} 
EOF 

HTTP/1.1 400 Bad Request 
Content-Type: application/json; charset=utf-8 
Server: ArangoDB 
Connection: Keep-Alive 
Content-Length: 71 

{"error":true,"code":400,"errorNum":18,"errorMessage":": lock timeout"} 

从文档中,我看到“当超时等待锁定时会提出。”被列为错误的原因。但是,我无法找到解决方案。任何提示?

谢谢!

回答

1

在ArangoDB Google Group论坛上解决here