Dokploy/dokploy · error · TRPCError

NOT_FOUND

NOT_FOUND

Error message

Volume backup not found

What it means

Thrown by Dokploy's update-volume-backup mutation when updateVolumeBackup returns a falsy value, meaning no volume backup row matched input.volumeBackupId (or the update affected nothing). The id-based update returns the updated record only when the target exists.

Source

Thrown at apps/dokploy/server/api/routers/volume-backups.ts:210

				existingVb.postgresId ||
				existingVb.mysqlId ||
				existingVb.mariadbId ||
				existingVb.mongoId ||
				existingVb.redisId ||
				existingVb.libsqlId ||
				existingVb.composeId;
			if (serviceId) {
				await checkServicePermissionAndAccess(ctx, serviceId, {
					volumeBackup: ["update"],
				});
			}
			const updatedVolumeBackup = await updateVolumeBackup(
				input.volumeBackupId,
				input,
			);

			if (!updatedVolumeBackup) {
				throw new TRPCError({
					code: "NOT_FOUND",
					message: "Volume backup not found",
				});
			}

			if (IS_CLOUD) {
				if (updatedVolumeBackup.enabled) {
					await updateJob({
						cronSchedule: updatedVolumeBackup.cronExpression,
						volumeBackupId: updatedVolumeBackup.volumeBackupId,
						type: "volume-backup",
					});
				} else {
					await removeJob({
						cronSchedule: updatedVolumeBackup.cronExpression,
						volumeBackupId: updatedVolumeBackup.volumeBackupId,
						type: "volume-backup",
					});

View on GitHub (pinned to 546686ea35)

Solutions

  1. Refresh the volume backups list and edit the current entry
  2. Verify the volumeBackupId string being sent
  3. Treat NOT_FOUND on edit as a signal to re-fetch and re-open the editor

Example fix

// before
await trpc.volumeBackup.update.mutate({ volumeBackupId, ...input });

// after
const list = await trpc.volumeBackup.all.query();
const current = list.find((b) => b.volumeBackupId === volumeBackupId);
if (current) await trpc.volumeBackup.update.mutate({ volumeBackupId, ...input });
Defensive patterns

Strategy: try-catch

Validate before calling

const backups = await trpc.volumeBackup.all.query();
if (backups.some((b) => b.volumeBackupId === id)) {
  await trpc.volumeBackup.update.mutate({ volumeBackupId: id, ...input });
}

Try / catch

catch (e) { if (e?.data?.code === 'NOT_FOUND') { refetchAndReopenEditor(); } else throw e; }

Prevention

When it happens

Trigger: Calling updateVolumeBackup with an id that was deleted, never existed, or came from a different instance; also possible when the update payload matches nothing due to a corrupted id.

Common situations: Editing a backup schedule in a stale UI tab after it was deleted elsewhere; double submissions; ids copied across environments (staging vs production).

Understand the failure class

Background: 'Could not be found', 'does not exist', 'not found in database': the resource-not-found family when an ID, slug, key, or URI lookup comes back empty — this error's family across 20 libraries.

Related errors


AI-assisted analysis of Dokploy/dokploy@546686ea35 (2026-08-27). Data as JSON: /api/errors/0c41717d22d57a1d. Report an issue: GitHub.