1. Overview: WinCC Long-Term Tag Archiving Requirements
Recording approximately 20 process tags at a 10-second sample interval for a continuous 365-day window is a standard demand in water treatment, wastewater, and utility SCADA applications. Siemens WinCC (both SIMATIC WinCC V7.x and WinCC Professional in the TIA Portal) supports this natively through its Tag Logging subsystem backed by Microsoft SQL Server. The standard runtime license already covers archive operation; the engineering effort is in correct sizing of segments, paths, and swap-out behavior rather than in buying extra options for a 20-tag load.
This reference walks through the mathematical sizing of the archive, the configuration of Tag Logging in WinCC Explorer and in TIA Portal, the database segment strategy, swap-out file behavior, and the path to the optional Central Archive Server (CAS) when redundancy or longer retention is required.
2. Prerequisites
Before opening the WinCC project, verify the following platform items.
- Runtime: SIMATIC WinCC V7.4 SP3 or later (V7.5 SP2 recommended), or TIA Portal V17/V18 with WinCC Professional V17/V18 Runtime. See the Siemens WinCC manual collection for the manual set shipped with your build.
- Database: Microsoft SQL Server 2017/2019, 64-bit, installed by the WinCC setup. WinCC owns its instance (WINCC) and configures the tempdb and primary file groups automatically.
-
Disk: Separate physical or logical volume for the archive database path (default:
C:\Program Files\Microsoft SQL Server\MSSQL15.WINCC\MSSQL\DATAon SQL 2019). Do not co-locate archive data on the system partition if you want predictable performance. - Licenses: WinCC RT (RC 1024 or higher depending on tag count). Tag Logging does not require an additional option; only the number of archive tags is counted against the powerpack limits.
- Authorizations: Local administrator right during configuration; "SIMATIC HMI" or WinCC administrator role during runtime.
3. Archive Sizing Calculation
3.1 Sample Volume
Number of samples per tag per year at a 10-second sampling rate:
samples_per_tag = (365 d × 86,400 s) / 10 s = 3,153,600
Across 20 tags:
samples_total = 20 × 3,153,600 = 63,072,000
3.2 Raw Data Volume
Each tag value in the SQL dbo.ARCHIVE table occupies roughly 20 bytes when WinCC writes a tight record (8-byte timestamp, 8-byte value, 4-byte quality/status flags).
raw_size = 63,072,000 × 20 B ≈ 1.205 GiB
3.3 SQL Server Overhead Factor
SQL Server pages are 8 KiB. After page overhead, index entries (clustered PK on timestamp + tag ID), LOB storage for long-string tags, internal fragmentation, and the unallocated-space reservation in the MDF file, a multiplier of 3.5× to 5× is realistic for a clean database. Field experience on water treatment stations repeatedly lands between 4 GiB and 5 GiB for the stated workload, which matches the published Siemens Support Entry ID 22413908 on archive data volume calculation. Reserve 10 GiB on the archive volume to keep two on-line segments plus headroom for slower values, sporadic events, and operator-driven annotation tags.
| Component | Bytes per record | Records/yr | Size |
|---|---|---|---|
| Timestamp (datetime2) | 8 | 63,072,000 | ~481 MiB |
| Process value (float64) | 8 | 63,072,000 | ~481 MiB |
| Status / quality | 4 | 63,072,000 | ~241 MiB |
| Row + page overhead | ~36 | 63,072,000 | ~2.15 GiB |
| Indexes, fill-factor slack | ~14 | 63,072,000 | ~840 MiB |
| Net on disk (no compression) | ~20 effective | 63,072,000 | ~4.0 GiB |
3.4 When the Figure Inflates
Add disk budget when any of the following apply:
- String-tag archival (operator messages, batch IDs) — each record can exceed 4 KiB.
- Compressed bit archives with sub-second clock jitter — WinCC writes a "compressed" archive by dead-band, which can either reduce or increase volume depending on noise. Bench-mark your real signal.
- Swap-out file (single-sided) on a network share — latency spikes can cause WinCC to buffer locally, doubling apparent disk use.
- SQL Server transaction log growth — leave 2–3× the data volume for the LDF file until you schedule regular log backups.
4. Tag Logging Configuration in WinCC V7.x
4.1 Create the Archive
- In WinCC Explorer, right-click Tag Logging → Open.
- Right-click Archives → New Archive. Choose Process Value Archive. Name it
WTP_Process_1Y. - In the Properties dialog, set:
- Archive type: Process value archive (continuous).
- Storage location: Local drive (default) — change the path only if the project mandates a separate volume.
- Size of online archive: 1,825 days (≈ 5 years buffer) so that the runtime never auto-deletes within the first year even under compression variability.
- Segment size: 7 days. A weekly segment matches typical maintenance cycles and makes online backup predictable.
- Confirm the Swap-out time (default 24:00) — archives close daily at midnight and the next segment opens. This is when the swap-out file (extension
.bkf) is written to the configured backup path.
4.2 Register the 20 Process Tags
- Right-click the new archive → New Tag.
- For each of the 20 tags set:
- Tag name: same name as the WinCC tag or process tag from the PLC.
- Supplying tag: select the matching WinCC tag.
- Acquisition cycle: 10 s (must match the WinCC tag's update cycle; otherwise WinCC samples at the slower of the two).
- Archiving cycle: 10 s.
- Archiving type: Continuous, or On change with a meaningful dead-band (e.g., level ± 0.02 m).
- Compression: Off (or set to 500 ms if your value changes faster than the acquisition cycle and you want to keep the database compact).
4.3 Trigger and Swap-Out Path
- In Computer → Properties → Tag Logging, set:
- Trigger: 500 ms (default is fine).
- Timeout: 5 s.
- Time base: Local time, with daylight-saving handling per the WinCC V7.5 manual.
- Configure the Backup path on a separate physical drive from the runtime database. On swap-out, WinCC writes the closed segment here and can delete the original after a configurable retention period.
- Set Keep online segments: to the number you can afford on the local database volume. With weekly segments and 10 GiB budget, leave 5–10 online.
5. Tag Logging Configuration in TIA Portal WinCC Professional
- Open the HMI device → Historical data → Archives.
- Add a Tag log. The runtime equivalent is the SQL Server log database
<ProjectName>_Log. - Add 20 Logging tags:
- Acquisition mode: Cyclic, 10 s.
- Logging mode: Cyclic, 10 s.
- Enable the Persistent property so values survive a power-loss event.
- Configure Storage location: local (default) or a network share. Avoid SMB shares with high latency; use a NAS with iSCSI or a local SSD for the active segment.
- In Runtime settings → Historical data, set the Segment time to 7 days and define a swap-out path. The path must exist on the runtime station; WinCC does not create intermediate directories on remote shares.
6. Database Maintenance and Long-Term Storage
6.1 SQL Server Backup Strategy
With 4–5 GiB of yearly volume, schedule a SQL maintenance plan on the WinCC station itself:
-
Daily: Full backup of
WINCCsystem database and the project databaseCC_<ProjectName>_<TS>_<R>. Retain 7 daily backups. - Weekly: Differential after the Sunday full backup.
- Hourly: Transaction-log backup if you need point-in-time recovery; otherwise trim the LDF file weekly to keep it under 5 GiB.
Use the sqlmaint.exe command-line or SQL Server Management Studio. The WinCC manual "WinCC V7.5 SP2 — Process Control" chapter "Data Archiving — Database Administration" lists the supported maintenance commands.
6.2 Swap-Out to NAS or Tape
Configure the swap-out file path on the same drive as the SQL backups so the weekly archive segment is rotated alongside the SQL backup. A typical one-year rotation ends with 52 swap-out files of ~80 MiB each, comfortably below 5 GiB. Restore is via the Tag Logging — Restore Archive dialog in WinCC Explorer.
7. Central Archive Server (CAS) Option
If the runtime station has limited local disk or you need to keep multiple plants on a single archive database, deploy WinCC/CAS V7.x as a stand-alone archive server. CAS is a separately licensed option (order number 6AV6371-1CA07-0AX0 for V7.5). The WinCC runtime only writes via a server–server connection; CAS owns the long-term storage and serves WinCC DataMonitor clients for trends and reports.
| Aspect | Local Tag Logging | Central Archive Server (CAS) |
|---|---|---|
| License cost | Included in WinCC RT | Additional option per server |
| Failure domain | Single WinCC station | Redundant pair with WinCC/Server redundancy |
| Typical retention | Months to ~3 years local | 5–10 years, depends on disk |
| Client access | WinCC station or DataMonitor | All WinCC/DataMonitor clients on the plant network |
| Disk floor for 20 tags × 10 s × 1 yr | ~10 GiB local | ~5 GiB on CAS volume + redundant path |
CAS does not increase the on-disk volume per sample; it only consolidates multiple WinCC stations into one archive farm. For a single-station water treatment plant with 20 tags, CAS is not strictly required. Consider it when you also want to give operators a single DataMonitor URL for trending across multiple plants.
8. Trend Display in Runtime
- In the graphics designer, insert a WinCC Online Trend Control.
- Add the 20 archive tags to the trend's value columns.
- Set Time range = "User-defined", with the default 1-hour window.
- Configure Selection buttons for 1 h / 8 h / 1 d / 7 d / 30 d / 1 year so operators can navigate to the full annual view.
- Enable Compress data on the trend. With 3.15 million samples per tag, the trend control must compress the display — otherwise drawing 365 days at 10 s resolution stalls the picture. The standard 1000-point compression is sufficient.
- For a year-long overview, switch the trend to Statistics mode and select the average/min/max reduction; this drops the visible points to a few thousand while preserving the 1-year envelope.
9. Verification and Health Checks
-
Disk check: After one week of runtime, query the MDF file size:
SELECT name, size*8/1024 AS MB FROM sys.database_files WHERE type_desc='ROWS';Multiply the result by 52 to extrapolate the annual volume. If the projection exceeds 8 GiB, re-evaluate dead-band or compression. -
Sample count check:
SELECT COUNT(*) FROM dbo.ARCHIVE WHERE TagID IN (SELECT TagID FROM dbo.Archive WHERE ArchiveName='WTP_Process_1Y');For 20 tags × 7 days × 86,400 / 10 = 1,209,600 samples per week — divide by 7 to compare against the daily rate. - Trend view test: Open the trend picture, select the 1-year time range, and verify that the picture redraws in < 2 s. Anything slower indicates missing compression.
-
Swap-out test: Force a swap-out by reducing the segment size temporarily to 1 hour, confirm the
.bkffile appears in the backup path, then restore the original 7-day segment. - Redundancy test (optional): If CAS is in use, stop the primary CAS and verify that the WinCC station reconnects to the redundant CAS within the configured timeout (default 30 s).
10. Troubleshooting Matrix
| Symptom | Likely Cause | Corrective Action |
|---|---|---|
| Trend picture freezes when zoomed to 1 year | Compression disabled on the control | Enable compression to 500–1000 visible points |
| Archive grows faster than calculated | String tags archived as continuous, or compressed-bit dead-band too tight | Audit archive configuration; remove string tags or switch to event-driven |
| Swap-out fails every Sunday | Backup path unreachable, no write permission | Check share ACLs, run WinCC as a service account with write access |
| SQL transaction log fills disk | Recovery model FULL with no log backup | Switch project DB to SIMPLE recovery, schedule weekly log backup |
| Gaps in trend after power loss | Persistent storage disabled in TIA Portal | Enable Persistent property on every Logging tag |
| DataMonitor cannot connect | DCOM not configured, SQL Browser service disabled | Enable SQL Server Browser, open TCP 1433, configure WinCC firewall rules |
| Time skew between WinCC tag and archive timestamp | Station time not synchronized to GPS/NTP | Point Windows Time service to a stratum-1 NTP source |
11. Field-Proven Caveats
- Daylight saving: WinCC V7.5 stores local time with DST flag. When trending across the DST boundary, the trend control shows a 1-hour shift if the operator's local time zone differs from the station. Document the time base in the operating manual.
- PLC time vs. station time: If the PLC uses SIMATIC time and WinCC uses local time, the first archive entry of every shift can drift by seconds. Enable time synchronization between the PLC and the WinCC station via NTP or WinCC Time Sync.
-
Antivirus: Exclude the SQL data directory and the swap-out path. Some antivirus products quarantine
.mdffiles during real-time scans, which surfaces as "archive not accessible" alarms. - Power-loss scenarios: Without an uninterruptible power supply, the swap-out file is most exposed. Use a small UPS (≥ 10 minutes runtime) on the WinCC station so the runtime can close the current segment cleanly.
-
Clock resolution: SQL Server's
datetimetype has 3.33 ms resolution — fine for 10 s sampling. If you ever drop below 1 s, switch todatetime2via the WinCC migration tool.
12. Summary
Twenty tags at 10-second intervals over one year require roughly 4–5 GiB of SQL Server storage in a standard WinCC installation — well inside the local disk budget of any properly sized SCADA station. The standard WinCC runtime license is sufficient; no extra option is needed for this workload. Configure a weekly segment, point the swap-out path at a separate volume, schedule SQL backups, and enable trend compression for the 1-year view. Step up to Central Archive Server only when you consolidate multiple plants or want year-long redundancy.
How much disk space does WinCC need for 20 tags at 10-second sampling for one year?
Approximately 4–5 GiB for the SQL Server data files, plus an additional 2–5 GiB for transaction logs and indexes. Allocate at least 10 GiB on a dedicated volume to keep two online segments plus headroom. See Siemens Support Entry ID 22413908 for the calculation template.
Does WinCC require an extra option or license to archive tags for one year?
No. Tag Logging is part of every WinCC Runtime license. Central Archive Server (CAS, order number 6AV6371-1CA07-0AX0 for V7.5) is an option only when you want to consolidate archives across stations or require redundant long-term storage.
Which WinCC version supports one-year continuous trending?
Any current WinCC V7.4 SP3 or later, or TIA Portal V16+ with WinCC Professional. Older V7.0 stations have a 12-month limit on continuous archives and should be upgraded.
How do I prevent the archive database from filling the system disk?
Move the SQL data files to a dedicated volume during installation, configure 7-day segments, enable a swap-out path on a separate drive, and run a weekly SQL maintenance plan with full backups plus transaction-log truncation.
Why does my one-year trend picture redraw slowly or freeze?
The trend control is trying to draw 3 million points per tag. Enable data compression on the trend (500–1000 visible points) or switch the view to statistics mode with average/min/max reduction. Without compression, no SCADA station can render a full year at 10-second resolution interactively.