Lesson 3 of 5
Central services and load distribution
9 min
A system can have many application server instances, but some services must exist exactly once, so that all instances agree. These live in ABAP central services (ASCS): the message server and the enqueue server. Because the whole system depends on them, they are usually protected by high-availability clustering.
The message server
The message server is the system's switchboard. Every application server instance registers with it, so it knows which instances are running and how busy they are. It passes messages between instances and it supports load balancing: when a user logs on through a logon group, the message server tells the client which instance to connect to.
The enqueue server and the lock table
SAP uses logical locks to stop two users changing the same business object at once: if Maria is changing a sales order, Dan cannot change the same order until she is done. These locks are kept in one lock table per system, managed by the enqueue server in central services. Because there is only one lock table, every instance asks the same enqueue server, which keeps locks consistent across the system. In high-availability setups an enqueue replication server keeps a copy of the lock table so locks survive a failover. For SAP S/4HANA, the Standalone Enqueue Server 2 (often called ENSA2) is the standard enqueue architecture in current releases.
- Request a lockA dialog work process asks to lock sales order 4711 for Maria
- Enqueue serverChecks the single lock table in central services
- Grant or refuseLock granted; anyone else trying gets a message that the order is locked
- ReplicationIn high-availability setups, the lock is replicated to the enqueue replication server
- ReleaseLock released when the update completes or the user leaves the transaction
Logon groups
Users rarely need to know which application server they are on. In SAP Logon, administrators define a connection that points to the message server and a logon group, a named set of application server instances maintained in transaction SMLG. At logon, the message server chooses an instance from that group based on current load. Separate groups can steer different user populations: Contoso keeps a group for order-to-cash and finance users and another for testers and support, so a heavy test campaign does not slow down the business.
- Is the user connecting through SAP Logon with a logon group?Yes → message server chooses the least-loaded instance in the group · No → next question
- Is it a browser request (Fiori, OData, SAP GUI for HTML)?Yes → an HTTP load balancer such as SAP Web Dispatcher distributes it across instances · No → next question
- Is it an RFC from another system?Yes → an RFC server group or a direct destination decides the target · No → a direct connection to one instance (useful for diagnosis, not for normal users)
Batch distribution
Background jobs can also be distributed. Jobs can run on any instance with background work processes, or be pinned to a background server group. Contoso pins its large overnight jobs, such as the MRP run for plants 1710 and 1720, to instances with more background capacity so they do not compete with the morning logon peak.
What would you do?
Contoso's test lead wants to run a large automated regression suite in production-like volumes in the quality system CMQ during business-hours UAT. What should Basis set up?
- ABAP central services hold the once-per-system message server and enqueue server.
- The message server knows all instances and supports logon load balancing.
- The enqueue server manages the single lock table; SM12 shows locks; replication protects locks in high-availability setups.
- Logon groups (SMLG) steer SAP GUI users; HTTP traffic is balanced by a web dispatcher; jobs can use server groups.
Check your understanding · not graded
Lesson check
1. How many lock tables does an SAP system have?
2. Which transaction maintains logon groups?
3. What does the enqueue replication server protect?
4. Which component distributes HTTP requests across instances?