B.Data Kernel Restart Procedures for WinCC Archive Configuration

David Krause10 min read
SiemensTechnical ReferenceWinCC
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

Overview

B.Data is the Siemens SIMATIC WinCC option for long-term archiving, reporting, and analysis of process values. It runs as a multi-service Windows application that depends on a central kernel process coordinating acquisition, compression, calculation, and dispatch of measurement variables (MEVA) and key performance indicators (KPI). Whenever the underlying database configuration changes—new tags, modified KPI formulas, swapped protocol sources, archive group edits—the in-memory cache held by the kernel becomes inconsistent with the SQL backend. The required corrective action is a controlled kernel restart so the cache is rebuilt from the freshly committed configuration.

This reference consolidates the two supported restart paths (the Hardware node context menu and the command-line batch method), the rule for protocol module inputs (MEVA/KPI, not raw datapoints), the role of the B.Data Logging Viewer as a diagnostic console, and the integration boundary with WinCC OLE DB Provider (RT Professional) for downstream consumers.

Prerequisites and System Architecture

Before performing any kernel operation, confirm the following baseline:

  • Operator/engineering workstation running WinCC V7.4 SP1 or later, or PCS 7 V9.0 SPx with B.Data option installed and licensed.
  • SQL Server instance hosting the B.Data project database is online; verify with SELECT @@SERVERNAME, @@VERSION from SQL Management Studio against the B.Data database.
  • B.Data project is loaded and the project folder (typically C:\BData\Projects\<ProjectName>) is accessible by the B.Data service account.
  • User account performing the restart belongs to the local BDataUsers group and has db_datareader and db_datawriter on the project database.
  • For OLE DB access, the WinCC OLE DB Provider must be installed; this is part of the WinCC RT Professional installation media.
Always perform kernel restarts during a maintenance window. Acquisition is suspended while the kernel reloads the configuration and any in-flight calculation cycles are discarded; the system resumes acquisition only after the new cache is fully built.

B.Data Kernel Architecture

The B.Data runtime consists of three cooperating components:

Component Executable / Service Function
Kernel Kernel.exe under BData\GUI Holds runtime cache, schedules acquisitions, routes protocol modules
GUI / Config BDataConfig.exe Engineering UI for database, KPIs, reports
Logging Viewer LoggingViewer.exe Live event and message stream viewer

The kernel loads its configuration exclusively at startup. Any modification made through the configuration editor (Hardware node, protocol definitions, KPI computations, archive groups, dispatchers) is committed to SQL but is not reflected in the running kernel until the cache is rebuilt by a Start/Restart cycle. This separation is what makes explicit restart mandatory after every change.

Restarting the Kernel via the Hardware Node

This is the canonical GUI procedure and is preferred when an interactive operator is at the engineering station.

  1. Open the B.Data configuration project in the B.Data Configuration editor.
  2. In the project tree, locate the Hardware node representing the runtime server.
  3. Right-click the Hardware node and select Edit... from the context menu.
  4. In the resulting dialog, click the Kernel button. This opens the Kernel Service Cockpit window.
  5. In the cockpit, click Start/Restart. The kernel terminates the running instance and spawns a new one.
  6. Observe the status indicator: it transitions from stopped to starting to running. The full cycle typically takes 10–45 seconds depending on database size.
  7. Close the cockpit and the Hardware editor. The new configuration is now active.
Selecting "Stop" instead of "Start/Restart" halts acquisition without immediately respawning the kernel. Use "Start/Restart" after every configuration commit; "Stop" should be reserved for controlled shutdown before service or OS maintenance.

Batch File Method for Kernel Restart

The batch method is preferred by automation engineers because it leaves a persistent console with status messages and can be called from scheduled tasks, RDP scripts, or remote maintenance shells. The recommended content for a desktop shortcut named kernel.bat:

@echo off
cd\
cd\BData\GUI
Kernel go
pause

Execution behavior:

  • cd\ resets the working directory to the drive root; this prevents inheritance of a wrong drive letter from a UNC path or network share.
  • cd\BData\GUI locates the Kernel.exe binary. If B.Data was installed to a non-default path, substitute the actual installation directory.
  • Kernel go is the supported command-line directive to start or restart the kernel. Alternative directives include Kernel stop, Kernel status, and Kernel reload; consult the B.Data service manual for the full directive matrix.
  • pause keeps the console open so the operator can read the return status and any warnings emitted by the kernel during initialization.

For multi-server installations, repeat the batch invocation on each B.Data server. Each server maintains its own kernel instance and its own cache; there is no cluster-wide restart broadcast.

Protocol Module Configuration: MEVA and KPI Inputs

A common source of "no value" or "no data" reports in B.Data is feeding a raw WinCC datapoint into a protocol module that expects a calculated variable. The protocol modules (used for things like shift reports, energy balancing, and standard-compliant logging) require a measurement variable as input.

Symbol Meaning Typical Source Acceptable as Protocol Input?
DP Datapoint (raw WinCC tag) PLC address mirrored by WinCC Tag Management No
MEVA Measurement Variable (compressed/processed time series) Acquired from DP via compressor or aggregator Yes
KPI Key Performance Indicator (formula-derived) Computed from one or more MEVAs in KPI editor Yes

When configuring a protocol module:

  1. In the project tree, expand the target protocol (for example Standard Daily Report).
  2. Open the variable assignment dialog.
  3. Pick a variable of type MEVA or KPI from the selection list, not a raw datapoint.
  4. Save the protocol definition, then perform a kernel restart as described in the previous sections.

If the selection list does not show any MEVA/KPI candidates, the corresponding measurement variable has not yet been defined in the Database node. Create the MEVA first (with archive group, compression method, and source datapoint), commit, restart the kernel, then return to the protocol definition.

Using the B.Data Logging Viewer for Diagnostics

The Logging Viewer is the first-line diagnostic tool when reports come back empty or acquisition appears stalled. It is accessed from the B.Data administration menu:

  • Start → All Programs → Siemens Automation → B.Data → Administration → Logging Viewer

The viewer shows three live streams:

Tab Contents Use Case
System Kernel startup, shutdown, restart messages Confirm restart cycle completed
Acquisition Acquisition errors, timeouts, source disconnects Investigate missing values
Calculation KPI evaluation results and formula errors Validate KPI inputs and outputs

If a report returns no rows, filter the Logging Viewer on the report's protocol module name and the timestamp of the report period. Look for entries of type WARN or ERROR such as "Source variable not found", "Archive group offline", or "Calculation aborted: divide by zero". These messages pinpoint the exact cause faster than any report-side investigation.

Integrating WinCC Archive Access via OLE DB Provider

Downstream consumers (Excel reports, Power BI dashboards, custom .NET or Python analytics) can read B.Data and WinCC Runtime Professional archives directly through the WinCC OLE DB Provider. The provider exposes archive segments as OLE DB rowsets and supports both tag-value queries and compressed-value queries.

For Runtime Professional (WinCC RT Professional / TIA Portal V21), the access path is documented in the Siemens TIA Portal Help: Access to archive data via WinCC OLE DB Provider (RT Professional).

Key technical points when connecting B.Data-sourced data to OLE DB:

  • The connection string uses provider WinCCOLEDBProvider.1 for the classic WinCC Runtime archive and the equivalent RT Professional connector for TIA-based projects.
  • Query parameters require PACK (number of values), STARTIME and ENDTIME in ANSI date format, and the TAGNAME matching the B.Data MEVA name exactly (case-sensitive).
  • For compressed archives, include MODE=COMPRESSED; for raw data, omit it.
  • Authentication follows the WinCC user administration; the connecting user must have archive read rights assigned.

Example SQL query fragment against a B.Data-fed MEVA named Boiler1_Temperature:

SELECT * FROM OPENQUERY(WinCCArchive,
  'TAG:Boiler1_Temperature,''0000-01-01 00:00:00'',''9999-12-31 23:59:59''',
  'PACK:2')

Always validate that the kernel has completed its restart before issuing OLE DB queries; queries issued during the cache rebuild may return incomplete or stale result sets.

Troubleshooting Matrix

Symptom Likely Root Cause Verification Step Corrective Action
Configuration changes do not appear at runtime Kernel still holds old cache Kernel Service Cockpit shows uptime > edit time Start/Restart kernel via Hardware node or Kernel go
Report returns no rows Protocol module bound to raw datapoint instead of MEVA/KPI Open protocol definition and inspect variable type Reassign to MEVA/KPI, save, restart kernel
KPI evaluates to 0 or NaN Formula references missing MEVA Logging Viewer shows "Source variable not found" Define the missing MEVA, restart kernel, re-evaluate
Acquisition freezes after restart Kernel cannot connect to SQL Server Logging Viewer shows DB connection error Verify SQL service, named pipes / TCP enabled, firewall rules
OLE DB query returns empty Query issued before kernel restart completed Check kernel status; wait for "running" state Re-run query after kernel confirms "running"
Batch file flashes and disappears Working directory incorrect or Kernel.exe not on path Run dir C:\BData\GUI\Kernel.exe Update batch to actual installation path

Verification After Kernel Restart

After every restart, run the following verification checklist before declaring the system ready:

  1. In the Kernel Service Cockpit, confirm status indicator shows running and uptime reads as expected.
  2. In the Logging Viewer (System tab), look for the line "Kernel ready, accepting requests".
  3. Open a representative MEVA trend in the B.Data trend control or in WinCC Trend Control; verify new values arrive at the configured acquisition cycle.
  4. Manually trigger a test report for a recent shift; confirm rows appear.
  5. From a downstream consumer, issue a minimal OLE DB query (for example, last 10 values of one MEVA) and confirm the result set.
If verification step 3 fails, do not assume the restart was successful. Repeat the restart, this time watching the Logging Viewer (Acquisition tab) for early error messages; the kernel may have started but failed to bind to one or more acquisition sources.

Best Practices for Stable Operation

  • Make all related configuration changes in a single batch, then perform exactly one kernel restart. Multiple restarts in quick succession waste acquisition cycles and can mask configuration mistakes.
  • Maintain a change log; record the timestamp, the operator, and the nature of every change that requires a restart. This makes regression analysis dramatically faster when reports later appear inconsistent.
  • Schedule kernel restarts outside acquisition-critical periods whenever possible. For continuous processes with shift-based reporting, target the inter-shift boundary.
  • Keep the Logging Viewer open on the engineering station during the first 10 minutes after every restart; early warnings are easier to act on than post-mortem analyses.
  • Document the B.Data installation path in operational procedures. Custom installations to D:\Siemens\BData or similar non-default locations break the canonical batch file and are a common source of "nothing happens" troubleshooting tickets.

FAQ

Why must the B.Data kernel be restarted after every database change?

The kernel holds an in-memory cache of the project configuration. Changes committed through the configuration editor are written to SQL but the running kernel does not pick them up automatically. A Start/Restart cycle rebuilds the cache from the updated SQL state.

Can I feed a raw WinCC datapoint directly into a B.Data protocol module?

No. Protocol modules require a measurement variable (MEVA) or a key performance indicator (KPI) as their input. A raw datapoint will either be rejected during configuration validation or produce empty report rows at runtime. Define the MEVA in the Database node first, then bind the protocol module to that MEVA.

How do I confirm the kernel restart succeeded?

Open the Kernel Service Cockpit and verify the status is "running" with the expected uptime. In the Logging Viewer System tab, look for the message "Kernel ready, accepting requests". Then load a representative MEVA trend and confirm new values arrive.

What is the difference between Kernel go and Kernel reload?

Kernel go starts the kernel if it is stopped and restarts it if it is already running, making it the safe default for post-configuration cycles. Kernel reload forces a reload of specific runtime data structures without a full process recycle and is used in narrower scenarios; consult the B.Data service manual before adopting it as a default.

How do external tools read B.Data archive values?

External consumers read B.Data and WinCC Runtime archives through the WinCC OLE DB Provider. For Runtime Professional projects, the configuration and SQL syntax are documented under Access to archive data via WinCC OLE DB Provider (RT Professional). Always query after the kernel restart has completed.

Back to blog