Offline: Data Deletion
Steps to erase all site data from the training machine after deployment is verified and before leaving. There is no dedicated deletion script, so follow this checklist.
Principles
After the site model is deployed and verified, erase all site data from the training machine, confirm it is gone, and record it.
| Principle | Description |
|---|---|
| Before leaving | Delete on the spot when done; never carry data back to delete later. |
| After verifying deployment | Do not delete before confirming on the device that the new model is applied. |
| Verify deletion | Do not stop at running delete commands; confirm nothing remains. |
| Models are deleted too | Trained models on the training machine are also erased. If you need to take one out, agree with the AI team first. |
Where Data Remains
Where site data is stored and how to erase it.
| Location | Contents | How to delete |
|---|---|---|
| Studio data | Uploaded videos, labels, datasets, training results, request history | Step 3 bash stop.sh --clean |
| Registered device info | Device IP and SSH account (including password) | Step 1 delete in [Device Management]; also removed in step 3 |
| Training scratch data | Datasets and intermediate results copied during training | Step 2 empty /data/argo |
| Training job records | Finished training jobs and pods | Step 2 delete workflows |
| Settings file | .env.backend (contains secrets) | Step 4 cleanup (follow AI team guidance) |
| Temporary files on the device | Temporary files created on the device during the build | Step 5 check and delete |
| Import media | Videos brought in via USB, etc. | Format/delete on site |
Step 1. Delete the Device
The SSH password is stored there, so delete it first.
- Open [AI Update] > [Device Management].
- Click the trash icon of each device and then [Delete]."Device deleted" means success. On failure retry; if it still fails, step 3 covers it.
- When the list is empty click [Close].
Step 2. Delete Training Jobs and Scratch Data
stop.sh does not touch these, so delete them yourself. Run with sudo on the training machine.
- Check the current state and size.
sudo k3s kubectl get workflows,pods -n argo-workflowsudo du -sh /data/argo/* - Delete all training jobs (workflows).
sudo k3s kubectl delete workflows --all -n argo-workflow - Check the remaining pods.Run
sudo k3s kubectl get pods -n argo-workflowand confirm only Argo's own pods remain. If a training pod isTerminating, wait until it is gone. - Empty the contents of the three folders in
/data/argo.sudo find /data/argo/vunex-dataset /data/argo/gpu-comm /data/argo/trt-cache -mindepth 1 -delete - Check the result.Run
sudo du -sh /data/argo/*and confirm each folder is nearly empty.
-mindepth 1 does that. Never rm -rf /data or /data/argo itself.Step 3. Delete Studio Data
Erase all data stored in Studio and stop the services.
- Run it in the Studio folder.
cd vunex-studio-offline && bash stop.sh --clean - Read the warning and type
yes.Anything other thanyesends with "Cancelled." and nothing is deleted. - Confirm the "stopped" message.
Step 4. Settings and Temporary Files
Clean up the remaining traces.
| Target | How | Notes |
|---|---|---|
.env.backend | Delete or keep as the AI team instructs | Contains secrets, not data. It is recreated at the next visit. |
| Files you opened | Check downloads, desktop and temp folders | No videos or exported files should remain. |
| Shell history | history -c if needed | Clear it if a command with a password was typed. |
Step 5. Check Temporary Files on the Device
Engine build/deploy creates temporary files in the device's /tmp that are removed automatically on success. After a failure or interruption they may remain, so check them. Connect over SSH with the site owner present.
- SSH into the device and look for leftover temporary files.
ls -d /tmp/tmp.* 2>/dev/null; ls /tmp/vunex_* 2>/dev/null - Check what is inside any leftover folder.
ls -l /tmp/tmp.XXXXXXβ for this build it contains the trained model file. - Delete only when sure it belongs to this build.
rm -rf /tmp/tmp.XXXXXX(replaceXXXXXXwith the real name). Always check the name by eye.
Verify and Record
Do not stop at deleting; verify and keep a record.
| Target | How | Expected |
|---|---|---|
| Studio storage | docker volume ls | grep vunex-studio-offline | No data volumes listed |
| Training jobs | sudo k3s kubectl get workflows -n argo-workflow | No jobs |
| Scratch data | sudo du -sh /data/argo/* | Nearly 0 |
| Video/model files | `sudo find /home /data /tmp /mnt -xdev -newermt " | No output |
| (Optional) Empty-state check | Start with `bash start.sh | AI Update, Collected Videos, Datasets and Devices are all empty. Stop again with bash stop.sh |
| Record | Content |
|---|---|
| Site / date / owner | Site name, work date, owner |
| Deployed model | Model name and device model version before/after |
| Evaluation summary | Before/after mAP (without site information) |
| Deletion done | Time deleted and the verification results |