How to fix Error 3004 on Windows Server 2025 / Windows 11

Why This Error Happens

This error occurs because SQL Server 2025 does not log file-level or filegroup-level operations when a database is set to the SIMPLE recovery model, which makes file backups unreliable for recovery purposes. File backups require the transaction log chain to restore data consistently, but SIMPLE recovery truncates the log automatically, breaking that chain. As a result, SQL Server blocks standard file/filegroup backups and instead requires either a full database backup or a partial backup using READWRITEFILEGROUPS.

Step-by-Step Resolution Guide

Step 1: Verify the Current Recovery Model

  • Open SQL Server Management Studio (SSMS) and connect to your Windows Server 2025 instance.
  • Run the following query to check the database recovery model:
  SELECT name, recovery_model_desc FROM sys.databases WHERE name = 'YourDatabaseName';
  • Confirm the result shows SIMPLE.

Step 2: Choose a Backup Strategy Based on Business Needs

  • If point-in-time recovery is required, switch the database to FULL recovery model:
  ALTER DATABASE YourDatabaseName SET RECOVERY FULL;
  • If SIMPLE recovery is intentional (e.g., for non-critical dev/test databases), skip to Step 3 and use a partial backup instead.

Step 3: Perform a Partial Backup Using READWRITEFILEGROUPS

  • If staying on SIMPLE recovery, run a partial backup instead of a file backup:
  BACKUP DATABASE YourDatabaseName
  READ_WRITE_FILEGROUPS
  TO DISK = 'C:\SQLBackups\YourDatabaseName_Partial.bak';
  • Ensure the backup destination folder exists and the SQL Server service account has write permissions on C:\SQLBackups\.

Step 4: Re-Enable Transaction Log Backups (If Switching to FULL)

  • After switching recovery models, take an immediate full database backup to restart the log chain:
  BACKUP DATABASE YourDatabaseName
  TO DISK = 'C:\SQLBackups\YourDatabaseName_Full.bak';
  • Schedule regular transaction log backups via SQL Server Agent to prevent log file growth issues.

Step 5: Validate SQL Server Agent Job Permissions

  • Open SQL Server Agent in SSMS and check that the backup job’s proxy account has access to the target backup directory.
  • Confirm the Windows Server 2025 firewall or antivirus isn’t blocking access to the backup share or local disk path.

Alternative or Verification Steps

  • Run RESTORE VERIFYONLY FROM DISK = 'C:\SQLBackups\YourDatabaseName_Partial.bak'; to confirm the backup file is valid and restorable.
  • If partial backups are not sufficient for your recovery objectives, consider migrating critical databases to the FULL recovery model permanently and implementing a maintenance plan with regular log backups.