How to Resolve SIMATIC Process Historian Not Storing Process Tags and Messages

How to Resolve SIMATIC Process Historian Not Storing Process Tags and Messages

To resolve the condition where SIMATIC Process Historian (PH) establishes a network connection to WinCC OS Servers but fails to store incoming tags and messages, engineers must resolve redundant server synchronization, clear corrupted Store-and-Forward cache (SFCache), and verify long-term archive attributes. In redundant OS environments, OS Servers will NOT forward archive data to the Process Historian until redundancy synchronization between Server A and Server B is 100% complete (Successful). If synchronization hangs or local cache files become corrupted, data ingestion stalls. The proven recovery workflow requires stopping runtime on both OS servers, deleting corrupted cache files in C:/ProgramData/Siemens/SFCache, purging stale fast/slow logging temporary buffers, restarting Server A, and allowing Server B to achieve full redundancy synchronization before validating PH data ingestion.

Table of Contents

Store-and-Forward Architecture in SIMATIC Process Historian

SIMATIC Process Historian (PH) functions as the central long-term archive server for SIMATIC PCS 7. Rather than streaming raw process values synchronously, the system uses an asynchronous Store-and-Forward architecture:

  1. Local Tag & Alarm Logging: WinCC OS Servers log historical data locally into cyclic circular segments (Tag Logging Fast, Tag Logging Slow, and Alarm Logging).
  2. PH-Ready Component (CCCAPHServer): Reads closed archive segments and compresses them into temporary Store-and-Forward cache files (SFCache).
  3. Transport to Process Historian: The cache files are streamed across the terminal bus to the PH server, where the ingestion service writes them into the central Microsoft SQL Server database.

If any link in this processing chain breaks—particularly during initial commissioning or following network interruptions—the PH Management Console will report a connected server status with zero tags and messages stored.

The Critical Role of Redundant OS Server Synchronization

A fundamental operational rule of SIMATIC PCS 7 long-term archiving is that redundant OS Servers will not forward archive data to Process Historian while redundancy synchronization is in progress:

  • When OS Server A and OS Server B are operating redundantly, the redundancy manager (CCRedSync.exe) continuously ensures that both servers have identical archive records.
  • If one server is restarted, has an unsynchronized outage period, or exhibits network packet loss on the redundancy link, the servers enter the 'Synchronizing' state.
  • To prevent duplicate or conflicting records from reaching the Process Historian, the PH-Ready service buffers all outgoing archive packages locally.
  • Only when redundancy synchronization reaches 'Successful' (Synchronized) does CCCAPHServer release the cached data to the Process Historian. If redundancy synchronization deadlocks, no data will ever be stored in PH.

Store-and-Forward Cache (SFCache) Corruption Mechanisms

The Store-and-Forward cache is stored locally on each WinCC OS Server at:
C:\ProgramData\Siemens\SFCache\<PH_Server_GUID>\

Corruptions or stalls in this cache occur due to:
1. Unclean System Shutdowns: Power loss or hard task kills leaving fragmented .tmp cache blocks that lock the transmission queue.
2. Mismatched Service Logon Credentials: CCCAPHServer running under an account that lacks write permissions to C:\ProgramData\Siemens\SFCache.
3. Terminal Bus Name Resolution Failures: OS Servers unable to resolve the PH server NetBIOS/DNS hostname, causing retry loops that overflow cache storage.

Step-by-Step Recovery Procedure: Clearing Cache and Resynchronizing

Follow this comprehensive procedure to clear corrupted buffers and restore data ingestion into Process Historian:

Step 1: Deactivate Both Redundant OS Servers

  1. Deactivate WinCC Runtime on OS Server B (Standby). Wait until deactivation is complete.
  2. Deactivate WinCC Runtime on OS Server A (Master). Wait until deactivation is complete.
  3. Close WinCC Explorer on both machines.

Step 2: Clear Corrupted Cache and Local Temporary Buffers

  1. On both OS Server A and OS Server B, open Windows Explorer:
    * Navigate to: C:\ProgramData\Siemens\SFCache\
    * Delete all files and subfolders within SFCache (the cache folder will regenerate automatically upon startup).
  2. In the WinCC project directory on both servers:
    * Navigate to: <Project_Dir>\ArchiveManager\
    * Delete stale temporary files in TagLoggingFast, TagLoggingSlow, and AlarmLogging (do not delete core configuration databases).

Step 3: Sequential Startup and Redundancy Resynchronization

  1. On OS Server A, start WinCC Explorer and activate Runtime.
  2. Wait until Runtime is completely operational and graphic displays update normally.
  3. On OS Server B, start WinCC Explorer and activate Runtime.
  4. Monitor the WinCC Redundancy status via @RM_Master / @RM_State system tags or WinCC Channel Diagnosis.
  5. Wait until redundancy synchronization completes 100% ('Successful').

Step 4: Verify Transmission to Process Historian

Once synchronization is successful, CCCAPHServer will immediately begin transferring newly generated archive packets to Process Historian.

OS Compilation and Long-Term Archive Configuration Prerequisites

If no tags are stored even after clearing cache and synchronizing redundancy, verify the engineering configuration:

  1. Tag Archive Properties: In SIMATIC Manager Process Object View or CFC, verify that process tags have 'Long-term archive' selected (not just short-term circular archive).
  2. OS Compilation with Memory Reset:
    * Right-click the OS project -> Compile.
    * Under Options, select Entire OS and check the box 'With memory reset'.
    * This rebuilds the archive catalog and regenerates ProcessHistorian.cfg in the project root.
  3. Verify ProcessHistorian.cfg:
    * Open <Project_Path>\WinCC\ProcessHistorian.cfg in Notepad.
    * Verify that the ServerName parameter matches the exact Windows computer name of the Process Historian server.

Process Historian Ingestion Diagnostic and State Matrix

The following table outlines the diagnostic states, locations, and recovery actions for Process Historian archiving:

Diagnostic IndicatorSystem LocationRoot CauseCorrective ActionOS Server Connected; 0 TagsPH Management ConsoleRedundancy sync ongoing or cache lockedWait for sync 'Successful'; clear SFCacheSFCache folder missing or emptyC:\ProgramData\Siemens\CCCAPHServer service logon failureRun PH-Ready Config; grant service rights'Transfer to external archive' uncheckedWinCC Archive ConfigurationLong-term transfer disabled in OS projectCheck 'Transfer to external archive' in OSDNS / Ping timeout to PHTerminal Bus NICMissing hosts / lmhosts entryAdd static IP/hostname mapping to hostsDatabase growth stalled on PHSQL Server Management StudioLicense shortage or SQL disk fullCheck ALM archive licenses; expand disk pool

Resolving redundancy and cache bottlenecks restores high-speed historical data streaming.

Verification

To verify that Process Historian is actively storing process data:
1. Open the Process Historian Management Console (PHMC) on the PH server.
2. Navigate to System Status -> Data Sources:
* Verify that both OS Servers show state 'Active / Connected'.
3. Under Performance Metrics, observe the Tags/sec and Messages/sec counters: Confirm that counters indicate incoming data transactions (> 0).
4. Launch Information Server or open a WinCC trend control configured for long-term historical data; confirm that historical values render across the full timeline.

Limitations and Operational Precautions

  • Never delete the Microsoft SQL Server database files (HISTORIAN.mdf/.ldf) on the Process Historian server during troubleshooting.
  • Ensure both redundant OS servers have synchronized system clocks (NTP via SICLOCK or domain controller) to avoid time-travel rejected archive segments.
  • Clearing SFCache permanently discards unstreamed buffer packets generated during the outage window; execute only when recovering from corrupted stalls.
  • Always validate final license quantities, archive tag volumes, and MLFBs against the applicable Siemens catalog and authorized distributor quotation.

Engineer FAQ

Why does Process Historian report 'Connected' if no data is being transferred?

'Connected' simply indicates that the TCP handshake on ports 4222/4223 succeeded and the service is communicating. Data transfer requires active archive triggers, completed redundancy sync, and healthy cache queues.

How long does redundancy synchronization take after restarting an OS server?

Depending on the duration of the server outage and archive volume, synchronization can take from 5 minutes to several hours. During this period, PH transfer is intentionally suspended.

Can I force an OS server to send data to PH without waiting for redundancy sync?

No. By design, the WinCC Redundancy architecture suppresses external archive streaming during synchronization to preserve archive consistency.

Technical References

Related Articles

Related Tags

  • Process Historian
  • Store and Forward
  • SFCache
  • No Tags Stored
  • OS Redundancy Sync
6 respuestas