
MeshCentral server architecture is worth understanding properly, even for administrators who only intend to run a single small installation. Once you know how the server, the agents, the browser and the database fit together, configuration decisions stop feeling arbitrary, troubleshooting becomes much faster and planning for growth becomes realistic. This article explains what the MeshCentral server actually does, how agents connect and stay connected, how sessions are relayed, which databases the server can use and how deployments scale from a single Raspberry Pi to several cooperating servers.
The Server's Responsibilities
The MeshCentral server is a single Node.js application, but it carries out many jobs at once.
- Web server. It serves the dashboard to browsers over HTTPS and redirects plain HTTP requests.
- Identity and access. It authenticates users, applies two-factor checks and enforces the permissions attached to each account, user group and device group.
- Agent hub. It accepts and maintains connections from every MeshAgent, tracking each device's status in real time.
- Session relay. It joins browsers to agents so that desktop, terminal and file sessions can flow between them.
- Record keeper. It stores accounts, device information, events and settings in a database.
- Agent distributor. It builds installers for each device group and updates agents when newer agent builds are available.
- Intel AMT manager. Where configured, it handles management of computers with Intel Active Management Technology, including client-initiated connections from those machines.
All of this runs in one process, supervised by a small launcher process that restarts the server when required. That simplicity is one reason MeshCentral can run on modest hardware.
How Agents Connect
The most important architectural decision in MeshCentral is the direction of the connection. Traditional remote access often requires the managed computer to accept incoming connections, which means opening firewall ports on every device and every site. MeshCentral reverses this.
When MeshAgent starts, it reads its configuration, which includes the server's address and a fingerprint of the server's certificate. It then opens an outbound, encrypted WebSocket connection to the server and keeps it alive. Because the connection is outbound, it passes through home routers, office firewalls and network address translation without any special configuration on the device side.
The certificate fingerprint protects that connection. The agent only completes its handshake with a server that proves it holds the matching private key. This is why the server's data folder, which contains those keys, is so important: a rebuilt server without the original keys looks like a stranger to every agent.
How a Session Is Relayed
When an administrator opens a remote desktop, the sequence runs like this.
- The browser, already signed in, asks the server to open a desktop session to a particular device.
- The server confirms that the account has the right to do so.
- The server tells the device's agent to start a session and open a second connection for the data.
- The server joins the browser's connection and the agent's data connection together, relaying traffic between them.
Where possible, the browser and agent can negotiate a direct WebRTC connection after the relay is established, reducing the load on the server and the delay. When a direct path is not available, the relay continues to carry the session. In either case, the server remains the point of control and authentication.
Ports and Network Exposure
By default, the server listens for HTTPS on port 443 and HTTP on port 80, the latter mainly for redirects and certificate validation. Intel AMT client-initiated remote access uses a separate port, 4433. Agents and browsers share the HTTPS port, which keeps the firewall footprint small.
The server can also run in different network modes. An internet-facing server can disable local discovery features, while a server confined to a local network can use them to find agents and Intel AMT devices without a public address.
Choosing a Database
MeshCentral stores its records in a database, and several options are supported.
- The built-in local database keeps everything in files inside the data folder. It needs no additional software and is ideal for small installations, labs and evaluation.
- MongoDB is a long-standing choice for larger deployments and for setups with more than one server.
- PostgreSQL suits organisations that already run and back up PostgreSQL.
- MariaDB and MySQL offer a familiar option for teams with that experience.
The choice affects backup procedures and performance at scale, but not the features available in the dashboard. MeshCentral includes tools to export and import its database, which makes migrating from the built-in database to an external one a planned task rather than a rebuild.
The Data Folder at the Heart of It All
Every MeshCentral server, however it is installed, centres on its data folder. It holds:
- config.json, which defines almost every setting;
- the web server certificate and the keys that agents use to identify the server;
- the built-in database files, when that database is in use;
- generated agent configuration and other server state.
Losing this folder means losing the server's identity. Backing it up, protecting it from unauthorised access and keeping it on persistent storage in container deployments are the most important operational habits an administrator can form.
If you remember only one thing about MeshCentral architecture, remember that the data folder is the server.
Domains: Several Portals from One Server
A single MeshCentral server can host multiple independent domains. Each domain has its own users, device groups, branding and settings, and can be reached by its own path or by its own hostname. Managed service providers use this to give each customer a separate portal, and organisations use it to separate departments with strictly independent administration.
Scaling Up
A single server handles a surprising number of devices, because each agent connection is lightweight when idle. Resource use grows with the number of simultaneous sessions, the volume of events being logged and features such as session recording. A sensible approach is to begin with a modest server, monitor processor, memory and database growth, and add resources as the fleet expands.
For very large or high-availability deployments, MeshCentral supports multiple servers working together as peers, sharing a common database such as MongoDB and a shared file store. Agents can connect to any peer, and the peers coordinate so that a browser on one server can reach an agent connected to another. Peering adds complexity, so it is best reserved for situations that genuinely need it.
Monitoring the Server
The My Server area of the dashboard shows live server statistics, including processor load, memory, connected agents, user sessions and relay counts, and gives access to the server's version, error log and configuration. Watching these figures over time is the simplest way to know when a server needs more resources. External monitoring that checks the HTTPS endpoint and alerts on outages adds another layer of assurance.
Security Implications of the Architecture
Because one server can control every enrolled device, the server is an attractive target. Threat actors have deployed MeshAgent connected to their own servers as a covert remote access tool, and vulnerabilities in MeshCentral itself have been exploited against unpatched installations. The architecture therefore calls for a few firm principles:
- keep the server and Node.js up to date, especially after security releases;
- protect administrator accounts with strong passwords and a second factor;
- expose the dashboard only as widely as necessary;
- monitor endpoints for MeshAgent installations that connect to servers other than your own.
Sizing a Server in Practice
The project does not publish a single minimum specification, because the load depends so heavily on how the server is used. A sensible way to size a server is to think in terms of workload rather than device count alone.
- Idle agents are cheap. Each holds one connection and sends occasional updates, so hundreds of idle devices place little demand on a modest machine.
- Active sessions are where resources are consumed. Every remote desktop session relayed through the server uses processor time and bandwidth, so the number of technicians working at the same moment matters more than the total number of devices.
- Logging and recording consume disk space steadily, and recordings in particular can grow quickly.
- The database grows with events and device history; an external database needs its own memory and storage.
Start with a modest virtual machine, measure processor, memory, bandwidth and disk usage during the busiest part of the working day and adjust from there. Because the server keeps all of its state in the data folder and database, moving it to a larger machine later is a planned migration rather than a rebuild.
Logs and Diagnostics
When something goes wrong, the server's own output is the best starting point. Startup messages report the ports in use, the database connection, certificate details and any configuration problems. The error log, reachable from the My Server page, records faults that occur while the server is running. For deeper investigation, the server supports additional tracing of particular subsystems, which is invaluable when diagnosing agent connection problems but should be switched off again afterwards to avoid filling the disk.
Time and Clock Accuracy
Accurate system time matters more than many administrators expect. Certificates, one-time passcodes from authenticator apps and event timestamps all depend on it. Make sure the server synchronises its clock automatically, because even a small drift can cause two-factor codes to be rejected.
Frequently Asked Questions
No. Agents open outbound connections to the server, so devices behind routers and firewalls can be managed without port forwarding on their side.
Agents keep trying to reconnect. When the server returns, they reconnect automatically and devices reappear in the dashboard.
The built-in database for small setups; MongoDB, PostgreSQL or MariaDB/MySQL for larger fleets or multi-server deployments.
Yes. Domains give each customer or department its own portal, users, devices and branding on the same server.
Agents identify the server by its certificate keys. A server without the original keys will not be trusted, and agents would have to be reinstalled.
Yes. Peering allows several servers to share a database and serve agents together, though it adds operational complexity.
Conclusion
The MeshCentral server is compact but carefully designed: a single Node.js process that authenticates users, keeps outbound agent connections alive, relays sessions, stores records and distributes agents. Its outbound connection model removes the need for port forwarding on managed devices, while its certificate-based trust ties every agent to a specific server identity held in the data folder. Understand those ideas, choose a database that matches your scale and protect the server as the critical system it is, and the rest of MeshCentral falls naturally into place.