Troubleshooting Windows: Random Failure to Create Swap File on Alternative Drive (J:) Location

Abstract: Resolve Windows failure to create an 18GB swap file on the J: drive by fixing permissions and configuring static virtual memory settings.

Created: 2026-09-23 by
Windows fails to create a swap file on the J: drive due to permission conflicts, incorrect system path configuration, or storage service interruptions. This issue often stems from the operating system being unable to write the large 18GB paging file to the secondary volume during boot. Resolving this requires verifying drive health, resetting permissions, and manually configuring the page file settings through advanced system properties.

Understanding the Page File Mechanism

The Windows page file, also known as the virtual memory file, acts as an extension of your physical RAM. When the system runs low on available memory, it moves inactive pages of data from the RAM to the hard drive. By default, Windows places this file on the primary C: drive. However, many users prefer moving it to a secondary drive, such as a fast NVMe SSD labeled J:, to improve performance or preserve space on the main system partition. Creating a static, manually sized page file can prevent fragmentation and ensure consistent performance. An 18GB size is substantial and requires significant contiguous free space on the target drive. If Windows cannot allocate this space securely during startup, the operation fails silently or logs an error in the Event Viewer. This failure disrupts memory management, potentially leading to application crashes or system instability if the fallback mechanism does not engage correctly.

Verifying Drive Health and Permissions

Before adjusting system settings, you must ensure that the J: drive is fully functional and accessible to the System account. A failing drive or corrupted file system will reject write operations for critical system files. Open the Command Prompt as an administrator and run chkdsk J: /f to check for errors. If the drive is healthy, proceed to verify permissions. Navigate to the root of the J: drive in File Explorer. Right-click the drive icon and select Properties. Go to the Security tab and click Advanced. Ensure that the SYSTEM account has Full Control permissions. If the SYSTEM account is missing or lacks these rights, Windows cannot write the pagefile.sys to the location. Correcting these permissions is a common fix for random creation failures. Additionally, ensure that no third-party antivirus software is blocking write access to the root directory of the J: drive, as some security suites restrict system-level modifications.

Configuring Virtual Memory Settings

Incorrect configuration steps often lead to persistent failures. To set up the page file correctly, press Win + R, type sysdm.cpl, and press Enter. In the System Properties window, navigate to the Advanced tab and click Settings under Performance. Switch to the Advanced tab again and click Change under Virtual Memory. Uncheck "Automatically manage paging file size for all drives" to gain manual control. Select the J: drive from the list. Choose Custom size and enter 18000 MB for both the Initial size and Maximum size. Using identical values ensures the file remains static, avoiding fragmentation. Click Set, then OK. You will receive a warning that changes require a restart. Click OK to dismiss the warning and restart your computer. If the setting reverts or fails to apply, it may indicate a conflict with existing registry policies. In such cases, deleting any existing page file entries on other drives before applying the new setting can help. Some users find success by first removing the page file from the C: drive entirely, restarting, and then assigning the full configuration to the J: drive. This forces Windows to recognize the new allocation without conflicting with legacy settings. For related issues regarding system resource management, see Troubleshooting High CPU, Memory, and Power Usage in Open Task Manager. Monitoring memory usage after the change helps confirm that the system is utilizing the virtual memory correctly.

Checking Storage Services and Drivers

Sometimes the failure is not due to configuration but rather background services. The StorSvc (Storage Service) manages disk configurations and page file creation. Open Services (services.msc) and locate the StorSvc service. Ensure its status is Running and Startup Type is Automatic. If it is stopped, start it and attempt to create the page file again. Outdated storage drivers can also cause initialization failures. Open Device Manager and expand Disk Drives. Right-click your J: drive controller and select Update Driver. If updates are unavailable, consider visiting the motherboard or drive manufacturer’s website for the latest chipset and storage drivers. Corrupted drivers may prevent the OS from communicating properly with the hardware during the early boot phase when the page file is created. Additionally, check the Event Viewer for specific error codes. Press Win + X and select Event Viewer. Navigate to Windows Logs > System. Look for errors tagged with Source PnP or StorSvc around the time of boot. These logs provide precise details on why the allocation failed, such as insufficient contiguous space or I/O errors.

Alternative Troubleshooting Steps

If standard methods fail, consider creating a new user profile. Corrupted user registry hives can sometimes interfere with system-wide settings. Create a new local administrator account, log in, and attempt to configure the page file there. If it works, the issue lies within your original user profile's registry keys. Another approach involves using the Registry Editor. Press Win + R, type regedit, and navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management. Check the value of PagingFiles. It should read something like J:\pagefile.sys 18000 18000. If it contains invalid paths or syntax, correct it manually. Be cautious when editing the registry, as incorrect changes can cause boot failures. Always export the key before making modifications. For users experiencing broader system instability, such as random shutdowns, review PC Randomly Shuts Down with a Kernel Power (ID 41) Critical Error - Troubleshooting Guide to rule out hardware faults that might mimic software configuration errors.

Frequently Asked Questions

Why does my page file keep reverting to C: drive?

This usually happens because the configuration was not applied correctly or a system policy overrides manual settings. Ensure you clicked the Set button after entering the custom size and restarted the machine. If it reverts, check for group policies or third-party optimization tools that reset virtual memory settings on reboot.

Can I use a USB drive as a page file location?

While technically possible, it is highly discouraged. USB drives have slower write speeds and higher latency than internal SSDs or HDDs. Using a USB drive as a page file can significantly degrade system performance and increase wear on the USB controller. Internal drives are always preferred for virtual memory.

How do I know if the page file is working on J: drive?

Open Task Manager and go to the Performance tab. Select Memory and look at the Commit section. The Committed value should reflect the total physical RAM plus the size of the page file on J:. If the commit limit matches your RAM plus 18GB, the page file is active and functioning correctly.

What causes the 'Access Denied' error when creating a page file?

This error indicates that the SYSTEM account lacks the necessary permissions to write to the root directory of the J: drive. Verify the Security tab in the drive properties to ensure SYSTEM has Full Control. Also, ensure no other process or antivirus software is locking the file or directory during the creation attempt.

Should I disable the page file on the C: drive?

Disabling the page file on the C: drive is generally safe if you have moved it entirely to another drive, but it carries risks. Some applications expect a page file to exist on the system drive and may crash if it is missing. It is safer to keep a small page file on C: while using a large one on J:, or ensure all applications are compatible with the change.

Latest News

How to Display Output of xterm Command in Terminal Screen using Cron

Resolve the inability to display xterm output in a terminal screen from cron by redirecting logs or using wall instead of insecure X11 workarounds.

Read More
Expose Local Server on VPS Preserving Real Client IPs (OS Level)

Resolve VPS logging showing only gateway IPs by configuring reverse proxies to forward real client addresses via X-Forwarded-For headers.

Read More
How to Clear Recent Files History in Linux without Deleting Actual Files?

Clear recent files history in Linux by deleting ~/.local/share/recently-used.xbel without removing the actual files.

Read More
Best HDD Copy Strategy: Manually Syncing and Rewriting Scratch

Resolve data drift between two 4TB hard drives by using rsync with the --delete flag to manually sync and rewrite scratch data for an exact mirror.

Read More
Understanding Bash Prompt Abbreviations: An Overview

Resolve repetitive typing errors by creating and persisting Bash aliases in the .bashrc file for improved command-line efficiency.

Read More
Free Tools and Methods to Log Real-Time Performance Details in Task Manager

Log real-time CPU and memory metrics to CSV files using Windows Performance Monitor Data Collector Sets to troubleshoot system slowness.

Read More
Contact Qatar Airways Customer Service: Phone Number, Help Center, and More

Resolve urgent Qatar Airways reservation issues like flight changes and baggage claims using the US phone number +1801-855-5905 or online self-service tools.

Read More
Windows 11: Alt Codes Displaying Wrong Characters - Solutions

Resolve Windows 11 Alt codes showing wrong characters by verifying the US keyboard layout and enabling Num Lock.

Read More
Run Programs with Elevated Privileges: A Comprehensive Guide

Eliminates the need to type sudo for frequent administrative tasks by configuring .bashrc aliases or functions.

Read More
Dynamically Changing Dates in Excel Formulas Using Cells

Eliminate manual date updates in Excel by using cell references to create dynamic formulas that automatically adjust calculations when input dates change.

Read More
Granting Edit Access to a Specific Excel Sheet in an Office 365 User Email ID-Based Login

Excel Online lacks native sheet-level permissions, so users must split workbooks or use worksheet protection to isolate edit access for specific tabs.

Read More
Creating Network Load on Local Wi-Fi from One PC

Generate sustained Wi-Fi bandwidth load from a single PC using a VM SFTP server to test router stability and throughput.

Read More
Changing the Default Editor for Batch Files in Windows 11's File Explorer

Resolve the issue of batch files opening in Notepad by changing the default editor to a preferred application like VS Code.

Read More
Gain WiFi Connection Minutes Before Losing it by Changing MAC Address

Bypass MAC address filtering to restore WiFi connectivity temporarily when a device is blocked by network administrators.

Read More
Photos Folders Turned Black: Troubleshooting Picture Applications on Windows

Resolve black screens in Windows Photos by resetting the app, updating graphics drivers, and repairing system files.

Read More
Troubleshooting High CPU Temperature Values: A Step-by-Step Guide

Resolve high CPU temperatures and thermal throttling by monitoring with Speedfan, cleaning dust from cooling components, and replacing degraded thermal paste.

Read More
Make cURL establish TLS connection with CA unknown

Resolve cURL TLS connection failures with unknown or self-signed certificates by using the --insecure flag to bypass CA validation.

Read More
Troubleshooting Incorrect Network Metrics Values in Grafana, Prometheus, InfluxDB, and Telegraf

Fix incorrect network metrics in Grafana, Prometheus, InfluxDB, and Telegraf by verifying interface selection, resolving unit mismatches, and handling counter resets.

Read More
Start Another Terminal Window (cmd.exe) Windows Repair/Troubleshoot

Provides step-by-step instructions to access the Windows Command Prompt via bootable media for advanced system repair and troubleshooting.

Read More
Thinkpad P1 Gen 6: Sudden Thunderbolt 3 Dock USB-C Charging Stopped Working

Resolve sudden Thunderbolt 3 dock USB-C charging and internet failure on ThinkPad P1 Gen 6 by updating firmware, resetting the dock, and adjusting power settings.

Read More
ASUS Windows 11 Laptop: Internet Connection Issue with Hotspot

Resolve ASUS Windows 11 laptop spinning wheel issue when connecting to mobile hotspot by resetting network stack, disabling IPv6, and adjusting power settings.

Read More
Developing iOS Project with Firebase: Logging in and Sending Push Notifications

Integrates Firebase to enable secure user authentication and push notifications in iOS applications.

Read More
Troubleshooting Bash Script with Suspected Issues of Spaces, Dashes, Filenames and Quoting

Resolve Bash script failures caused by word splitting, globbing, and special characters in filenames by applying proper quoting techniques.

Read More
Populating OneDrive Folder for Local Backup without Affecting Remote Files

Prevent OneDrive from deleting remote files during Windows reinstallation by unlinking the account or using symbolic links to isolate local data.

Read More
Force First Frame as Keyframe Without Re-encoding: A Quick Solution

Resolve inaccurate seeking and playback glitches by re-encoding video to ensure the first frame is a valid keyframe.

Read More
Find Information in Database Using WSL (Ubuntu) on Windows-10

Resolve database connection issues from WSL Ubuntu on Windows 10 by configuring client tools and network access to query remote or local servers.

Read More
Configuring a New Router with Different Networks: One Family, One Guest

Resolve IP conflicts and isolate guest traffic by configuring a second router with a distinct subnet via its WAN port.

Read More
Quickly Open Multiple Stock Websites with a Single Command

Solve the problem of manually opening multiple stock research websites by creating a single command to launch them simultaneously on Windows, macOS, or Linux.

Read More
Improved Adobe Acrobat Search Experience: Access Advanced Search with Ease

Access advanced search filters like case sensitivity and regex in Adobe Acrobat by clicking More Options in the Find bar.

Read More
Port Forwarding VM via OpenVPN: A Comprehensive Guide

Configure OpenVPN server and iptables to forward specific ports from VPN clients to a virtual machine's internal IP address.

Read More
Understanding Partitions in the 1980s: A Look Back at MS-DOS and Master Boot Record

Explains how the Master Boot Record and partition table enabled MS-DOS to manage multiple disk volumes on a single physical drive.

Read More
Windows 10 Enterprise: Keyboard Not Detected in Managed Organization with Admin Privileges

Resolve Windows 10 Enterprise keyboard detection failures caused by Group Policy restrictions, driver corruption, or USB enumeration errors.

Read More
Can't Find x86_64 Versions of Applications on MacOS arm64 (M1)

Resolve missing x86_64 app issues on M1 Macs by installing Rosetta 2 and reinstalling apps as universal binaries.

Read More
How to Hide Installation Source for an Android App

Manage Android app installation source visibility by using USB transfers or file managers to reduce browser traces and isolate data via work profiles.

Read More
Connecting Momentus 4200.2 ST9808210A Hard Drive via USB Cable

Resolve inability to access Seagate Momentus 4200.2 ST9808210A hard drive by connecting it via USB using a compatible SATA-to-USB adapter and configuring the disk in Windows.

Read More