IMD SolutionComputing LibraryShop main store

Troubleshooting

MQTT Engine blank settings page after a branch switch

Edge computing and IIoT Published 7 min read By IMD Solution engineering team

Short answer

After a branch switch, MQTT Engine's settings page goes blank because its com.cirruslink.mqtt.engine.gateway resource tree is incomplete: the generated default server sets and their companion files are missing. Stop the Gateway, delete that directory under the Gateway data config path, let MQTT Engine regenerate a clean default, then rebuild custom server sets through the webpage instead of copying the old folder back. Patching the securityContextHashingAlgorithm key by hand does not fix it.

On this page
  1. Why the page goes blank
  2. Rule out the Gateway web path first
  3. Read the file, the page and the runtime together
  4. What a module-generated tree contains
  5. Worked example: a Docker dev gateway on Ignition 8.3 with MQTT Engine 5.0.1
  6. Rebuild sequence
  7. Keep the next branch switch clean
  8. Questions asked

A blank MQTT Engine settings page after a git branch switch is a damaged com.cirruslink.mqtt.engine.gateway resource tree, not a broker, network or permissions fault. The page renders, so the Gateway web path did its job; what fails is MQTT Engine binding the saved resources to its configuration model. The same failed binding empties the checkboxes and entry fields, rejects saves with an error naming securityContextHashingAlgorithm, and leaves node and device commands blocked even where the file holds the blocking setting at false. The repair is to stop the Gateway, delete the directory under [IGNITION_HOME_DIR]/data/config/resources/core, let the module generate a clean default, confirm the page populates, and rebuild your custom server sets from that base — never by patching the one key.

Why the page goes blank #

The configuration request has four stages: the browser, the Gateway web service, the MQTT Engine module, and the module's saved resources under the Gateway data directory. A page that renders with empty controls has already cleared the first two stages. The request reached MQTT Engine, and the module could not bind the saved resource structure to its configuration model. Two more symptoms come from that same failed binding:

  • Saving any option fails with an error that names securityContextHashingAlgorithm.
  • Node and device commands stay blocked although the saved setting does not block them; the running module is not applying what is on disk.

That second symptom makes this an operational fault, not a cosmetic one: node and device commands are refused until the tree is rebuilt. The whole pattern, and the repair below, is recorded on MQTT Engine 5.0.1 running on an Ignition 8.3 gateway with the dev gateway in Docker; the versions matter because the module is the thing generating and consuming this tree.

Rule out the Gateway web path first #

Work through these checks before touching the module's files:

  1. Open another Gateway configuration page through the same address and port. Read a setting without changing it, then test one harmless save if your operating procedure allows. If those fail too, the fault is the Gateway or its container, not MQTT Engine.
  2. Record exactly how the MQTT Engine page fails: it does not load, it loads with blank controls, or it loads populated controls that reject the save. Only the second and third point at the resource tree.
  3. Capture the Gateway log entries written by that page request and the failed save, at the moment they occur. A save error that names securityContextHashingAlgorithm sends you to the general resource and the tree around it.

A populated page with a runtime complaint is a different class of fault. Tags that hold an online status after an edge node drops live on the runtime side and have their own diagnosis, covered in Why MQTT Engine shows online status after an edge node drops.

Read the file, the page and the runtime together #

Take three readings — the value in the resource file, what the page shows, and what a real node or device command does — and match them to a decision:

File Page Runtime Decision
Blocking set to false Controls blank Node and device commands blocked The tree is unreadable or internally inconsistent; regenerate it
Agrees with the page Populated Commands follow the setting The configuration path is healthy; chase the individual command only if one still fails
Old or default values Save rejected with the securityContextHashingAlgorithm error Old behavior continues Inspect the general resource and the whole generated tree, not the single key

The first row is the branch-switch fault: the text on disk is correct, and the module still cannot consume it.

What a module-generated tree contains #

A clean default written by the module carries, under namespace-server-set, both default server sets with their companion files:

./Sparkplug B-Default Set
./Sparkplug B-Default Set/config.json
./Sparkplug B-Default Set/resource.json
./Elecsys-Default Set
./Elecsys-Default Set/config.json
./Elecsys-Default Set/resource.json

If the tree in your repository lost those generated sets — the reported base config deleted them when its custom sets were built — then a branch switch or a file scan hands the module a structure it never generated, and that is the corruption you are seeing. Two traps to skip:

  • The absent securityContextHashingAlgorithm key in general/config.json is a symptom, not the test. A freshly generated default loads and saves with the key not visible; the key appears only after the setting is moved away from none. Adding it by hand and scanning did not clear the fault in the reported case.
  • A set folder without its config.json or resource.json is an incomplete resource even when the folder name looks right.

The decisive test is whether a module-generated default tree loads and saves. When the clean default works and your restored tree does not, the restored tree is the problem — full stop.

Worked example: a Docker dev gateway on Ignition 8.3 with MQTT Engine 5.0.1 #

Inputs, each with its origin:

  • Platform: MQTT Engine 5.0.1 on an Ignition 8.3 gateway, the dev gateway run in Docker — the reported case.
  • State after a branch switch that touches no MQTT file: controls blank, save error naming securityContextHashingAlgorithm, node and device commands blocked while the file holds blocking at false — the reported case.
  • Reference contents under namespace-server-set: 2 generated sets, each with 2 companion files — the module-generated default.
  • Base config history: both generated sets were deleted when the custom sets were created, so the tree held in source control contains 0 of them — the reported case.

The rule, in words: a set folder counts only when it exists together with both companion files. Compare your tree against the module-generated default by counting complete pairs, and rebuild anything that falls below the default instead of patching it.

Arithmetic:

  • Expected companion files: 2 sets × 2 files per set = 4 files
  • Complete pairs in the affected tree: 0 sets × 2 files per set = 0 files
  • Shortfall: 4 − 0 = 4 companion files, across 2 missing set folders

Result: the tree sits below the reference, so delete-and-regenerate is the repair that applies. After regeneration the default came back complete and the page populated; the custom sets were then rebuilt through the page and survived later file scans.

Decision: fewer than 4 companion files across the 2 default set folders — or any set folder missing half of its pair — means stop the Gateway, delete, and regenerate. Editing the single key by hand is never the repair.

Rebuild sequence #

Run this from the broken state:

  1. Copy the whole com.cirruslink.mqtt.engine.gateway directory to somewhere outside the active config path, so your custom values stay available for comparison.
  2. Stop the Gateway and confirm the process is gone — on the Docker dev gateway, docker compose down. On a production gateway, schedule the stop: collection is down for the duration and MQTT Engine subscribes to nothing while the tree regenerates.
  3. Delete [IGNITION_HOME_DIR]/data/config/resources/core/com.cirruslink.mqtt.engine.gateway.
  4. Start the Gateway — docker compose up on the Docker host — and let the module write a fresh default tree.
  5. Check namespace-server-set: both default sets present, each with both companion files.
  6. Open the MQTT Engine page and confirm every control is populated before you change anything.
  7. Recreate your custom server sets through the working webpage. Where files must come back from the saved copy, restore them in controlled groups and leave the generated companions in place.
  8. Run a file scan, reload the page, and read the Gateway log for new errors.
  9. Prove the path end to end: change one harmless setting, save, run a file scan, confirm the value persists; then send one test node command and confirm blocking follows the setting.

Overwriting the regenerated folder with the old copy also brought the page back in the reported case, but only intermittently. Rebuilding from the clean generated base is the repeatable version, which is why the steps above never paste the old folder over the new one wholesale.

Keep the next branch switch clean #

  • Version the directory as one complete unit — every set folder with both companion files — or keep it out of source control entirely and rebuild settings through the webpage after each checkout. A half-tracked tree is what breaks.
  • Never delete the generated default sets to tidy the repository. Leave them and add your custom sets alongside.
  • After every branch switch: run a file scan, open the MQTT Engine page, confirm the controls are populated, and send one test node command before you trust the running config.
  • With the page working again, a custom namespace that still creates no tags is a separate fault with its own fix: Why MQTT Engine custom namespaces create no tags.

Questions asked

Does the blank page mean the MQTT broker connection is down?

No. The page rendering proves the Gateway web path carried the request; the failure sits between MQTT Engine and its saved resources, and no broker setting is involved. A broker problem looks different: the config page stays populated and the symptom is missing or stale tag data, not empty checkboxes or a rejected save.

Why did copying the old folder back sometimes take several attempts?

A whole-folder overwrite replaces everything the module just generated. Unless the saved copy already holds each set folder complete, with both its config.json and resource.json, the overwrite recreates a partial tree and the fault returns. Restoring files in controlled groups around the generated sets is what makes the repair succeed in one pass.

Will regenerating the folder delete my custom server sets?

Yes, the folder holds them, so copy it outside the active config path before deleting anything. Then rebuild the sets through the working webpage, which writes each companion file itself, rather than re-importing hand-edited files that may be missing half of a pair.

Is a clean git diff proof the MQTT tree is intact?

No. Generated resource files and default sets can sit outside the diff you review, so a checkout can hand the module a structure that differs from what you approved even when no setting changed. After any switch, open the page and run a file scan, and trust the populated controls, not the diff.

Keep reading

  • Troubleshooting

    Why MQTT Engine shows online status after an edge node drops

    An Info/Online tag that stays true with Good quality is not proof the edge node is alive: Engine's online state comes from the node's Sparkplug death certificate, and earlier Engine versions marked tags stale only on Engine shutdown. Read Info/Online, tag quality and Store & Forward stored metrics as three separate indicators, retest on Engine 4.0.8 with Ignition 8.0.16 or later, and compare against a node that reports correctly before escalating.

    Edge computing and IIoT

  • Troubleshooting

    Why MQTT Engine writes fail with Bad_NodeIdUnknown

    Bad_NodeIdUnknown on an MQTT Engine tag write is an OPC UA namespace lookup failure at the server executing the write — the node id is not in its address space. It is not a VPN fault: with good edge tags and a live Engine tag, fix the write target's node path, not the transport.

    Edge computing and IIoT

  • Troubleshooting

    Why Node-RED HTTP requests throw AggregateError after an update

    An AggregateError from the HTTP request node wraps the runtime's failed connection attempts; it is not a diagnosis. A passing ping clears ICMP, not outbound TCP 443 or TLS. Log the nested error object, test DNS, TCP 443 and certificate trust in order from the device, and while the hop stays broken, relay the messages over MQTT to a second Node-RED host that completes the request.

    Edge computing and IIoT

Why a renamed InfluxDB field writes after a field type conflict