SQLITE_NOLFS
SQLiteERRORNotableFilesystemofficial confidence

Large file support is disabled

Production Risk

High — writes will fail on affected platform until resolved.

What this means

SQLITE_NOLFS (22) is returned on systems that do not support large files (> 2 GB) when SQLite tries to write beyond the 2 GB limit. Rare on modern 64-bit systems.

Why it happens
  1. 1SQLite compiled without large file support on a 32-bit system.
  2. 2Filesystem does not support files larger than 2 GB (FAT32, some older NFS).
  3. 3Database file growing beyond 2 GB on an unsupported platform.
How to reproduce

Write operations on databases exceeding 2 GB on constrained systems.

trigger — this will error
trigger — this will error
# On a 32-bit system or FAT32 filesystem:
# INSERT that pushes the database past 2 GB returns SQLITE_NOLFS

expected output

sqlite3.OperationalError: large file support is disabled

Fix 1

Fix 2

Fix 3

Sources
Official documentation ↗

sqlite3.h — SQLITE_NOLFS = 22

Content generated with AI assistance and reviewed for accuracy. Found an error? hello@errcodes.dev

← All SQLite errors