Connect to embedded orientdb server - orientdb

I have a embedded server with this default config: orientdb-server-config.xml I use version 1.0 from maven.
I'm having trouble connecting to it from the console.
Here is the command I tried: connect remote:localhost/temp admin admin
Disconnecting from the database [null]...OK
Connecting to database [remote:localhost/temp] with user 'admin'...
Error: com.orientechnologies.orient.enterprise.channel.binary.ONetworkProtocolException: Binary protocol is incompatible
with the Server connected: client=9, server=12
But I have these listeners:
<listener protocol="binary" port-range="2424-2430" ip-address="0.0.0.0"/>
<listener protocol="cluster" port-range="2434-2440" ip-address="0.0.0.0"/>
<listener protocol="http" port-range="2480-2490" ip-address="0.0.0.0">
And this storage: <storage loaded-at-startup="true" userPassword="admin" userName="admin" path="memory:temp" name="temp"/>
Everything is like the default orientdb-server-config.xml
How do I connect to this embedded database from the console?
Startup output:
2012-05-21 06:57:37:496 INFO OrientDB Server v1.0 is starting up... [OServer]
2012-05-21 06:57:38:003 INFO -> Loaded memory database 'temp' [OServer]
2012-05-21 06:57:38:038 INFO Listening binary connections on 0.0.0.0:2424 [OServerNetworkListener]
2012-05-21 06:57:38:039 INFO Listening cluster connections on 0.0.0.0:2434 [OServerNetworkListener]
2012-05-21 06:57:38:040 INFO Listening http connections on 0.0.0.0:2480 [OServerNetworkListener]
2012-05-21 06:57:38:062 INFO OrientDB Server v1.0 is active. [OServer]
UPDATE: it's working with [OServer] OrientDB Server v1.0rc9
UPDATE2: the issue was that I had version 1.0 in the server and used the console client from 1.0rc9. But now everything seems ok when server is running 1.0 and i try with client console 1.0. Thanks!

Related

Kaa, My first application - can't retrieve collected data

I'm doing my first kaa application, i have a stuck at Retrieve collected data step.
I have build my client project, kaa-app run as below:
viettq#viettq:~/Documents/workspace/kaa_example/build$
viettq#viettq:~/Documents/workspace/kaa_example/build$
viettq#viettq:~/Documents/workspace/kaa_example/build$
viettq#viettq:~/Documents/workspace/kaa_example/build$
viettq#viettq:~/Documents/workspace/kaa_example/build$
viettq#viettq:~/Documents/workspace/kaa_example/build$
viettq#viettq:~/Documents/workspace/kaa_example/build$ ./kaa-app
Default sample period: 1 seconds
Sampled temperature: 33
2017/02/17 2:29:10 [WARNING] [kaa_bootstrap_manager.c:612] (-7) - Could not find next Bootstrap access point (protocol: id=0x56C8FF92, version=1)
2017/02/17 2:29:10 [ERROR] [kaa_tcp_channel.c:307] (-7) - Kaa TCP channel [0x929A2016] error notifying bootstrap manager on access point failure
2017/02/17 2:29:10 [ERROR] [kaa_client.c:240] (-7) - Failed to process OUT event for the client socket 3
Sampled temperature: 30
Sampled temperature: 32
Sampled temperature: 26
2017/02/17 2:29:13 [WARNING] [kaa_bootstrap_manager.c:612] (-7) - Could not find next Bootstrap access point (protocol: id=0x56C8FF92, version=1)
2017/02/17 2:29:13 [ERROR] [kaa_tcp_channel.c:307] (-7) - Kaa TCP channel [0x929A2016] error notifying bootstrap manager on access point failure
2017/02/17 2:29:13 [ERROR] [kaa_client.c:240] (-7) - Failed to process OUT event for the client socket 3
Sampled temperature: 31
Sampled temperature: 32
Sampled temperature: 31
Some data send to kaa sandbox server.
My ssh to kaa sandbox server as below:
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$
kaa#kaa-sandbox.kaaproject.org:~$ mongo kaa
MongoDB shell version: 2.6.1
connecting to: kaa
> db.logs_80610364736216152939.find()
> db.logs_80610364736216152939.find()
> db.logs_80610364736216152939.find()
>
[2]+ Stopped mongo kaa
kaa#kaa-sandbox.kaaproject.org:~$ mongo kaa
MongoDB shell version: 2.6.1
connecting to: kaa
> db.logs_80610364736216152939.find()
>
>
>
Nothing in mongoDB shell.
I done everything full compilance the Kaa official tutorial
http://kaaproject.github.io/kaa/docs/v0.10.0/Programming-guide/Your-first-Kaa-application/
But i retrieve nothing from mongoDB shell.
Please help me slove it.
Thank advance!
From the logs you provided:
2017/02/17 2:29:10 [WARNING] [kaa_bootstrap_manager.c:612] (-7) - Could not find next Bootstrap access point (protocol: id=0x56C8FF92, version=1)
2017/02/17 2:29:10 [ERROR] [kaa_tcp_channel.c:307] (-7) - Kaa TCP channel [0x929A2016] error notifying bootstrap manager on access point failure
2017/02/17 2:29:10 [ERROR] [kaa_client.c:240] (-7) - Failed to process OUT event for the client socket 3
The application can`t send information to Kaa Sandbox server. Check that you correctly created all schemas and log appender. Check that you can connect to the server.
Please also check the Sandbox configuration for the Kaa host on the Management page. There should be set the PC host (which runs the Kaa Sandbox VM) machine's IP address accessible from the host you are running the application.
Note that each time the Kaa host setting is changed, you should re-generate Kaa SDK and re-build your application with that new SDK files. Otherwise, the application might fail connecting to the Kaa operations service.

OrientDB & .Net driver: Unable to read data from the transport connection

Getting error while reading network stream from a successful socket connection. PL see the debug log from orient DB:
2016-04-08 18:08:51:590 WARNI Not enough physical memory available for DISKCACHE: 1,977MB (heap=494MB). Set lower Maximum Heap (-Xmx setting on JVM) and restart OrientDB. Now
running with DISKCACHE=256MB [orientechnologies]
2016-04-08 18:08:51:606 INFO OrientDB config DISKCACHE=-566MB (heap=494MB os=1,977MB disk=16,656MB) [orientechnologies]
2016-04-08 18:08:51:809 INFO Loading configuration from: C:/inetpub/wwwroot/orientdb-2.1.5/config/orientdb-server-config.xml... [OServerConfigurationLoaderXml]
2016-04-08 18:08:52:292 INFO OrientDB Server v2.1.5 (build 2.1.x#r${buildNumber}; 2015-10-29 16:54:25+0000) is starting up... [OServer]
2016-04-08 18:08:52:370 INFO Databases directory: C:\inetpub\wwwroot\orientdb-2.1.5\databases [OServer]
2016-04-08 18:08:52:495 INFO Listening binary connections on 127.0.0.1:2424 (protocol v.32, socket=default) [OServerNetworkListener]
2016-04-08 18:08:52:511 INFO Listening http connections on 127.0.0.1:2480 (protocol v.10, socket=default) [OServerNetworkListener]
2016-04-08 18:08:52:573 INFO Installing dynamic plugin 'studio-2.1.zip'... [OServerPluginManager]
2016-04-08 18:08:52:838 INFO Installing GREMLIN language v.2.6.0 - graph.pool.max=50 [OGraphServerHandler]
2016-04-08 18:08:52:838 INFO [OVariableParser.resolveVariables] Error on resolving property: distributed [orientechnologies]
2016-04-08 18:08:52:854 INFO Installing Script interpreter. WARN: authenticated clients can execute any kind of code into the server by using the following allowed languages:
[sql] [OServerSideScriptInterpreter]
2016-04-08 18:08:52:854 INFO OrientDB Server v2.1.5 (build 2.1.x#r${buildNumber}; 2015-10-29 16:54:25+0000) is active. [OServer]
2016-04-08 18:08:57:986 INFO /127.0.0.1:49243 - Connected [OChannelBinaryServer]
2016-04-08 18:08:58:002 INFO /127.0.0.1:49243 - Writing short (2 bytes): 32 [OChannelBinaryServer]
2016-04-08 18:08:58:002 INFO /127.0.0.1:49243 - Flush [OChannelBinaryServer]
2016-04-08 18:08:58:002 INFO /127.0.0.1:49243 - Reading byte (1 byte)... [OChannelBinaryServer]
Using OrientDB .Net binary (C# driver) in Windows Vista. This was working fine until recently. Not sure what broke it...
Resetting TCP/IP using NetShell utility did not help.
Any help is highly appreciated.
The problem was with the AVG anti-virus program that is blocking the socket. Added an exception in the program for localhost to fix the problem.

What causes this OrientDB startup error?

I just started getting this error when running Orient. Any advise what to do?
2015-11-10 08:09:52:003 INFO OrientDB auto-config DISKCACHE=489MB (heap=491MB os=52,339MB disk=978MB) [orientechnologies]
2015-11-10 08:09:52:111 INFO Loading configuration from: /home/ubuntu/workspace/orient215/config/orientdb-server-config.xml... [OServerConfigurationLoaderXml]
2015-11-10 08:09:52:391 INFO OrientDB Server v2.1.5 (build 2.1.x#r; 2015-10-29 16:54:25+0000) is starting up... [OServer]
2015-11-10 08:09:52:430 INFO Databases directory: /home/ubuntu/workspace/orient215/databases [OServer]
2015-11-10 08:09:52:484 INFO Listening binary connections on 0.0.0.0:2424 (protocol v.32, socket=default) [OServerNetworkListener]Exception in thread "main" java.lang.NegativeArraySizeException
at com.orientechnologies.orient.server.network.OServerNetworkListener.getPorts(OServerNetworkListener.java:113)
at com.orientechnologies.orient.server.network.OServerNetworkListener.listen(OServerNetworkListener.java:305)
at com.orientechnologies.orient.server.network.OServerNetworkListener.<init>(OServerNetworkListener.java:79)
at com.orientechnologies.orient.server.OServer.activate(OServer.java:334)
at com.orientechnologies.orient.server.OServerMain.main(OServerMain.java:41)
Well I deleted this question quickly because I found my own answer. But on second thought if someone else makes a typo in the port specification in orientdb-server-config.xml, then they might find this post useful

Connection timeout to local JBoss 7.2.0 on osx

I'm attempting to connect to a locally deployed JBoss 7.2.0 on osx, but I get the following error message when trying to connect with the CLI:
$ bin/jboss-cli.sh
You are disconnected at the moment. Type 'connect' to connect to the server or 'help' for the list of supported commands.
[disconnected /] connect
The controller is not available at localhost:9999: java.net.ConnectException: JBAS012144: Could not connect to remote://localhost:9999. The connection timed out: JBAS012144: Could not connect to remote://localhost:9999. The connection timed out
[disconnected /]
Netstat shows:
tcp4 0 0 127.0.0.1.9999 *.* LISTEN
and the server log states:
16:24:37,118 INFO [org.jboss.as.remoting] (MSC service thread 1-3) JBAS017100: Listening on 127.0.0.1:9999
In addition to which, I can telnet to 127.0.0.1:9999 (though the connection dies due to incorrect packet size, which I presume is as intended).
I've verified that standalone.xml states 127.0.0.1 as the correct binding address and 9999 as the correct port for management-native.
Is there anything I've missed, or any other way to trouble shoot?
Yeah, a bug in OpenJDK turned out to be it.

Unable to start JBoss from within Eclipse

I am unable to start JBoss server 5.1.0.GA version from eclipse Indigo.
Eclipse shows me message box saying 'Server JBoss v5.0 at localhost was unable to start within 500 seconds. If the server requires more time, try increasing the timeout in the server editor.' but in the console window I can see that JBoss has been actually started.
here is some part of log which I can see in console window of eclipse :
SecureDeploymentManager/remote - EJB3.x Default Remote Business Interface
SecureDeploymentManager/remote-org.jboss.deployers.spi.management.deploy.DeploymentManager - EJB3.x Remote Business Interface
15:14:20,212 INFO [SessionSpecContainer] Starting jboss.j2ee:jar=profileservice-secured.jar,name=SecureManagementView,service=EJB3
15:14:20,212 INFO [EJBContainer] STARTED EJB: org.jboss.profileservice.ejb.SecureManagementView ejbName: SecureManagementView
15:14:20,222 INFO [JndiSessionRegistrarBase] Binding the following Entries in Global JNDI:
SecureManagementView/remote - EJB3.x Default Remote Business Interface
SecureManagementView/remote-org.jboss.deployers.spi.management.ManagementView - EJB3.x Remote Business Interface
15:14:20,252 INFO [SessionSpecContainer] Starting jboss.j2ee:jar=profileservice-secured.jar,name=SecureProfileService,service=EJB3
15:14:20,262 INFO [EJBContainer] STARTED EJB: org.jboss.profileservice.ejb.SecureProfileServiceBean ejbName: SecureProfileService
15:14:20,272 INFO [JndiSessionRegistrarBase] Binding the following Entries in Global JNDI:
SecureProfileService/remote - EJB3.x Default Remote Business Interface
SecureProfileService/remote-org.jboss.profileservice.spi.ProfileService - EJB3.x Remote Business Interface
15:14:20,362 INFO [TomcatDeployment] deploy, ctxPath=/admin-console
15:14:20,412 INFO [config] Initializing Mojarra (1.2_12-b01-FCS) for context '/admin-console'
15:14:23,486 INFO [TomcatDeployment] deploy, ctxPath=/BannedListSearch
15:14:27,532 INFO [TomcatDeployment] deploy, ctxPath=/IWorkWebApp
15:14:27,813 INFO [TomcatDeployment] deploy, ctxPath=/
15:14:29,155 INFO [TomcatDeployment] deploy, ctxPath=/TestWebProject
15:14:30,036 INFO [TomcatDeployment] deploy, ctxPath=/displaytag-examples-1.2
15:14:30,136 INFO [TomcatDeployment] deploy, ctxPath=/jmx-console
15:14:30,276 INFO [TomcatDeployment] deploy, ctxPath=/HelloWebService
15:14:30,407 ERROR [EngineConfigurationFactoryServlet] Unable to find config file. Creating new servlet engine config file: /WEB-INF/server-config.wsdd
15:14:30,687 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-127.0.0.1-8081
15:14:30,707 INFO [AjpProtocol] Starting Coyote AJP/1.3 on ajp-127.0.0.1-8009
15:14:30,707 INFO [ServerImpl] JBoss (Microcontainer) [5.1.0.GA (build: SVNTag=JBoss_5_1_0_GA date=200905221053)] Started in 48s:110ms
I have increased start Timeout of server to 500 seconds then also I am getting same error. I have not changed anything else.
I am able to start JBoss from command prompt successfully but same server is not getting started from eclipse.
Please help me to start the JBoss server.
Sound to me like the http port you are configured in JBoss is different to the port you have in the Eclipse configuration for JBoss.
Eclipse uses the port configuration to listen to JBoss' port so that it can determine that JBoss has actually started. If they differ, Eclipse thinks JBoss has never started although it actually has according to the log console. Make the ports match and it will probably work.
Updated: According to your log, JBoss is using port 8081 for HTTP:
Starting Coyote HTTP/1.1 on http-127.0.0.1-8081
Now you have to tell Eclipse to listen to that port so that it can figure out whether JBoss has started (default is 8080 and therefore Eclipse will never be aware of it!). Go to your servers view, double click on your JBoss server, and the configuration screen will come up:
You have to edit the HTTP port (in the 'Port' box) and set it to 8081 so that it matches your server's.