Installing Two WSL Instances (Non-C Drive Point Instance)

Abstract: Install a second WSL instance on a non-C drive to separate system resources from user data and maintain independent Linux distributions.

Created: 2026-07-30 by
You can install two Windows Subsystem for Linux (WSL) instances by using the wsl --import command to create a new virtual hard disk on a non-C drive. This method allows you to store your Ubuntu 20.04 or 22.04 distribution files on a separate partition, such as D: or E:, effectively separating system resources from user data. By specifying a custom path during the import process, you ensure that the second instance runs independently of the default C: drive installation while maintaining full functionality and access to both distributions simultaneously.

Prerequisites for Dual WSL Setup

Before creating a second instance, you must ensure that WSL is properly enabled on your Windows machine. Open PowerShell or Command Prompt as an administrator and run wsl --set-default-version 2. This command ensures that all new installations use the modern WSL2 architecture, which provides better performance and full system call compatibility compared to WSL1. Additionally, verify that your target drive has sufficient free space, as each Linux distribution requires several gigabytes for the root file system and additional storage for packages and user files. It is also advisable to check if you already have a default distribution installed. You can list existing instances by running wsl -l -v. If you see an active Ubuntu version, you can proceed with adding a second one without removing the first. This setup is particularly useful for developers who need isolated environments for different projects or testing scenarios. For more information on managing existing installations, you might find our guide on transferring WSL Ubuntu installation to USB helpful for understanding how WSL handles file paths and external storage.

Preparing the Destination Drive

The core of this solution involves preparing a location on a non-C drive to host the new virtual hard disk. Navigate to your desired directory, such as D:\WSL\Ubuntu22, using File Explorer or the command line. Create a subdirectory for the specific distribution you intend to install. This structure keeps your WSL instances organized and makes it easier to manage backups or move them in the future. Next, you need a tarball of the Linux distribution. You can download the latest Ubuntu 22.04 or 20.04 tar.gz file from the official Canonical archives or use the Microsoft Store app to export an existing installation. If you choose to export an existing instance, you can do so by running wsl --export Ubuntu D:\Backup\Ubuntu.tar.gz. This creates a portable archive that can be imported into a new location. Ensure that the tarball is accessible via a short, simple path to avoid issues with long file name limits in Windows.

Importing the Second Instance

With the destination folder ready and the tarball available, you can now import the new WSL instance. Use the following command structure in an elevated PowerShell window:
wsl --import Ubuntu22 D:\WSL\Ubuntu22 D:\Backup\Ubuntu.tar.gz
Replace Ubuntu22 with the name you want for the new instance, D:\WSL\Ubuntu22 with the path to the empty folder you created earlier, and D:\Backup\Ubuntu.tar.gz with the path to your tarball. The --import flag tells WSL to create a new virtual hard disk at the specified location and extract the contents of the tarball into it. This process may take several minutes depending on the size of the archive and the speed of your storage drive. Once the import completes, you will have a fully functional Ubuntu instance residing on your non-C drive. You can start it by running wsl -d Ubuntu22. This command launches the new distribution, allowing you to install packages, configure services, and develop applications just as you would with the default instance. The key advantage here is that the heavy I/O operations are directed to the secondary drive, reducing load on your primary system drive.

Configuring User Permissions

By default, the imported instance may start with the root user. To improve security and usability, you should set up a default non-root user. Inside the new WSL session, you can add a new user with adduser username and then switch to that user. Alternatively, you can modify the .wslconfig file in your Windows user profile to set specific configurations for the new instance. If you encounter permission issues when accessing files from Windows, remember that WSL2 uses a network filesystem to mount the Windows drives. Accessing /mnt/c/ from within WSL is generally slower than accessing native Linux files. Therefore, keeping your project files within the WSL file system (e.g., /home/username/projects) is recommended for optimal performance. This practice applies to both your C: drive instance and your new non-C drive instance.

Managing Multiple Instances

Running multiple WSL instances concurrently can consume significant RAM and CPU resources. Monitor your system's resource usage using the Windows Task Manager or the wsl --list --verbose command to see the current state of each distribution. You can shut down all WSL instances efficiently by running wsl --shutdown from PowerShell. This ensures that background processes do not drain battery life on laptops or leave resources occupied unnecessarily. For advanced configuration, you can edit the wsl.conf file inside each instance to set hostname, networking, and mount options. Each instance maintains its own separate environment, meaning package installations in one do not affect the other. This isolation is beneficial for testing different library versions or operating system updates without risking your primary development environment.

Frequently Asked Questions

Can I run both WSL instances at the same time?

Yes, you can run multiple WSL distributions simultaneously. Each instance operates as a separate lightweight VM, allowing you to open terminals for both Ubuntu 20.04 and 22.04 in parallel. Just be aware that running both concurrently will increase RAM usage significantly.

How do I delete a WSL instance stored on a non-C drive?

To remove the instance, first shut it down using wsl --terminate InstanceName. Then, simply delete the folder where the virtual hard disk was stored (e.g., D:\WSL\Ubuntu22). You can also use wsl --unregister InstanceName to clean up the registration entry in WSL.

Is there a performance penalty for storing WSL on a secondary drive?

No, there is no inherent performance penalty. In fact, storing large datasets on a faster SSD secondary drive can improve overall system responsiveness by freeing up I/O bandwidth on your main boot drive. The performance depends entirely on the speed of the physical storage device used.

Can I transfer my existing C: drive WSL to another drive later?

Yes, you can export your existing installation and re-import it to a new location. Use wsl --export to create a backup tarball, then use wsl --import to place it on the new drive. Remember to unregister the old instance after confirming the new one works correctly.

Does this method work for distributions other than Ubuntu?

Absolutely. The wsl --import command supports any valid tarball containing a Linux root file system. You can import Debian, Kali, Alpine, or custom-built distributions into any directory on any mounted drive, provided they are compatible with WSL2.

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