Manifold Server

Manifold Server, called Server for short, is a read-only, parallel, spatial database server that also includes a TCP data sharing server, an HTTP map server and WMS server.  This topic provides an overview of Manifold Server with installation, activation, and launching instructions.

 

Server can run in three modes:

 

 

 

 

Manifold Server is built into Release 9 Universal edition and Release 9 Server edition as follows:

 

 

 

Manifold Server is not a part of Manifold 9 Professional edition, Manifold Viewer, or Manifold's SQL for ArcGIS® Pro product.  Although those products do not install Server, they can connect to Manifold Server as clients, to use the data served by Server.

 

Server can run on a machine at the same time as a regular Manifold session.  When a Manifold 9 Server has been installed, multiple Server instances can run at the same time on the same machine, with each Server instance sharing out a different .map file.  The limited version of Server installed by Manifold 9 Universal can run only a single Server instance on the server machine.   Running as a TCP server, Server is by far the easiest spatial database server to install, load, launch, manage, and use, and running as an HTTP server, Server is by far the easiest way to publish GIS displays for browsing on Internet.

 

Universal edition is limited to 20 TCP Server simultaneous connections and to 100 HTTP Server simultaneous connections.  The number of HTTP Server connections allowed with Universal edition is larger because browsers will often launch multiple connections from a single session.  

 
The higher number ensures that, when running Universal edition, on average about 20 simultaneous users can work with an HTTP Server web page, the same as the maximum number of Manifold clients that can connect to TCP Server hosted by Universal edition.

Installation and Activation

Manifold 9 Universal edition or Manifold 9 Server edition  must be installed and activated on the server machine before Server can be used.  Manifold 9 Universal edition and Manifold 9 Server edition automatically install Manifold Server as part of the installation.    Manifold 9 Professional edition does not install Server.

 

Installing and Activating Server

 

  1. Install Manifold 9 Universal edition or Manifold 9 Server edition on the server machine.
  2. Launch Manifold with administrator privileges (right-click on manifold.exe and choose Run as administrator).
  3. Activate the license.  When activating a Manifold 9 Server license, check the Install for all users (admin) box to activate the license for all users.  

 

A typical Manifold installation will install a variety of files in the Manifold installation folder:

 

 

Server appears as manifoldsrv.exe in the installation folder of a Manifold Release 9 Universal installation.   

 

The manifold.exe executable in the installation folder is a regular Manifold application.  Launch manifold.exe to run Manifold in the usual way, for example, to work with projects in the Manifold desktop or to run Manifold as a client that uses data from Server.     A regular Manifold session can run on a server machine at the same time as Server, so long as the two different sessions do not open the same .map file directly.   The regular Manifold session could connect to the Server to use the contents of a .map file launched with Server.

Activate Manifold Server

Activating Manifold on a machine also activates Manifold Server on that machine.  The same license allows launching both Server instances and also regular desktop sessions of Manifold on that machine.

 

If Manifold has not yet been activated on the server machine, launch Manifold in the usual way by double-clicking the manifold.exe executable.   That will raise the activation dialog to allow entering a Release 9 Universal edition or Release 9 Server serial number.   You can then close Manifold and proceed with launching Server.

 

When activating a Manifold 9 Server license, launch Manifold with administrator privileges (right-click and choose Run as administrator), and make sure to check the Install for all users (admin) box to activate the license for all users.  

Launching Server from a Command Prompt

Server can be launched using a single command line in a Command Prompt window.   Server can be launched from a command prompt window using either a Manifold Universal or a Manifold Server license.

 

Launch Manifold Server from a Command Prompt

 

  1. Open a Windows Command Prompt window.
  2. Navigate into the Manifold installation folder.
  3. Launch manifoldsrv from the command line, specifying the .map file for Server to use as well as any options, such as the IP address to use and the -type option to specify running as a TCP server ( -type:tcp  for sharing data) or as an HTTP server ( -type:http serving maps as web pages).
  4. If Windows pops open a Windows Defender Firewall dialog, press the Allow access button.
  5. Do not close the Command Prompt window or log out.  
  6. To stop Server, either close the Command Prompt window, or with the focus on the Command Prompt window, press Ctrl-C.
  7. When running as an HTTP server, launch Windows Defender Firewall and add the manifoldsrv.exe executable file to the exceptions list.  This will enable users from outside the server machine to browse the web site that Server creates.

 

If the computer being used does not have a Manifold 9 Universal license or Manifold 9 Server license activated, manifoldsrv will exit without prompting to activate the license.  Activate the license using the main manifold.exe application by launching a desktop session of Manifold in the usual way.

 

When launched from a command prompt, Server runs as long as the Command Prompt window stays open, and we have not logged out, and we have not stopped Server in the Command Prompt window with a Ctrl-C.   We can continue working on the computer running Server using that same user login.  Users running Server on their machines will usually just minimize the Command Prompt window to the taskbar and then keep running other programs.   If we do not want to leave a server machine with an open login, we can lock the screen by simultaneously pressing the Windows logo key and L.

 

Stopping Manifold Server launched from a Command Prompt

 

  1. To move the focus onto the window, Click the Command Prompt window in which manifoldsrv was launched.
  2. Press Ctrl-C or Ctrl-Break.
  3. Alternately, close the Command Prompt window in which manifoldsrv was launched.

 

Manifold Server launched from a Command Prompt window automatically stops if the console window attached to it is closed, if the Windows user who launched manifoldsrv starts logging off Windows, or if the computer system starts shutting down.

Launching Server as a Windows Service

A Manifold 9 Server license also allows Server to be launched as a Windows service.  A Manifold 9 Universal license cannot launch Server as a Windows service.  

 

A regular Manifold interactive session launched with administrator privileges (right-click and choose Run as administrator) is used to control Server instances when run as Windows services.   Launch Manifold interactively to get access to the Tools - Manage Services dialog that allows adding, starting, stopping, and otherwise managing Server instances running as services.

 

Windows Firewall wants to protect users from themselves by preventing programs from accessing ports.  If you know how to work Firewall, you can easily give Server access to the ports it uses.  If your Firewall skills are rusty, it is easier to simply launch Server at least once from a Command Prompt window as described above, so you can press the Allow access button and let Windows Firewall configure itself.  

 

Getting Server Ready

 

  1. Launch Manifold with administrator privileges (right-click and choose Run as administrator).
  2. Activate for all users.
  3. If Manifold has already been activated, choose Help - About, to verify that the license has been installed for all users.
  4. Verify that the License for all users readout reports Installed.
  5. If it does not report Installed, press the Install button to install the license for all users.
  6. Open a Command Prompt window and launch Server from a command line.  Use any .map file with default options.
  7. When Server launches, if Windows Firewall raises a dialog, press the Allow access button.
  8. Close the Command Prompt window to shut down that Server instance.
  9. When running as an HTTP server, launch Windows Defender Firewall and add the manifoldsrv.exe executable file to the exceptions list.  This will enable users from outside the server machine to browse the web site that Server creates.

 

The above procedure need be done only once for a new Server installation, to verify that the license has been installed for all users, and to allow access through Windows Firewall.  If the Manifold installation is updated, launch Server again from a Command Prompt window to once again configure Windows Firewall.    Or, learn how to use Windows Firewall to open the ports that will be used for any Manifold Server installation.

 

When running Server as an HTTP server from a portable installation, if the manifoldsrv.exe executable file is in a different folder than previously used, it must be added to the exceptions list for Windows Defender Firewall.  See the instructions at the end of this topic for adding Server as an exception to Windows Defender Firewall.

 

Add a Server instance running as a Windows service:

 

  1. Install Manifold 9 Server edition on the server machine.
  2. Launch Manifold interactively in the usual way to activate it.
  3. Important: Activate for all users.
  4. In the main menu, choose Tools - Manage Services.
  5. In the Manage Services dialog, press the Add button in the toolbar.
  6. In the Service dialog, press the [...] browse button and choose the .map file for Server to use.
  7. Choose a different address and port if the defaults are not desired.
  8. Enter any desired options in the Options box as they would be written in a command line, for example, choosing either -type:tcp to run as a TCP server or -type:http to run as an HTTP server.
  9. Press OK.
  10. Back in the Manage Services dialog, Ctrl-click the row just added to select it.
  11. Press the Start button in the toolbar to start running the service.
  12. If desired, press the Refresh button in the toolbar to see the process ID assigned.
  13. Press the Close button to close the Manage Services dialog

 

See the Tools - Manage Services topic for details on starting, stopping, and otherwise managing Server instances.  Watch the new 10 Minute Tutorial - Manage Services video to see the new Manage Services dialog in action.   The topic and video use a TCP server as an example.  Procedures are exactly the same for an HTTP server.

Connect to TCP Server from Manifold

Manifold clients connect to Server running as a TCP server by creating a data source just as they would for any database.  Any Manifold edition can connect as a client, including Manifold Professional, Manifold Universal, Manifold Server, Manifold Viewer, and SQL for ArcGIS® Pro.

 

Connect to Manifold Server from a Manifold Client

 

  1. Launch Manifold as usual.
  2. Choose File - Create - New Data Source - More...
  3. In the New Data Source dialog choose Database: manifoldserver as the Type.
  4. Click the [....] button for Source.
  5. In the Database Login dialog, enter the IP address for the Server.  Press OK.
  6. Back in the New Data Source dialog, press Create Data Source.
  7. A new Data Source appears in the Project pane for the server.  Expanding the data source shows the contents of the .map file.

 

Multiple different Manifold sessions on the same machine can connect to the same Server, just as multiple different Manifold sessions on different machines can connect to the same Server.

 

Disconnect a client by deleting the Server data source in a project, or by closing the project or the Manifold session.

 

Keep in mind that the Server data source is read-only.   For greater interactive flexibility, copy drawings, images, labels, and maps (do not copy their tables, just the drawings, images, labels or maps) and paste into the main part of the Project.   The pasted components will automatically have links in their properties back to the originating tables in the Server data source, but the pasted components will exist in the read/write portion of the project.   That will enable styling of drawings, the ability to turn labels off and on in maps and so on.

 

Shutting down Server when clients are connect will generate a Server Disconnected message on the client machines.   Server administrators should use a messaging or chat application to send out warnings to possible client users in their organization before shutting down Server.  

Connect to HTTP Server from a Browser

Internet browsers connect to a map served by Server running as an HTTP server by using a URL that has the IP address (or a domain that resolves to that IP address) used for that Server instance.  For example, if we have launched Server as an HTTP server on a computer that has an IP address of 192.168.1.99 we can enter a URL of http://192.168.1.99 into our browser to visit the web page Server generates.

Command Line Syntax and Options

When launching Server from a command line in a Command Prompt window, the following syntax applies.

 

manifoldsrv [<options>] <file>

 

File names or paths that use spaces should be wrapped with double quote " characters.

Options

Default values are used for any options not explicitly specified.  The following options are also used in the Options box in the Service dialog when running Server as a service using Tools - Manage Services in Manifold Server licenses.

 

-addr:xxx

Network interface to listen on.  Default: primary network interface

-component:xxx

Used only with HTTP server.  The name of the served component, a single map, drawing, image, or labels component.  Enclose component names that have spaces with double " quote characters, as in

 

-component:"Cities and Provinces of Mexico"

 

The default component name used is Main if no component name is explicitly specified.

-connections:xxx

Maximum number of connections. Use 0 for no limit.  Default: 20   More than 20 connections when using TCP Server require a Manifold 9 Server license.  More than 100 connections when using HTTP Server require a Manifold 9 Server license.

-cx:xxx

-cy:xxx

Width (cx) and height (cy) in pixels of the image to render on the web page.  Cannot exceed 4096. If no specified, the default height and width is 800 by 800 pixels.
 
If only cx or cy is specified, the image will have the width and height of that specified number of pixels, providing a quick way to set square image sizes by specifying only one parameter.
 
Example: -cx:800 -cy:600 specifies an image size 800 pixels wide by 600 pixels high.
 
Example: -cx:400 -cy:600 specifies an image size 400 pixels wide by 600 pixels high.
 
Example: -cx:500 specifies an image size 500 pixels wide and 500 pixels high.
 
Example: -cy:450 specifies an image size 450 pixels wide and 450 pixels high.
 

-logfolder:xxx

Specify file to use for a log file instead of the default location.

-memory:xxx

Memory size in GB to use for system cache.  Default if not specified is 4 GB. Memory size for system can be set as low as 1 GB.  Manifold server ignores the amount of memory to use for system cache size specified in Tools - Options and instead allows specifying it with the -memory:xxx command-line parameter.  
 
(Server ignores the user value set because server instances frequently are run using specialized accounts and accessing interactively-set user options for these accounts might be hard or even impossible.)

-password:xxx

Used only with TCP server.  Optional password for access. Ignored if no -user name is specified.  If not specified, any or no password can be used.

-port:xxx

Port to listen on. Default for TCP: 9099.  Default for HTTP: 80.
 
Internet browsers default to using port 80 for HTTP.  When running as an HTTP server, using the default port allows any browser to connect by just using the IP address as the URL, for example, http://192.168.1.99.
 

You can use other ports by specifiying the -port:xxx command line option, for example, -port:8080 to use port 8080.  Using the non-default port will require use of a URL that specifies the port, such as http://192.168.1.99:8080.

 

See the comments on specifying ports in the Notes section at the end of this topic.

-service

Launch the Server instance as a Windows service.  Requires administrator privileges. Requires a Manifold 9 Server license.

-scripts:xxx

Used only with TCP server. Control availability of scripts with either an on or off (the default) setting:
 

-scripts:on - Allow running scripts.  This currently applies to calling script functions in queries, computed fields and constraints.  In the future it will also apply to running script components.

 

-scripts:off - Disaallow running scripts (the default).

 

-type:xxx

Server type.  Specifying -type:http runs the HTTP server and specifying -type:tcp runs the TCP server.  The default is running as a TCP server.

-urlbase:xxx

Specifies the URL base to use by the Javascript control that generates the web site.  The default is /.  This option is useful when the HTTP server is used together with a general-purpose web server.
 
Suppose, for example, the image generated by server is to be used within a site that is supposed to have a URL of https://mydomain.com/parcels/.   Without using the urlbase option the HTTP control would not be aware that is is being run from within a web server(or proxied) and the URL of the image would end up being /map?, which would translate to https://mydomain.com/map?... with similarly wrong URLs for the icons used.  
 
Using an option of -urlbase:https://mydomain.com/parcels/ would translate to https://mydomain.com/parcels/map?... and so the HTTP control will work correctly.
 

-user:xxx

Used only with TCP server.  Optional user login name.  If no login name is specified, any login name or no login name can be used.

-workers:xxx

Number of worker threads per connection, from 1 to 128.  Default: 4   
 
Used only with TCP server.  Threads used by the HTTP server are organized differently from threads used by the TCP server: the number of threads for the HTTP server is managed automatically.

 

If no IP address is specified, Server will pick an IP address to use from the network connections currently available.  See all available IP addresses by doing an ipconfig command in the Command Prompt window prior to launching Server.  

 

Systems often have multiple networks running, including virtual networks for services such as VPNs in addition to physical networks such as WiFi adaptors or Bluetooth networks, so do not assume that the IP address Server picks as the primary is the one you want it to use.  Explicitly specify which IP address you would like Server to use instead of letting Server pick from those available.   To tell Server to listen on the IP address of an Ethernet or WiFi connection, specify that IP address using the -addr: option.

 

Port 9099 is the default port for Manifold Server.  It is currently unassigned by IANA and will be requested by Manifold when Manifold Server is issued in a Base build.

 

To launch a Server instance as a Windows service, a more convenient way than using the -service option is to use the new Tools - Manage Services dialog.

Example Command Line

In a Command Prompt window, launch Manifold Server using a .map file called standard layers.map, using an IP address of 192.168.2.12, the default port of 9099, up to 20 connections (the default), and 6 worker threads per connection:

 

manifoldsrv -addr:192.168.2.12 -workers:6 "C:\mfd\projects\standard layers.map"

 

Any options not explicitly set when launching Server will remain at their default values.  If no user login name or password are specified, none will be required for connections.

Log Files

manifoldsrv writes log files, similar to how regular Manifold sessions write log files.  The manifoldsrv log files are named xxx-srv.log, extended to xxx-srv-yyy.log for multiple instances of manifoldsrv running at the same time, to distinguish them from the log files for Manifold. manifoldsrv logs each accepted and closed connection as well as messages generated by worker threads that process requests.

 

The -logfolder:xxx allows specifying a file to use for a logfile instead of the default log file.

 

Notes

Credentials encryption - Credentials are stored in database and other data sources in plain text.   Manifold expects to provide encryption options so data sources can be provided with Server without exposing credentials.

 

TCP - Manifold clients connect to Server running as a TCP server through TCP protocol, a standard part of networking.

 

Exclusive use - A Manifold project being shared by Server cannot be opened or used by a different Server session or by a regular Manifold desktop session.   To update that project, the Server session using it must be shut down.  Server cannot share a project that is in use in a regular Manifold desktop session or which is being provided by a different Server session.

 

Exclusive binding - For security, Server binds to the network interface in exclusive mode.

 

Console title - When launched in a Command Prompt window, Server sets the console title to Server - addr:port - filename. This hides sensitive information like user logins and passwords and it also shows connection information even if that was not spelled out in the command line.   The console window will show the server type (HTTP or TCP) in the window caption when Server is run in a console window.

 

Non-routable IP addresses - The examples in this documentation use non-routable IP addresses beginning with 192....  Such IP addresses may be visible on your local network, but they cannot be visited across Internet.  When connecting to Server through the Internet, either for sharing data using the TCP server or for publishing maps using the HTTP server, the computer should have a static IP address that is routable (visible over Internet), like 20.81.111.85, and the Server instances that are launched should use that IP address.

 

See Also

Server: Share Data

 

Server: Publish Web Maps

 

Server: WMS Server

 

Favorite Data Sources

 

File - Create - New Data Source

 

Tools - Manage Services

 

Command Window

 

Query Builder