IMD SolutionComputing LibraryShop main store

Troubleshooting

Stale historian tag browse tree entries after a restore

Edge computing and IIoT Published 5 min read

Short answer

A historical tag browse tree lists the identities the edge historian has stored samples under, and a gateway restore replaces live tag configuration without touching that store. On a disposable development machine, stop the gateway, move the local .idb file out with a copy kept, and restart to clear them; Root Node Path trims the visible hierarchy without deleting data.

On this page
  1. Why a gateway restore cannot remove them
  2. Reset the local historian file on a disposable machine
  3. What the reset throws away
  4. Trim the tree without deleting anything
  5. The decision for each case
  6. Questions asked

The stale folders are not live tags that failed to delete. A historical tag browse tree lists every tag path the edge historian has ever stored samples under, and a gateway restore imports tag configuration without touching that store, so paths from the previous project stay browsable indefinitely. On a machine where the stored history is disposable — this came up on an Ignition Edge 7.9.13 development install on Windows 10 — the fix is a full history reset: stop the gateway service, move the local historian file out of the data folder with a copy kept, and restart. The historian rebuilds an empty store and the stale identities disappear. If the only problem is the two provider rows eating screen space, set the component's Root Node Path instead; that trims what is displayed and deletes nothing.

Why a gateway restore cannot remove them #

Two stores are involved, with different lifecycles. The live tag database holds what the project defines right now, and a gateway restore overwrites it from the backup. The historian keeps its own store — in this Edge install, a single SQLite file with the .idb extension inside the installation's data folder — and a restore never opens, edits or empties it. An identity is created the first time a sample is written under a path and survives even after the live tag is deleted, so the tree can offer paths the current project has never used.

What you are seeing, and what each item actually is:

  • Folders from the previous project: historical identities recorded while that project ran. The restore never touched them.
  • Entries that look like live tags with " 1" appended: two stored identities, created when a provider rename or re-import shifted the full path. The historian keeps both.
  • The Edge Historian and edge rows at the top: the component's browse root, not stale data — the Root Node Path setting below controls those.

The deciding check takes a minute: open the live tag browser next to the tree. An entry with no live counterpart but stored history is a stale identity, not a tag someone forgot to delete.

Reset the local historian file on a disposable machine #

This is a whole-historian reset: it deletes the stale identities and every stored sample with them, so never run it on a historian whose records feed quality, environmental or compliance reporting. Where the history is disposable, the procedure is:

  1. Confirm nothing in the store is needed. Export or record any range someone may still ask for; on this development machine, nothing was.
  2. Take two backups: a gateway backup and a file copy of the historian store.
  3. Stop the gateway service, from the Windows Services control or the gateway's own stop control. Moving a SQLite file while its owning process is writing leaves the copy inconsistent.
  4. Move — do not delete — C:\Program Files\Inductive Automation\Ignition\data\edge_data\edge_historian.idb to a folder outside data. That exact path belongs to the 7.9.13 Edge install; other versions and other historian modules keep their files in their own subfolders under the same data directory, so verify the location in your installation before moving anything.
  5. Restart the service. The historian recreates an empty store; check the gateway diagnostics for the historian connection and confirm the live tags start recording.
  6. Reopen the trending screen and set the tree beside the live tag inventory. Only current paths should remain.

Charts whose time range lies before the reset draw empty from now on. That is the reset working, not a broken binding: test a range that includes newly recorded samples before diagnosing anything. If a trend stays empty even over ranges that should hold fresh samples, work through the PLC tag collection troubleshooting for an empty historian trend instead.

What the reset throws away #

Size the loss before you move the file. The rows discarded are tags × sample rate × days stored, and the sample rate that matters is how often samples were actually written, not how many folders the tree shows. Illustrative numbers, not a measurement: 14 logged tags at one sample per second accumulate 14 × 86,400 = 1,209,600 rows per day, so after five working days the reset discards 5 × 1,209,600 = 6,048,000 rows. At one sample per minute the same tags total at most 14 × 1,440 = 20,160 rows per day, 100,800 over five days. Either way, the empty pre-reset trend ranges are that arithmetic made visible.

Trim the tree without deleting anything #

If the complaint is screen space rather than stale data, the Tag Browse Tree's Root Node Path property sets which subtree is displayed and changes nothing in the historian. On this screen, turning off Show Root Node alone did not help; the historian and provider rows under the root stayed. Setting Root Node Path to [Edge Historian/edge] started the tree below those two rows and left the application folders intact.

Take the historical path from the component, not from the live tag browser: the two are different namespaces, and a live tag path will not resolve as a historical root. Run the screen in preview mode, select a tag inside the folder you want at the top, then read the selected paths dataset in the Tag Browse Tree properties and put that exact path into Root Node Path.

This is presentation only. The stale identities stay in the file and reappear if the property is cleared; only the reset above removes them.

The decision for each case #

  • Disposable development or test machine: run the reset — stop the service, move the .idb with a copy kept, restart. The stale entries clear, the stored history goes with them, and empty pre-reset trend ranges confirm the store is new.
  • Machine whose records must survive: leave the file alone. Trim the display with Root Node Path and let the identities sit; reclaiming them is selective maintenance against a verified backup, the same pattern as deleting future-dated alarm archive entries through SQL on a store that stays live.
  • Discarded ranges that turn out to matter on a plant system: recover them by backfilling trend history from the plant historian rather than trying to re-log what the edge machine lost.

Questions asked

Why do the stale entries look like live tags with " 1" added to the name?

Each historical identity is tied to the full tag path that existed when samples were recorded. If a tag provider or folder was renamed, or the tags were re-imported under a slightly different path, the historian keeps both identities, so the old one shows up next to the new one with a numbered suffix. Compare the two full paths and check whether both exist as live tags before assuming either is junk.

Will moving the historian file break the gateway?

On this 7.9.13 Edge install it did not: the gateway rebuilt an empty store on restart and the installation kept operating. Move the file rather than deleting the only copy, stop the service first so the database is not mid-write, and confirm in the gateway diagnostics that the historian connection comes back and the active tags start recording again.

Can I show cleaner names in the tree without renaming production tags?

Yes. Create history-enabled copies of the tags in one folder used only for selection, give the copies operator-friendly names, and set the tree's root path to that folder. Keep history enabled on the originals if an alarm status table or another consumer reads it; turning it off there to avoid storing every sample twice is only safe when nothing else depends on it.

Does the same file reset apply to a full historian on a plant server?

No, and it should not. This procedure describes an edge internal historian, which keeps its data in a single local SQLite file with the .idb extension under the installation's data folder. Full historian modules keep their files in their own subfolders under the same data directory, and on a production server that store is managed through retention and maintenance procedures, not by moving files by hand.

Keep reading

  • Troubleshooting

    Edge trend shows no historian data: fix the doubled SELECT

    The trend stays blank because a complete SELECT statement was pasted into the Table field, so the gateway wraps it in its own SELECT ... FROM and SQL Server rejects the result as incorrect syntax near the keyword select. Put only Runtime.dbo.History in Table, carry DateTime, TagName and Value in the column controls, and move TagName = 'SysTimeSec' into the filter control.

    Edge computing and IIoT

  • Troubleshooting

    Historian reads slow in Excel after adding tags

    Run one timed test before touching anything: read one old tag and one newly added tag over the same range in the historian's built-in client, then in the Excel macro. Fast in the client but slow in Excel means the macro's request pattern is the fault; the new tag slow in both means you run the historian's validate action and then confirm the SQL maintenance plan actually targets the historian database.

    Edge computing and IIoT

  • Troubleshooting

    Historian trend empty: PLC tag collection troubleshooting

    A live PLC value proves nothing about what the historian stored. Work one known, changing tag through four boundaries — controller to data server, server to collector, collector to point, point to chart — and with a 2 s update rate, a 1% deadband on a 200 in span and a 24 in/h fill, a 20 min window must show about 4 stored events. Zero events means the collector; four events with a flat chart means the display.

    Edge computing and IIoT