Problem Description
On WinCC V6.2 SP3 stations, the HMI/SCADA Runtime can shut down unexpectedly. When the operator (or technician) attempts to deactivate Runtime from the WinCC Explorer, the supporting process WinCC.CCHierarchySrv.1 enters a non-responsive state. The Windows shutdown tracker raises a 2-minute "Application not responding" warning, and only a forced termination of the process returns control to the operator. The Runtime can then be restarted, but the failure repeats after a variable interval (typically minutes to hours).
This symptom set is a regression introduced when migrating from WinCC V6.2 SP2 to V6.2 SP3 on Windows XP SP3. Sites that ran the same project under SP2 on the same hardware and OS image report no failures. The fault therefore originates in the SP3 update of the WinCC COM/DCOM layer rather than in the user project itself.
CCHierarchySrv.1 fails to release its COM references, (3) the WinCC Explorer status pane shows "Deactivating Runtime..." indefinitely, (4) the OS prompts the user to terminate the process, and (5) the WinCC Runtime window disappears with the kernel tearing down the child processes.Environment and Affected Versions
The fault is observed under the following configuration matrix. Values not confirmed by the source are marked as "case to evaluate".
| Component | Confirmed value | Case to evaluate |
|---|---|---|
| WinCC version | V6.2 SP3 | Earlier SPs, hotfix roll-ups |
| OS | Windows XP SP3 | Windows Server 2003 SP2 single-station |
| Project type | Single-user / multi-user (client) | Redundancy server pairs |
| Project source | Upgraded from V6.2 SP2, possibly from V4/V6.0 via Project Migrator | Native V6.2 SP3 build |
| Deactivation path | WinCC Explorer "Deactivate Runtime" button | Runtime internal deactivation (recommended workaround) |
For projects originally authored under older WinCC releases, the Project Migrator path described in the Siemens migration documentation is a relevant diagnostic step. See the official PDF Migration of WinCC Projects from V4 to V6.2 SP3 for the upgrade flow and the location of the diagnostic file written by the migrator.
WinCC.CCHierarchySrv.1 Architecture Overview
WinCC Runtime is built as a set of cooperating COM/DCOM processes. WinCC.CCHierarchySrv.1 is the central component that owns the in-memory hierarchy of all WinCC objects: tag connections, alarm classes, archive configurations, picture tree, user archive structure, and the S7/MPI/TCP driver bindings. Other WinCC Runtime processes (Graphics Runtime, Alarm Logging, Tag Logging, User Archive, Report Designer) register their COM objects against the hierarchy server. When the hierarchy server cannot shut down cleanly, the dependent processes are also torn down by the OS, which is why the Runtime window disappears.
The component is registered as a Windows service. Its identity, launch permissions, and access permissions are stored in the registry and in the COM+ catalog. SP3 added stricter validation of these permissions and of the caller's authentication level, which is the proximate cause of the hang.
Root Cause Analysis
The hang is caused by a permission or authentication mismatch during COM object teardown. The SP3 installer refreshes the COM+ application registration for the WinCC components. When the WinCC Explorer issues the Deactivate Runtime command, the Explorer process and the CCHierarchySrv.1 process exchange a sequence of COM calls protected by Windows authentication. If the authentication level, identity, or launch/access ACL of either side was not refreshed to match the SP3 catalog, the call blocks on a security negotiation. Because the Explorer is waiting for the deactivation to complete, and the server is waiting for permission to release, the process appears frozen for the duration of the OS-defined timeout (default 120 s on Windows XP/Server 2003).
Common contributing factors confirmed by Siemens support patterns for WinCC 6.2 SP3:
- Service account password rotation. The WinCC services were originally installed under a domain or local user whose password was subsequently changed. The COM+ catalog still holds the old password.
- DCOM hardening applied by Windows XP SP3. The default DCOM authentication and encryption levels are stricter in XP SP3. The legacy WinCC components expect the pre-SP3 levels.
- Local security policy / UAC-equivalent restrictions. Group Policy that restricts "Log on as service" or "Log on as batch job" prevents the COM+ identity from starting.
-
Antivirus / EDR file-locking on the project directory. Real-time scan holds an open handle on a project file;
CCHierarchySrv.1cannot flush and blocks on the file close. - Corrupt or partial migration of the project tree. The Project Migrator diagnostic file lists the components it could not translate. A partial hierarchy causes the server to enter a recovery loop on shutdown.
- Operator discipline: deactivation requested from the WinCC Explorer rather than from within the running Runtime, which is the path the SP3 service expects.
Pre-Diagnostic Data Collection
Collect the following artefacts before changing configuration. This protects the option of opening a Siemens support ticket with full evidence.
| Artefact | Location | Purpose |
|---|---|---|
| Windows Application event log |
eventvwr.msc → Application |
COM+ runtime errors, DCOM authentication failures |
| Windows System event log |
eventvwr.msc → System |
Service Control Manager errors for WinCC services |
| WinCC diagnostic file |
<Project>\<Computer>\<Computer>.log under the project root |
Runtime start/stop sequence, hierarchy server events |
| Project Migrator diagnostic file | Output path defined in migrator; typically <Project>\MigratorDiag.log
|
Lists components the migrator could not translate from V4/V6.0/V6.2 SP2 |
| Process dump |
procdump -ma WinCC.CCHierarchySrv.1.exe CCHierarchy.dmp (Sysinternals) at the moment of the hang |
Stack trace of the blocked thread |
| DCOM config snapshot |
dcomcnfg → Component Services → Computers → My Computer → DCOM Config → WinCC.CCHierarchySrv.1 → Properties |
Identity, Security, Endpoints tabs |
| Service account snapshot |
services.msc → WinCC services → Log On tab |
Confirms the identity under which the service is registered |
| Project file ACL | icacls "C:\WinCC\Projects\<Project>" /T > acl.txt |
Confirms the service account has full control |
Resolution Procedure
Apply the steps in the listed order. Each step ends with a verification check; do not advance until the check passes.
Step 1 — Confirm a Clean Service Account
- Open
services.mscand list every service whose name starts withWinCCorCC. - For each entry, record the Log On As account. The account must be a known local or domain user with a non-expired password.
- If any account is
LocalSystemand the project lives on a network share, change it to a domain user with Log on as service and Log on as batch job rights. - Re-enter the password in the service properties even if it is unchanged, to refresh the LSA secret.
Step 2 — Re-align the COM+ Identity
- Open
dcomcnfg→ Component Services → Computers → My Computer → DCOM Config. - Right-click
WinCC.CCHierarchySrv.1→ Properties. - On the Identity tab, select This user and enter the same user/password used in Step 1.
- On the Security tab, set Launch and Activation Permissions to Customize and grant the WinCC operator group both Local Launch, Remote Launch, Local Activation, and Remote Activation.
- Set Access Permissions to Customize and grant the same group Local and Remote Access.
- On the Endpoints tab, leave the default static endpoints; do not select Use any available port on a firewalled system.
Repeat the same identity/security configuration for every WinCC DCOM application, in particular:
WinCC.PictureWinCC.AlarmLoggingWinCC.TagLoggingWinCC.UserArchive-
WinCC.Connectivity(if used)
Step 3 — Restore the DCOM Authentication Level for the WinCC Components
- Still in
dcomcnfgforWinCC.CCHierarchySrv.1, open the General tab. - Note the AppID. It is a GUID of the form
{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}. - Close
dcomcnfg. - Open
regeditand navigate toHKEY_CLASSES_ROOT\AppID\<AppID>. - Create or modify the value
AuthenticationLevelasDWORD = 0x00000002(Connect) if it is not present, and confirmAccessPermissionandLaunchPermissionhave non-null security descriptors.
AppID key with reg export before any change.Step 4 — Verify and Re-apply Project File Permissions
- Open a command prompt as Administrator.
- Run
icacls "C:\Siemens\WinCC\Projects\<ProjectName>" /T /C /Q > before.txtto capture the current ACL. - Run the WinCC project editor's Project → Properties → Computer → Permissions dialog and re-grant the operator and service accounts. This rewrites the ACLs in the canonical form expected by the SP3 server.
- Re-run the
icaclscommand to a new file and diff against the original.
Step 5 — Exclude the Project Path from Real-Time Antivirus
- Identify the antivirus or EDR product in use.
- Add the following paths to the real-time scan exclusion list, including the executable image files:
C:\Siemens\WinCC\bin\*.exeC:\Siemens\WinCC\Projects\<ProjectName>\**\*C:\Siemens\Automation\**\*.mdfC:\Siemens\Automation\**\*.ldf
- Repeat the Runtime deactivation cycle five times to confirm the hang is no longer triggered by an AV lock.
Step 6 — Re-Register the Project Migrator Output (Projects Originating in V4 / V6.0 / SP2)
- Open the Project Migrator diagnostic file. For V4 → V6.2 SP3 the layout is described in the Siemens document Migration of WinCC Projects from V4 to V6.2 SP3.
- For every component listed as error or warning, open the affected object in the WinCC Explorer of the V6.2 SP3 project, re-save it, and let the hierarchy server re-cache it.
- Repeat the runtime cycle to confirm the CCHierarchySrv.1 process stops cleanly.
Step 7 — Use the Runtime Internal Deactivation Path
The WinCC SP3 service expects the deactivation request to originate from the running Runtime. The Explorer button is a convenience wrapper that, on some installations, does not propagate the correct COM apartment context.
- On a running Runtime, open the standard System picture (or the configured exit button).
- Trigger the configured exit function. The Runtime shuts down internally;
CCHierarchySrv.1is asked to release its COM objects in the correct order. - Confirm the Runtime window closes within 10 seconds and the WinCC Explorer reports Runtime deactivated.
Step 8 — Process Priority and Memory Tuning
| Setting | Recommended | Notes |
|---|---|---|
WinCC.CCHierarchySrv.1 priority class |
Above Normal / High | Set via SetPriority in the service properties, or with Sysinternals Process Explorer for testing |
| Working set minimum/maximum | Min 256 MB / Max 1024 MB | Set on the Recovery tab of the service or with Set-ProcessWorkingSet in PowerShell |
| Windows paging file | 1.5 × installed RAM, fixed size | XP SP3 default is system-managed; switch to fixed for the duration of the fault |
| Desktop Heap | Default on XP, do not modify unless event log shows desktop heap exhausted | Registry: HKLM\System\CurrentControlSet\Control\Session Manager\SubSystems\Windows SharedSection |
Verification Procedure
After applying the resolution steps, execute the following verification matrix. The system is considered healthy only when every row passes.
| # | Test | Pass criterion | How to capture |
|---|---|---|---|
| 1 | Start Runtime from Explorer | Runtime window opens within 30 s, no error in <Computer>.log
|
WinCC Explorer → Activate |
| 2 | Deactivate Runtime from Runtime | Window closes within 10 s, no DCOM warning | System picture → Exit |
| 3 | Deactivate Runtime from Explorer | No process hang within 2 min | WinCC Explorer → Deactivate |
| 4 | Restart Runtime 5 times in 30 min | All 5 cycles complete without intervention | Manual or scheduled task |
| 5 | Force a service-account password rotation and re-test steps 1–4 | All 5 cycles still pass | Active Directory → Reset Password; re-enter in service and COM+ |
| 6 | Review Application event log for COM+ error events | Zero new events with Source = DCOM or COM+ in the 30 min window |
eventvwr.msc → filter by Source |
| 7 | Generate a process dump of CCHierarchySrv.1 after step 3 |
No blocked threads in ntdll!ZwWaitForSingleObject on a COM security call |
WinDbg !locks and kb on each thread |
Escalation Path and Siemens Support
If the verification matrix still fails after applying all eight resolution steps, raise a Siemens support request. Provide the artefacts collected in the Pre-Diagnostic Data Collection section and quote:
- WinCC build string (Help → About → Installed Software → SIMATIC WinCC → Version)
- Service Pack level of Windows (e.g. Windows XP SP3, build 2600.x)
- Project origin (native, migrated from V4, V6.0, V6.2 SP2)
- The full Project Migrator diagnostic file if a migration was performed
Open the request via the Siemens Industry Online Support portal: https://support.industry.siemens.com. Cross-reference the WinCC V6.2 SP3 readme and the SP3 hotfix index from the same portal. The V4 → V6.2 SP3 migration PDF is also reachable from the portal at 44029132_wincc_upgrade_v4-v6.2_V2_3_en.pdf.
Troubleshooting Matrix
| Symptom | Likely cause | First action |
|---|---|---|
| CCHierarchySrv.1 hangs for full 2 min on every Explorer deactivation | COM+ identity password mismatch | Step 1 + Step 2 of the resolution procedure |
| Hang occurs only when project is opened from a network share | LocalSystem identity cannot reach UNC path | Switch service and COM+ identity to a domain user |
| Hang started after a Windows XP SP3 install on a previously working SP2 system | DCOM hardening tightened the default authentication level | Step 3 of the resolution procedure |
| Hang coincides with antivirus signature update | Real-time scan holding a file handle | Step 5 of the resolution procedure |
| Hang is preceded by Project Migrator warnings in the diagnostic file | Partial migration left a corrupt node in the hierarchy | Step 6 of the resolution procedure |
| Hang only on Explorer deactivation, Runtime internal exit works | Caller apartment context incompatibility | Step 7 of the resolution procedure |
| CCHierarchySrv.1 uses 100 % CPU before hang | Insufficient working set, paging thrash | Step 8 of the resolution procedure |
What is WinCC.CCHierarchySrv.1 and why does it block the Runtime shutdown?
It is the central COM server that owns the WinCC object hierarchy (tag connections, alarms, archives, picture tree). When the Explorer issues a deactivation, every dependent WinCC process is asked to release its COM references to the hierarchy server. If the security negotiation between the Explorer and the server fails, the release blocks and the Runtime appears frozen.
Why did the same project work on WinCC 6.2 SP2 but fail on SP3?
SP3 refreshes the COM+ catalog for the WinCC applications and tightens DCOM authentication. Sites that ran SP2 against the same OS image did not have the stricter security checks, so a latent account or ACL mismatch that SP3 enforces for the first time will not surface on SP2.
Is the deactivation workflow from the WinCC Explorer unsafe on SP3?
The Explorer button is supported but it has been observed to leave the COM apartment context inconsistent on some installations. The SP3-safe path is to trigger the exit function from the running Runtime, typically via a button in the System picture. Always retest with both paths after any change to the COM+ identity or the service account.
Where is the Project Migrator diagnostic file located?
The path is set in the Project Migrator tool. For a V4 → V6.2 SP3 upgrade, the file format and behaviour are described in the Siemens document Migration of WinCC Projects from V4 to V6.2 SP3. Use it to identify components that did not migrate cleanly and re-save them in the V6.2 SP3 editor.
How do I capture a process dump of the hung WinCC.CCHierarchySrv.1?
Use Sysinternals procdump -ma WinCC.CCHierarchySrv.1.exe CCHierarchy.dmp at the moment the 2-minute warning is shown. Open the dump in WinDbg and run !locks and kb on each thread to confirm whether a thread is blocked on a COM security call. Include the dump in the Siemens support request.