Backup Job Failure - ERR=ERROR: index row size exceeds maximum 2712 for index "path_name_idx

Backup Job Failure - ERR=ERROR: index row size exceeds maximum 2712 for index "path_name_idx

Hello,

if you receive a backup error similar to the below

Fatal error: sql_create.c:831 Fill Path table Query failed: INSERT INTO Path (Path) SELECT a.Path FROM (SELECT DISTINCT Path FROM batch) AS a WHERE NOT EXISTS (SELECT Path FROM Path WHERE Path = a.Path) : ERR=ERROR: index row size XXXX exceeds maximum 2712 for index "path_name_idx"
HINT: Values larger than 1/3 of a buffer page cannot be indexed.
Consider a function index of an MD5 hash of the value, or use full text indexing.

this is a native limitation in SQL (which is the backend we use to store backup job details (such as filename)

if you see this error, there is likely a script related issue or other significant issue on the server causing this event

one such "normal" report case is "Google's mod_pagespeed". If google mod_pagespeed is creating cache files this large (which is not normal), it is safe to remove those files and restart the backup

although normally, it does not create file names this long, we have seen a reported incident of this

resolution - delete such files, and or resolve the script issue generating such files and restart your backup