How-to
Store InfluxDB data on an SD card in ctrlX CORE
Short answer
The InfluxDB App on a ctrlX CORE writes wherever its active configuration points its data storage location, not where Node-RED sends records. Format the SD card as EXT4 in the Storage window, mount it, repoint the persistent data path in config.yaml, upload and activate the configuration, reboot, and confirm with a known tag that writes land on the card and survive a restart.

On this page
Yes — the InfluxDB App stores its files wherever its active configuration points, and an SD card mounted as a memory extension is a supported destination. The trap in this fault is that everything keeps looking healthy: Node-RED delivers records, dashboards fill, and the database quietly keeps filling onboard storage. Changing the acquisition flow does not move the database. Format the card as EXT4, mount it, name the mount as the data storage location in the app configuration, upload and activate it, reboot, and then prove with a known tag that writes land on the card and survive a restart.
What decides where the data lands #
The storage chain is: card inserted, formatted as EXT4, mounted at a path, the InfluxDB App's data storage location pointing at that path, configuration activated, device rebooted. A break anywhere in the chain leaves the database on onboard storage, and two changes that feel like fixes are not:
- Changing the Node-RED write target selects which database receives records. It never relocates files managed by the database that is already running.
- Inserting the card and rebooting only makes the medium visible. An unmounted directory that shares a name with your intended mount still lives on onboard storage, and the running service happily keeps filling it.
Redirection is a designed feature, not a workaround: the Influx Database Connection manual for the app lists a USB flash drive or SD card mounted as a memory extension as the supported way to move data off the internal medium. The related article Why InfluxDB on ctrlX OS only offers external storage explains how the app scopes that choice.
Format and mount the card #
Work in the ctrlX CORE web interface. Formatting destroys everything on the selected medium, and a medium that is already mounted cannot be formatted, so pull any files you need off the card first and format before you mount.
- Save the active app configuration and note the current data location. Keep the old data directory intact until the new location passes the restart check in the verification section.
- Insert the SD card and open the Storage window in the web interface. The card appears as a removable medium; confirm you are looking at the card and not the internal medium before any destructive step.
- Format the card as EXT4. ctrlX accepts FAT32 as well, but EXT4 is the filesystem to use for a directory a database writes into continuously.
- Mount the formatted card in the same storage area and note the exact mount path. That path is what the app configuration will name, so copy it precisely.
- Open the Partition manager window to see the mounted medium and its partitions, and confirm the mount path resolves to the card before anything points at it.
Point the InfluxDB App at the card #
Pause acquisition first. A live database holds its files open, and a copy taken while the service writes can mix timestamps from different moments; a paused flow gives you a clean cut-over. If the flow feeds anything else, check how it behaves when the database is unreachable instead of assuming it buffers.
- Stop or pause the Node-RED acquisition flow.
- Edit the app configuration. The version 4 Influx Database Connection manual names config.yaml as the place where the data storage location is configured: point the persistent data path at the card's mount path from the previous section. On earlier app revisions the same change goes through the app's configuration upload workflow — follow the manual for your installed version, and do not copy a path from another installation.
- Upload the configuration and activate it. An uploaded configuration that was never activated changes nothing for the running service; this is the step most often skipped.
- Reboot the ctrlX CORE so the app reopens its files on the card instead of holding the onboard directory.
- After the reboot, confirm in the Storage window that the card is mounted again and that the app started without path or permission errors.
Prove the writes survive a restart #
A successful query proves the service runs; it does not prove where the files are. Check both.
- While acquisition is still paused, write one recognizable test point through your normal write path — for example a tag named
storage_checkwith value 1 and the current timestamp. - Reboot the ctrlX CORE.
- Query the test point. The value and timestamp must come back.
- Watch the card's used space in the Storage window while a short acquisition test runs. Growth on the card is the physical proof the writes land there.
- Compare history. If the points you had onboard are no longer visible, the app opened a fresh, empty database at the new path and the old files are still in the previous directory — the failure behind why an InfluxDB container loses old data after restart. Resume production only after you have decided what happens to that old directory.
Two more failure patterns are worth knowing before you close the job. A worn or marginal card rarely fails inside one app; the article on Docker OCI runtime create failed on SD card storage describes the same root case from the container side. And if the web UI or the Node-RED editor misbehaves after this particular reboot, that fault is separate from your storage change — the page on troubleshooting a ctrlX Node-RED 404 after a core reboot walks through it.
Sizing the card for 100 tags at 1 s on a 32 GB card #
Inputs for a typical compact acquisition, each declared before any arithmetic:
- Write rate: 100 tags with one point each per second, so 100 points/s. This is an example rate for a compact machine line; read your own from the flow.
- Size per point: 200 B, a planning figure for a short line with two tags and one numeric field. It is an assumption for the arithmetic, not a documented InfluxDB constant; measure your own from a day of growth if the number matters.
- Card: 32 GB, labeled in decimal gigabytes like every SD card.
- Headroom: keep 20 percent of the card free as a planning margin for compaction work and day-to-day overhead.
The rule in words: days to full equals usable space divided by the bytes stored each day, and the bytes stored each day equal points per second times 86,400 s/day times bytes per point.
The arithmetic, written out:
- 100 points/s × 86,400 s/day = 8,640,000 points/day
- 8,640,000 points/day × 200 B = 1,728,000,000 B/day ≈ 1.73 GB/day
- usable space: 32 GB × 0.8 = 25.6 GB
- 25.6 GB ÷ 1.73 GB/day ≈ 14.8 days
Result: roughly two weeks before this card fills.
Decision: if the retention window you must keep is longer than your days-to-full figure, the card is too small at this rate — cut the write rate with a deadband or batched writes, shorten retention, or move history to larger storage. If the window is shorter, set a retention policy at or below that figure and keep the 20 percent margin. At 8.64 million records a day, fit a card rated for continuous application writes; a consumer photo card is the wrong class of hardware for this duty.
Questions asked
Does redirecting InfluxDB to the card keep the existing history?
No. Pointing the data storage location at the card starts a fresh database at that path; the existing points stay in the old directory on onboard storage. To carry history across, use the backup and restore workflow documented for your installed InfluxDB version while acquisition is paused, restore into the card-backed database, and confirm a known tag and timestamp before resuming. Keep the original directory until that check passes.
Is FAT32 acceptable instead of EXT4 for the card?
ctrlX accepts FAT32 and EXT4 formatted media, but they are not interchangeable for this job. InfluxDB creates and updates many files continuously and relies on Unix file permissions, which FAT32 does not carry, so a database mount belongs on EXT4. Use FAT32 for media that only shuttle files between machines.
What happens once the card fills up?
Without a retention policy the database grows until the filesystem is full, and writes then fail, so data stops landing even though Node-RED keeps running. Size a retention policy below the days-to-full figure from the sizing example, keep at least 20 percent of the card free, and watch free space in the Storage window after the change.
Is an SD card dependable enough for continuous history?
For 24/7 writes it is the weakest link in the chain: flash wears under continuous rewrites, and a card that drops its mount can stop a runtime from starting at all. Use a card rated for continuous application writes, keep a database backup off the card, and re-check after every maintenance reboot that the mount came back before trusting the history.


