Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Loosing vertex around? #25

Closed
MartinBrugnara opened this issue Aug 2, 2016 · 8 comments
Closed

Loosing vertex around? #25

MartinBrugnara opened this issue Aug 2, 2016 · 8 comments

Comments

@MartinBrugnara
Copy link
Contributor

I can not locate a vertex from within gremlin, which I can retrieve in the web GUI:

From the GUI I filter as:
screen shot 2016-08-02 at 3 58 59 pm

From gremlin I query (searching by attribute wo/key) as:
g.V.has('freebaseid', 68545795554948).next().id

Raised exception:
javax.script.ScriptException: com.tinkerpop.pipes.util.FastNoSuchElementException

Full stack trace: http://pastebin.com/61iPnkBW

Relevant points:

13:32:19.129 [main] DEBUG com.arangodb.http.HttpManager - [REQ]http-POST: url=http://arango:8529/_api/cursor, headers=null, body={"count":false,"batchSize":20,"options":{},"query":"for i in GRAPH_VERTICES(@graphName , @vertexExample, @options) FILTER i.`freebaseid` \u00
3d\u003d @property0 return i","bindVars":{"property0":68545795554948,"vertexExample":{},"graphName":"mysuperdb","options":{"direction":"any","includeData":true}}}
com.arangodb.blueprints.client.ArangoDBException: org.apache.http.NoHttpResponseException: The target server failed to  respond
--- cut ---
Caused by: org.apache.http.NoHttpResponseException: The target server failed to respond

Could someone please help me figuring out what's happening here?

Versions:
ArangoDB: 2.7.7
Gremlin: 2.6.0
blueprints-arangodb-graph: 1.0.14

@a-brandt
Copy link
Collaborator

The ArangoDB client has lost the connection to the server (the server closes inactive connections after 300 seconds)

Example:

gremlin> new Date() 
==>Mon Aug 29 11:06:24 CEST 2016
gremlin> new Date()
==>Mon Aug 29 11:12:03 CEST 2016
gremlin> g.V.has('freebaseid', 68545795554948).next().id
11:12:07.415 [main] DEBUG com.arangodb.http.HttpManager - [REQ]http-POST: url=http://localhost:8529/_api/cursor, headers=null, body={"count":false,"batchSize":20,"options":{},"query":"for i in GRAPH_VERTICES(@graphName , @vertexExample, @options) FILTER i.`freebaseid` \u003d\u003d @property0 return i","bindVars":{"graphName":"factory_graph","vertexExample":{},"property0":68545795554948,"options":{"includeData":true,"direction":"any"}}}
499371 [main] ERROR com.arangodb.blueprints.ArangoDBVertexIterable  - error in AQL request
com.arangodb.blueprints.client.ArangoDBException: org.apache.http.NoHttpResponseException: The target server failed to respond

To avoid this you can increase the "keep-alive-timeout" of the server by:
--server.keep-alive-timeout <big number>

@MartinBrugnara
Copy link
Contributor Author

Thank you,
I am going to try this and report back

a-brandt pushed a commit that referenced this issue Aug 29, 2016
@a-brandt
Copy link
Collaborator

Please update blueprints-arangodb-graph to 1.0.15 and try again. (will be available on maven central in some hours)

@MartinBrugnara
Copy link
Contributor Author

ok

@MartinBrugnara
Copy link
Contributor Author

MartinBrugnara commented Sep 7, 2016

Setting --server.keep-alive-timeout to 9000 make the server die reporting that it can not lock the database and to look after /var/lib/arangodb/LOCK for further details; the file does not exists.

I am trying with a smaller value i.t. 1200 looking if it works any better.

2016-09-07T12:28:44Z [1] ERROR cannot lock the database directory, please check the lock file '/var/lib/arangodb/LOCK': system error
2016-09-07T12:28:44Z [1] FATAL cannot start server: cannot lock database directory

@a-brandt
Copy link
Collaborator

a-brandt commented Sep 8, 2016

I changed the time out handling of the client driver in 1.0.15. So you do not need to change the keep alive timeout of the server anymore.

The directory /var/lib/arangodb is not writable for none root users. Did you try to start the server with your user id?

@MartinBrugnara
Copy link
Contributor Author

No...

$ docker run -it arangodb.yml_freebase10_2.json ls -alh /var/lib/arangodb
total 24K
drwxr-xr-x  5 arangodb arangodb 4.0K Jul  4 14:52 .
drwxr-xr-x 17 root     root     4.0K Jul  4 14:18 ..
-rw-r-----  1 arangodb arangodb   68 Jul  4 14:18 SERVER
-rw-r-----  1 arangodb arangodb  124 Jul  4 14:52 SHUTDOWN
drwxr-xr-x  3 arangodb arangodb 4.0K Jul  4 14:18 databases
drwxr-xr-x  2 arangodb arangodb 4.0K Jul  4 14:52 journals

$ docker run -it arangodb.yml_freebase10_2.json whom
root

BTW there is something strange here:
I migrated this docker image from one server to the other (I needed the first);
before that I was able to start the server alone, now not even that is working.

Investigating.

@MartinBrugnara
Copy link
Contributor Author

Sorry for disappearing, but other critical things required my attention.

I've good news I was able to make it work with version 2.8.11 and gremlin 2.6.0.

It required the following actions:

  • Permission change of the arangodb installation directory chmod 777 /etc/arangodb
  • Use of arangoimp instead of gremlin api (due to arangodb#1939 )
  • Change in the groovy queries: .back() function does not support ops (deprecated).
    Fixed using labels via .as() .
  • Start the server as
rm -f /etc/arangodb/arangodb.pid
arangod --server.disable-authentication="true" --server.disable-statistics true --daemon --pid-file /etc/arangodb/arangodb.pid

I still have to check if those solutions are enough to process even our bigger sample, but at this point Arango is definitely not Loosing vertex around, so closing now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants