Resolving OS Compilation Error 12010 (Process Tag Access Failure) via Multiproject Reorganization in PCS 7

Resolving OS Compilation Error 12010 (Process Tag Access Failure) via Multiproject Reorganization in PCS 7

During WinCC OS compilation in SIMATIC PCS 7, the compilation abort error 'Internal Error: A process tag could not be accessed. Error number 12010' indicates database corruption or orphaned cross-reference pointers in the underlying STEP 7 project database. This failure typically arises after deleting technological blocks in CFC, renaming hierarchy folders, or encountering an interrupted compilation that leaves dangling database keys. To resolve Error 12010, engineers must close all active editors, execute 'File -> Reorganize...' on the Multiproject (or perform 'File -> Save As... With Reorganization (Slow)'), recompile CFC charts, and re-run an Entire OS compilation.

Table of Contents

Executive Summary

In SIMATIC PCS 7 engineering environments, the OS Compilation process (executed via the Compile OS wizard) is the primary automated bridge linking the automation station (AS) database to the WinCC operator station database. During OS compilation, the wizard queries the CFC chart database to extract technological blocks marked with the attribute S7_m_c = true, generating WinCC process tags, raw data tags, archive records, and Alarm Logging messages. Frequently, following substantial software modifications, block deletions, or hierarchy restructuring, the compilation halts abruptly with the fatal diagnostic error:

Interner Fehler: Auf eine Prozessvariable konnte nicht zugegriffen werden. Fehlernummer 12010
(Internal Error: Could not access a process tag. Error number 12010)

This technical article details the database mechanisms underlying Error 12010 and provides proven maintenance workflows to restore database integrity.

Root Cause Analysis: Why OS Compilation Fails with Error 12010

The STEP 7 and PCS 7 engineering database architecture relies on relational database tables (Sybase / Microsoft Access / SQL):

  1. Tag Cross-Reference Indexing: When a technological block (e.g. MotL, PIDConL) is instantiated in CFC, the engineering system creates cross-reference records linking the chart, block pin, and WinCC symbol table.
  2. Dangling Pointers from Delta Deletions: If an engineer deletes a CFC chart, moves a block between hierarchy folders, or if an earlier compilation crashed, table records in the STEP 7 project database become orphaned. The index points to an address pointer or tag ID that no longer has a physical technological block instance.
  3. OS Compiler Abort (12010): When the OS compiler traverses the database, it queries the referenced tag. Finding an empty record or broken relational key, the compiler cannot resolve the tag metadata and aborts the compile with Error 12010 to prevent corrupting the WinCC runtime database.

STEP 7 Project Database Structure and Cross-Reference Indices

Understanding the internal structure of the PCS 7 project files clarifies why reorganization succeeds:

  • The *.s7p Container: Holds project metadata and folder relationships.
  • The xrs and hrs Directories: Contain cross-reference data and technological hierarchy indices.
  • Fragmented Database Growth: STEP 7 does not dynamically shrink database files when objects are deleted; it merely flags records as inactive. Over months of engineering changes, database fragmentation accumulates, increasing the probability of index collisions.

The 'Reorganize' Function Mechanics in SIMATIC Manager

SIMATIC Manager provides an integrated database maintenance utility: File -> Reorganize...:

  • Record Purging: The reorganization routine scans all internal project tables, permanently deleting inactive and orphaned records.
  • Index Rebuilding: It defragments data pages and completely rebuilds all primary and foreign key index trees.
  • Cross-Reference Resynchronization: Cleans stale cross-reference pointers, ensuring that only actively instantiated technological tags are presented to the OS compiler.

Step-by-Step Procedure to Resolve Error 12010

To resolve Error 12010 and successfully compile the WinCC Operator Station:

  1. Close All Open Editors: Close CFC, SFC, HW Config, NetPro, and WinCC Explorer across all client and engineering stations.
  2. Execute Reorganize in SIMATIC Manager:
    * In SIMATIC Manager, select File -> Reorganize... from the main menu.
    * In the project selection dialog, select the Multiproject or the specific AS project experiencing compilation errors.
    * Click OK.
    * Allow the progress bar to complete (this may take several minutes depending on project size).
  3. Recompile CFC Charts:
    * Open any CFC chart and execute Chart -> Compile -> Charts as Program.
    * Select Changes only (or Entire program if extensive changes occurred).
  4. Execute OS Compilation:
    * Right-click the OS object in SIMATIC Manager and select Compile.
    * Select Entire OS (with memory reset option if prompted).
    * Confirm that OS compilation completes with zero errors.

Deep Cleanup: When Standard Reorganization Is Insufficient ('Save As With Reorganization')

If running File -> Reorganize... fails to clear Error 12010 due to deep file system corruption:

  1. In SIMATIC Manager, select File -> Save As....
  2. Check the box With Reorganization (Slow).
  3. Specify a new directory path on the local hard drive.
  4. Click OK.
  5. Unlike standard reorganization (which works in place), Save As With Reorganization creates a brand-new database structure from scratch, copying only verified, valid objects and completely discarding corrupt database clusters.

OS Compilation Error Diagnostic and Remediation Matrix

The following table provides diagnosis and remediation for common OS compilation failures:

OS Compiler ErrorUnderlying Root CauseVerification MethodCorrective Engineering ActionInternal Error: 12010Orphaned process tag in STEP 7 databaseReorganization log / compile logRun File -> Reorganize... on MultiprojectMissing server data (pck)OS Server data not generatedCheck Server Data folder in OS projectRight-click Server Data -> Generate on OS ServerTag name collision in WinCCDuplicate tag names across different chartsSearch tag names in Process Object ViewRename block or chart to ensure unique tag nameS7_m_c attribute compilation faultCorrupted block type interface signatureCheck Block Types in CFCRun Options -> Charts -> Update Block TypesCannot open WinCC database (dcf)WinCC project locked by another processCheck Task Manager for CCSetSub.exeClose WinCC and restart engineering station

Verification

Confirm that Error 12010 is fully resolved:

  1. OS Compilation Log Review: Open the OS compilation log file (Compilation.log). Verify that the compilation status displays 0 Errors, 0 Warnings and indicates successful tag transfer.
  2. WinCC Tag Management Inspection: Open WinCC Explorer on the OS Server. Navigate to Tag Management and verify that technological process tags from the affected AS station appear correctly under the named S7 connection.
  3. Alarm Logging Verification: Open WinCC Alarm Logging. Verify that all process messages from newly compiled charts are populated.

Preventive Database Management for Multi-User Engineering Teams

To prevent database index corruption in large collaborative PCS 7 projects:

  • Schedule Regular Reorganizations: Execute File -> Reorganize... at least once per month or following major commissioning phases.
  • Avoid Hard Power Shutdowns: Never perform hard power resets on engineering workstations while SIMATIC Manager or WinCC is open.
  • Use Multi-Engineering Project Check-In/Check-Out: Utilize SIMATIC Version Trail or Version Cross Manager rather than sharing raw network folders without concurrency controls.

Limitations and Operational Precautions

Never run File -> Reorganize... while any other engineer or background process is actively accessing the project files over a network share. Concurrent file locks during reorganization will corrupt the project database irrecoverably.

Always verify that a valid archive backup (File -> Archive...) is safely stored before executing Reorganize or Save As With Reorganization.

Engineer FAQ

Does running 'Reorganize' delete any of my code or logic?

No. Reorganization only purges deleted, marked-for-removal records and defragments database tables; active blocks, charts, and parameters are fully preserved.

What is the difference between Reorganize and Save As With Reorganization?

'Reorganize' compacts the existing database in place, while 'Save As With Reorganization' creates a brand-new database from scratch, providing deeper cleanup.

Can I compile the OS while the AS is in RUN mode?

Yes. OS compilation is an offline engineering process that compiles data from the offline project into WinCC; it does not impact the running controller.

Why does Error 12010 occur mostly after deleting charts?

Deleting charts leaves residual index pointers in the cross-reference tables; if the OS compiler encounters these dangling keys before a reorganization, it triggers Error 12010.

Technical References

Related Articles

Related Tags

8 respuestas