Resolving WinCC 7.2 Alarm Archive Text Display Failure

David Krause11 min read
SiemensTroubleshootingWinCC
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Problem Description: Alarm Numbers Visible, Text Missing

In SIMATIC WinCC V7.2 (Classic) projects, the Alarm Logging runtime views (Short-term archive and Long-term archive) display only the numeric message identifiers while the Active alarm list renders the configured message text correctly. Operators see columns such as Number, Time, Date, and State populated, but the Message text, Point of error, and Info columns appear blank or show only the configured numeric ID.

This is a classic symptom of a text/language mismatch between the Text Library source of the WinCC project and the language table that the Alarm Logging Runtime database uses to resolve text IDs in archive segments. The active list reads from the live configuration cache, so it succeeds; the archive reads from the persisted .mdf / .ldf segments under \\ArchiveManager\AlarmLogging, and that persistence is where the language resolution breaks.

Symptom summary: Active alarm window = text OK. Short-term and long-term windows = text blank, only message number visible. No SQL errors logged in WinCC_Sys_01.log / WinCC_Sys_02.log.

Affected Versions and Project Variants

WinCC Version Edition SQL Backend Status
V7.2 (6.2.x) RT / RC / ES MS SQL Server 2008 R2 / 2012 Confirmed affected
V7.2 SP1 RT / RC / ES MS SQL Server 2012 SP1 Affected when >1 RT language active
V7.2 SP2 RT / RC / ES MS SQL Server 2014 Affected when Text Library drift present
V7.3 / V7.4 / V7.5 RT / RC / ES MS SQL Server 2014 / 2016 / 2017 Same root cause may recur
WinCC Unified (TIA V16+) RT Unified Internal SQLite / PostgreSQL Different mechanism; see Unified reference

The fix path described below targets the Classic CSK (Communication Server / Knowledge) database. Unified RT stores multilingual alarm texts in a different structure and is not resolved by deleting the *Alg.mdf / *Alg.ldf pair.

Root Cause Analysis

Three independent failure paths produce the same observable symptom. Diagnose all three before applying any destructive fix.

Cause 1 — Text Library Language Drift

The WinCC Text Library (opened from the WinCC Explorer: Text Library → Open) is the central registry of translatable strings. Every configured text receives a Text ID (an integer), and the runtime resolves text from the per-language column for the currently selected runtime language. When a project accumulates many runtime languages (e.g. 15 languages imported through Text Distributor from a master project, template, or migration), the Alarm Logging archive segment captures the language list at segment creation time. If a runtime language is added, removed, or renumbered after a segment is already on disk, the segment's language table no longer matches the live Text Library, and the JOIN inside Alarm Logging returns NULL for the text column.

The symptom: the Active list reads the in-memory config and resolves text correctly, but the Archived list reads the frozen segment, which still references the deleted or renumbered language ID.

Cause 2 — Template Segment Stale State

WinCC creates a template database segment when the runtime first initializes Alarm Logging. This template lives at:

\<WinCC_Project_Path>\<ProjectName>Alg.mdf
\<WinCC_Project_Path>\<ProjectName>Alg.ldf

The template defines the language metadata and column layout for every subsequently created archive segment. If the template was generated against a corrupted or mismatched language set, every new segment inherits the broken state. Recreating the template forces Alarm Logging to rebuild the column layout from the current Text Library.

Cause 3 — Text Distributor Import Mismatch

The Text Distributor (WinCC Explorer → Text Library → Text Distributor) exports and imports the multilingual text table between projects. Importing a distributor file from a project that uses a different default language, a different default fallback order, or a subset of the receiving project's language IDs can leave the receiving project with orphaned Text IDs. The Text Distributor dialog exposes the per-language row count; an unexpected count (zero, or a number that does not match the master) is a strong indicator.

Pre-Diagnosis: Data to Capture

Before any change, capture the following from a working copy of the project (read-only, not the running RT):

  1. Project path and computer name from the WinCC Explorer title bar.
  2. Runtime languages configured: WinCC Explorer → Computer → Properties → Graphics Runtime → Languages tab. Record the order of the runtime languages and the configured default.
  3. Text Library per-language row count: WinCC Explorer → Text Library → Open. Note row count for each language column. The English (USA) / English (UK) / fallback language should match expected catalog size.
  4. Archive segment list: WinCC Explorer → Alarm Logging → Archives. Screenshot the segment list with sizes and time ranges.
  5. SQL Server state: SQL Server Configuration Manager → confirm the WinCC MSSQLSERVER instance is running; check the SQL log path C:\Program Files (x86)\Microsoft SQL Server\MSSQL<instance>.MSSQLSERVER\MSSQL\Log.
  6. WinCC diagnostic files: copy WinCC_Sys_01.log, WinCC_Sys_02.log, and WinCC_Alarm_01.log from the project \<project>\ directory.

Solution A — Repair the Text Library (Most Common Fix)

This is the resolution that resolved the original report: a project that had 15 imported languages in the Text Library, where the Alarm Logging database had been written against a different English variant than the one the runtime language list resolved to.

Step-by-Step

  1. Close the WinCC Runtime on the target computer. From the system tray, right-click the WinCC icon and choose Exit WinCC Runtime, or from the WinCC Explorer toolbar click Deactivate.
  2. Stop the SQL Server WINCC instance to release file handles: SQL Server Configuration Manager → SQL Server Services → SQL Server (WINCC) → Stop. Wait for the WinCC Connectivity Station Service and any CCAlgRtHmi process to terminate.
  3. Open WinCC Text Library (WinCC Explorer → Text Library → double-click the editor). In the language list at the top, write down the order and the IDs of every language. Typical drift symptom: English (USA) shows zero rows or has been silently replaced by English (UK) or another variant.
  4. From Text Library → Text Distributor, inspect the per-language row count. If any language used by the active Runtime shows zero rows, that is the broken column.
  5. Delete every language in the list that the project does not require at runtime. Keep exactly one language (the one the project's Alarm Logging messages are written in). In the original report, the operator reduced 15 configured languages to a single language and the archive text returned immediately.
  6. Save the Text Library. Reopen WinCC Explorer and check the project compiles without Text Library Inconsistency warnings in the output window.
  7. Restart the SQL Server WINCC instance.
  8. Start the WinCC Runtime. Trigger a test alarm. Wait one segment rotation (default 1 day, or force-rotate via the Alarm Logging → Connect to Archive API or by waiting the configured segment size).
  9. Open the Short-term archive view and confirm the new alarm has text. Open the Long-term archive and confirm the new alarm has text.
Important: Existing archive segments created with the broken language layout will still display blank text. Only new segments are repaired. To clear old segments, apply Solution B.

Solution B — Recreate the Alarm Logging Template Segment

Use this procedure to rebuild the *Alg.mdf / *Alg.ldf template when segments are physically corrupted on disk, when the SQL database was migrated without a Text Library reimport, or when the language drift cannot be corrected by editing the Text Library alone.

Step-by-Step

  1. Deactivate WinCC Runtime. Stop the WINCC SQL Server instance as in Solution A.
  2. Open Windows Explorer and navigate to the WinCC project root, typically:
    C:\Program Files (x86)\Siemens\Automation\WinCC\WinCCProjects\<ProjectName>\
  3. Locate the two files:
    <ProjectName>Alg.mdf
    <ProjectName>Alg.ldf
  4. Move both files to a backup folder outside the project tree. Do not delete in place if you want the option to roll back.
  5. Restart the WINCC SQL Server instance.
  6. Activate WinCC Runtime. Alarm Logging will detect the missing template and create a fresh *Alg.mdf / *Alg.ldf against the current Text Library and the current runtime language set.
  7. Verify the new template files exist and are non-zero in size.
  8. Trigger a test alarm, force a segment rotation if your project uses small segments, and confirm text renders in both short-term and long-term views.
Data loss warning: Solution B wipes only the in-flight template. Existing archive segments under \ArchiveManager\AlarmLogging are untouched unless you also delete them. If you need a complete reset, also remove the dated segment files (*Alg_*.mdf / *Alg_*.ldf) after backing them up.

Solution C — Re-Export and Re-Import the Text Distributor

If the Text Library was imported from a master project and the import is suspected to have orphaned IDs, rebuild it from a known-good source.

  1. On a reference project that has the correct text set, open Text Library → Text Distributor → Export. Choose a path and a name (e.g. TextLib_Reference.export).
  2. On the affected project, open the same dialog and click Import. Confirm the language list and row counts match the reference.
  3. If the affected project must keep its own IDs (because external systems reference them), use Text Distributor → Update rather than Import. The Update operation merges by ID and preserves external references.
  4. Save the project, recompile, restart the runtime, and verify per the checklist in the verification section below.

Diagnostic SQL: Direct Verification of Segment Language State

For engineers who need to confirm the diagnosis without touching the GUI, query the Alarm Logging database directly. The WINCC instance hosts a database named CC_<ProjectName>_<TimeStamp> per archive segment, and the template lives in CC_<ProjectName>_Alg_<TimeStamp>. Attach the template MDF in SQL Server Management Studio as a database and run:

SELECT MsgNr, LanguageID, TextLength, Text
FROM dbo.MSGTEXT
WHERE LanguageID = 1033   -- 1033 = English (USA), 2057 = English (UK)
ORDER BY MsgNr;

If Text is NULL for English (USA) but populated for another LanguageID, the runtime language selected at archive write time resolved to a different column than the one the live Text Library uses. Solution A is the correct fix.

Cross-check the active project's configured language list against the segment language table:

SELECT DISTINCT LanguageID FROM dbo.MSGTEXT;
SELECT * FROM dbo.MSGLANGUAGE ORDER BY LanguageID;

Any LanguageID present in MSGTEXT but absent from the WinCC Explorer Runtime Languages list is a candidate for the drift.

Verification Checklist

# Check Expected Result
1 Trigger a new alarm from a configured bit message Message number, time, and full text appear in Active list
2 Wait for the alarm to clear and rotate to archive Short-term view shows the same text as Active list
3 Wait one full segment rotation or force-rotate Long-term view shows the same text
4 Query MSGTEXT in SQL for the segment Text column is NOT NULL for the runtime language
5 Check WinCC_Alarm_01.log for 0x8004xxxx codes No unresolved-text or text-ID-0xFFFF warnings
6 Switch runtime language via the language switcher in RT Text updates in Active and in the latest archive segment

Related: WinCC Unified RT System Alarms

The WinCC Unified runtime (TIA Portal V16 onward) uses a different architecture and stores multilingual alarm text in a separate configuration object. If you migrate the project from V7.2 to Unified, the failure mode above does not apply. Instead, refer to the System Alarms Runtime (RT Unified) reference for canonical error codes raised when the Unified RT cannot reach the target system, when certificates are mismatched, when the configured system ID or system name does not resolve, or when time synchronization is broken.

Common Unified RT system alarm IDs in the same diagnostic family include unreachable target (alarm raised at startup when the HMI device cannot bind to the configured interface), certificate trust chain failure (raised when the Unified RT certificate store does not contain the PLC or CP certificate), and clock skew (raised when the controller and the HMI panel differ by more than the configured threshold).

Documentation References

Why does the Active alarm list show text but the Short-term and Long-term archives show only the message number?

The Active list reads text from the in-memory configuration cache against the live Text Library, which resolves correctly. The archive views read from persisted *Alg.mdf / *Alg.ldf segments that captured the language layout at segment-creation time. If the runtime language set or Text Library drifted after the segment was written, the JOIN inside Alarm Logging returns NULL for the archived rows.

Which files must be deleted to rebuild the Alarm Logging template segment?

Delete the two template files in the WinCC project root: <ProjectName>Alg.mdf and <ProjectName>Alg.ldf. The WinCC runtime recreates them on next activation. Do not delete the dated archive segments (*Alg_YYYYMMDD_*.mdf) unless you want to wipe historical data; back them up first.

How many runtime languages should a WinCC 7.2 project hold to avoid this drift?

Keep only the languages the runtime actually serves on that target. A common field practice is to limit the project to two (the default plus one fallback) and use the Text Distributor → Update operation to merge text from a master rather than Import, which preserves Text IDs.

Can the cause be detected from SQL before any UI change?

Yes. Attach the CC_<Project>_Alg_<TS> database in SQL Server Management Studio and query SELECT DISTINCT LanguageID FROM dbo.MSGTEXT;. Compare the result against the languages listed in WinCC Explorer under Computer → Properties → Graphics Runtime → Languages. Any LanguageID present in the segment but absent from the project is a candidate for the drift.

Does the same fix apply to WinCC Unified RT alarms?

No. Unified RT stores multilingual alarm text in a different object and exposes canonical system alarms for unreachable target, certificate mismatch, wrong system ID or name, and time synchronization faults. Refer to the WinCC Unified RT system alarms reference for the corresponding error codes and remedies.

Back to blog