Menu Close

Data Crow Server

Since Data Crow 4.0 it is possible to run Data Crow as a server. This allows for clients to connect to a single instance of Data Crow.

The server edition is an advanced server, a combined web and application server. This means that users can connect to Data Crow using the thick-client (the Data Crow application) and / or the web client (the browser) . The server allows multiple users, using either of these clients (thick / web) to connect to the server, at the same time. The user management function allows you to set granular user permissions per user, right down to field level.

The server edition is headless, meaning it can run in environments where there is no graphical interface.

Installing the Server #

To install the server:

  • Unzip the zipped Data Crow Server distribution to the installation location.

That’s it – it does not require any further installation. It does require Java version 17 or higher though.

Setting up the Server #

Just as the normal client does need a user folder where it stores the data and settings, the server does so too. You can choose to have the server edition set up a new empty user folder, or, you can choose to use an existing user folder.

Tip: use the thick client to set up the initial user folder – use the client to create users, change the system settings and basically to configure Data Crow to fit your needs. This opposed to the web client, which does not have all features the thick client has.

Running the Server #

The server has no graphical user interface (GUI) which means it relies fully on the command line. Open the terminal (Linux and Mac users) / command prompt (Windows users) and navigate to the Data Crow Server installation folder.

In the below example I will show <command> for the Data Crow start command;

  • None Windows: Java –Xmx1024m –jar datacrow-server.jar
    The –Xmx1024m parameter specifies the amount of memory available to Data Crow. You can change this to another number if necessary.
  • Windows: datacrow-server.exe (or the above, either will work)

Now we are ready to start the server.

<command> -userdir:<user folder> –port:<portnumber> –imageserverport:<portnumber> -webserverport:<portnumber> –credentials:<username>/<password>

Explanation:

  • The <command> I have explained above, make sure you use the correct syntax for the platform you are using.
  • userdir: specifies the user folder location.
    Example (Windows): -userdir:c:/server-data
  • port: specifies the main port number for the application server. The default port is 9000. If you do not supply the port parameter, port 9000 will be used.
    Example: -port:9000
    When the server has been started, clients connect by starting the Data Crow Client in client mode (-client parameter).
  • imageserverport: specifies the port to use for the HTTP image server. The default is port 9001. If you do not supply the port parameter, port 9001 will be used.
    Example: – imageserverport:9001
  • mode: specifies the operation mode. Setting the mode as local will make Data Crow server run in a localhost mode only. Omitting this parameter will set Data Crow to operate in external mode.
    Example: – mode:local
  • webserverport: specifies the port to use for the web server. If not supplied, the web server module will not be started.
    Example: – webserverport:8080
    When started, clients connect to the server as follows:
    https://<server address>:<webserverport>/datacrow
    Example: https://192.168.178.12:8080/datacrow.
  • credentials: username and password for the administrator. This is a required parameter for security reasons. The default user for Data Crow is SA with a blank password. It is recommended to set a password for each user when using the client-server setup.
    Example #1 (user rwaals, pw 123456): -credentials:rwaals/123456
    Example #2 (default user): -credentials:SA

A tip on the credentials; you can also supply these within the datacrow.credentials file. When this file is present in the installation folder of the Data Crow server Data Crow will read the credentials from this file and they don’t have to be supplied anymore as a parameter. The file does not exist by default; create the file (a plain text file) and enter the credentials within this file: <username>/<password>.
For example: rwaals/123456

Checking the Server #

If all is well the Server will reporting something similar to below:

INFO [main] (DcServer.java:140) – Server has been started, ready for client connections.

INFO [main] (DcServer.java:141) – Client can connect to IP address 192.168.0.121 on port 9000 and on image port 9001

INFO [main] (DcServer.java:144) – Listening for CTRL-C for server shutdown.

It specifies the actual IP address as well as the assigned port numbers.
Errors will be displayed directly in the console. Additionally there is the default log file, located in the user folder (data_crow.log).
If you want to debug the server (or see more messages) you can supply –debug parameter on startup.

Stopping the Server #

Press CTRL-C in terminal / command prompt window.

Connecting to Data Crow: (Thin) Web Client #

Connecting to the web server is the easiest option. Navigate, using a web browser, to the server address, like so:

https://<server address>:<web server port>/datacrow

For example: https://192.168.178.120:8080/datacrow

Connecting to Data Crow: (Thick) Client #

Any installation above 4.0 can connect to a server. It’s a simple matter of supplying the –client command to your Data Crow startup:

In the below example I will show the <command> for the Data Crow client start command;

  • For Windows users substitute this with:
    datacrow.exe
  • For other platforms use:
    Java –Xmx1024m –jar datacrow.jar
    The –Xmx1024m parameter specifies the amount of memory available to Data Crow. You can change this to another number if necessary.

Connect to server by starting Data Crow as follows (amend the shortcut):

<command> -client

When the client starts the following login dialog is shown:

  • Login name: your username (the default user is SA)
  • Password: your password (the password for user SA is blank)
  • Server Address: the IP address of the Server (see the Server console for the IP address, for example within an internal network the IP could be 192.168.0.10).
  • Application Server Port: the port as configured on the server (default is 9000). This setting is remembered.
  • Image Server Port: the port as configured on the server (default is 9001). This setting is remembered.

Web Server SSL Security #

The web server only allows HTTPS connections. In order to achieve this Data Crow uses a self-signed certificate. These types or certificates are not safe to use when exposing Data Crow to external users or when using Data Crow in a production like environment. In both of these cases make sure to use a certificate supplied by a real certificate authority.

Once you have obtained such a certificate, navigate to the ssl folder of the Data Crow Server installation. Find the datacrow_keystore.jks and add your certificate to this Java keystore. For this, please follow these instructions: https://www.baeldung.com/java-import-cer-certificate-into-keystore

Then, find the datacrow-ssl.properties file and amend the keystore_password value to the password belonging to your certificate.

User Management #

Make sure you understand the user management part of Data Crow before allowing others to access the server.