Optimizing Slow CEMAT and APL Faceplate Opening Times on Virtualized PCS 7 OS Clients

Optimizing Slow CEMAT and APL Faceplate Opening Times on Virtualized PCS 7 OS Clients

Slow faceplate opening times (exceeding 3–10 seconds) in SIMATIC PCS 7 V9.1 with CEMAT V9.1 or APL on virtualized WinCC OS Clients are primarily caused by DNS/NetBIOS hostname resolution delays, unbuffered synchronous tag polling in C-scripts, or virtual machine CPU ready bottlenecks. To resolve this, configure static host mappings in the 'hosts' and 'lmhosts' files across all nodes, ensure Simatic Shell utilizes the dedicated terminal bus adapter with encryption matching the server, allocate reserved vCPU cores on VMware ESXi/Hyper-V, and increase the WinCC picture cache setting in the project properties.

Table of Contents

Executive Summary

Virtualized operator stations (running on VMware vSphere / ESXi or Microsoft Hyper-V) are standard in modern SIMATIC PCS 7 and CEMAT installations. However, system integrators frequently report performance degradation where clicking a block icon takes several seconds to render the faceplate popup (@PG_*.pdl). In complex libraries like CEMAT V9.1, faceplates load dozens of dynamic attributes, script triggers, and alarm histories simultaneously. When underlying network resolution, hypervisor CPU scheduling, or WinCC picture caching are sub-optimal, cumulative delays lead to unacceptable operator response times. This guide outlines a structured optimization methodology to restore sub-second faceplate performance.

Architectural and System Mechanics

Faceplate loading mechanics and virtualization bottlenecks in PCS 7 / CEMAT:

  • Faceplate Invocation Architecture:
  • Clicking a block icon invokes @PCS7_OpenInputFaceplate or CEMAT equivalent C-scripts.
  • The script parses the tag prefix (e.g., Motor1), loads @PG_C_DRV_1D.pdl, and attaches sub-pictures (@PG_C_DRV_1D_Standard.pdl, @PG_C_DRV_1D_ViewToolbar.pdl).
  • Each sub-picture executes initialization scripts querying server tags across DCOM.
  • Network Name Resolution Latency:
  • If the OS Client relies on slow or unconfigured DNS servers, every DCOM tag request triggers NetBIOS broadcast timeouts (typically 2-4 seconds per failed resolution) before falling back to local cache.
  • Virtual Machine Resource Contention:
  • vCPU Oversubscription: High 'CPU Ready' time (>5%) on ESXi delays WinCC script execution threads.
  • Virtual Display Rendering: WinCC Graphics Designer relies on GDI/DirectX rendering. Without proper VM video memory allocation, software rendering stalls GUI updates.
  • Picture Cache Architecture:
  • WinCC caches recently loaded PDLs in RAM. If cache size is set too small, every faceplate open requires reloading files from disk or network shares.

Step-by-Step Engineering and Implementation Procedure

Step 1: Configure Static Host Resolution in Hosts and LMHosts

  1. On every OS Client, OS Server, and ES, navigate to C:/Windows/System32/drivers/etc/.
  2. Edit hosts (as administrator) and append the IP address and NetBIOS hostname of all servers and clients on the terminal bus.
  3. Edit lmhosts.sam, save as lmhosts, and add matching entries with the #PRE tag for permanent NetBIOS caching:
    192.168.1.10 OS_SRV1 #PRE 192.168.1.11 OS_SRV2 #PRE
  4. Run nbtstat -R in Command Prompt to purge and reload NetBIOS name cache.

Step 2: Validate Simatic Shell Network Adapter and Encryption

  1. Open Windows Explorer on the OS Client, right-click 'Simatic Shell' -> 'Settings'.
  2. Confirm that the selected network adapter is strictly the physical terminal bus NIC.
  3. Verify that 'Encrypted Communication' settings match the OS Server configuration exactly.

Step 3: Optimize Virtual Machine Configuration in Hypervisor

On VMware ESXi / vCenter:
1. Assign at least 4 dedicated vCPUs with 100% CPU reservation for OS Clients.
2. Ensure CPU Ready time is below 2% in ESXi performance charts.
3. Increase Virtual Machine Video Memory (VRAM) to at least 128 MB and enable 3D hardware acceleration if supported.
4. Store VM virtual disks (.vmdk) on enterprise NVMe or high-speed vSAN datastores to minimize I/O latency.

Step 4: Tune WinCC Picture Cache Size

  1. In WinCC Explorer on the OS Client project, open Computer Properties -> 'Graphics Runtime'.
  2. Increase the picture cache setting: set 'Number of picture files cached' to 20 or higher (default is often 5-10).
  3. This retains common faceplate templates (@PG_*.pdl) permanently in memory after initial loading.

Verification

To verify faceplate opening speed:
1. In WinCC Runtime, click an APL or CEMAT block icon.
2. The faceplate must appear in under 1.0 second on initial open, and under 0.5 seconds on subsequent opens.
3. Use the WinCC 'APDiag' tool (Output Window -> Trace Script Calls) to confirm zero script execution timeouts or DCOM delay messages.
4. Verify that CPU utilization on the VM remains stable during rapid faceplate transitions.

Limitations and Operational Precautions

Operational precautions:
- Do not use Remote Desktop Protocol (RDP) sessions to measure faceplate rendering performance; RDP adds network display latency. Test on the physical console or dedicated thin client.
- Increasing picture cache consumes additional client RAM; verify that the virtual machine has at least 8 GB to 16 GB of allocated memory.
- Ensure CEMAT V9.1 Update Collections and WinCC V7.5 SP2 updates are aligned between server and client stations.

Engineer FAQ

Q: Why do faceplates open slowly only on virtual machines?

A: Virtual machines often suffer from vCPU oversubscription (CPU Ready latency), unoptimized virtual video drivers, or DNS resolution delays across virtual switches.

Q: What is the impact of missing lmhosts entries?

A: Without static lmhosts mappings, Windows DCOM queries initiate NetBIOS broadcasts that take 2 to 4 seconds to timeout on every tag request.

Q: Where is the picture cache configured in WinCC?

A: In WinCC Explorer -> Computer Properties -> Graphics Runtime tab -> 'Number of picture files cached'.

Q: Does CEMAT require specific display settings?

A: Yes, CEMAT faceplates are optimized for 1920x1080 resolution with 32-bit true color and hardware GDI acceleration.

Q: How do I check WinCC script execution delays?

A: Launch the Siemens APDiag utility from C:/Program Files (x86)/Siemens/WinCC/uTools/apdiag.exe and monitor script cycle queues.

Technical References

Related Articles

Related Tags

CEMAT V9.1, Faceplate Performance, Virtualization, ESXi Optimization, WinCC Graphics

20 respuestas